Le jeudi 29 janvier 2015 à 19:43 +0100, Yann Droneaud a écrit :
> Le jeudi 29 janvier 2015 à 11:28 -0700, Jason Gunthorpe a écrit :
> > On Thu, Jan 29, 2015 at 06:59:58PM +0100, Yann Droneaud wrote:

> > > -         resp.odp_caps.general_caps = attr.odp_caps.general_caps;
> > > -         resp.odp_caps.per_transport_caps.rc_odp_caps =
> > > -                 attr.odp_caps.per_transport_caps.rc_odp_caps;
> > > -         resp.odp_caps.per_transport_caps.uc_odp_caps =
> > > -                 attr.odp_caps.per_transport_caps.uc_odp_caps;
> > > -         resp.odp_caps.per_transport_caps.ud_odp_caps =
> > > -                 attr.odp_caps.per_transport_caps.ud_odp_caps;
> > > -         resp.comp_mask |= IB_USER_VERBS_EX_QUERY_DEVICE_ODP;
> > > - }
> > > + resp.odp_caps.general_caps = attr.odp_caps.general_caps;
> > > + resp.odp_caps.per_transport_caps.rc_odp_caps =
> > > +         attr.odp_caps.per_transport_caps.rc_odp_caps;
> > > + resp.odp_caps.per_transport_caps.uc_odp_caps =
> > > +         attr.odp_caps.per_transport_caps.uc_odp_caps;
> > > + resp.odp_caps.per_transport_caps.ud_odp_caps =
> > > +         attr.odp_caps.per_transport_caps.ud_odp_caps;
> > >  #endif
> > > + resp.comp_mask |= IB_USER_VERBS_EX_QUERY_DEVICE_ODP;
> > 
> > Not sure about this - if 0 is a valid null answer for all the _caps
> > then it is fine, and the comp_mask bit should just be removed as the
> > size alone should be enough.
> > 
> 
> That's difficult to say. But I hope 0 are valids answers in this case.
> 

Hum, according to include/rdma/ib_verbs.h, there's a bit set
for ODP support:

    148 enum ib_odp_general_cap_bits {
    149         IB_ODP_SUPPORT = 1 << 0,
    150 };

So it should be safe to set everything to 0 in struct
ib_uverbs_odp_caps.

Regards.

-- 
Yann Droneaud
OPTEYA


--
To unsubscribe from this list: send the line "unsubscribe linux-api" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to