Re: [PATCH rdma-next V1 03/10] IB/core: Add subnet prefix to port info

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 07, 2016 at 11:56:08PM +0200, Eli Cohen wrote:
> On Mon, Mar 07, 2016 at 02:43:13PM -0700, Jason Gunthorpe wrote:
> > On Mon, Mar 07, 2016 at 11:08:53PM +0200, Eli Cohen wrote:
> > > +	err = ib_query_gid(ibdev, port, 0, &gid, NULL);
> > > +	if (err)
> > > +		return err;
> > > +
> > > +	props->subnet_prefix = be64_to_cpu(gid.global.subnet_prefix);
> > 
> > Why not put this common pattern in ibv_query_port?
> > 
> > device->query_port(ibdev, port, ..);
> > if (props->subnet_prefix == 0) {
> 
> Why do you need this conditional?

If the driver fills it in (like mlx seems to be able to do cheaply) we
don't need the over head of calling another callback?

Jason
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux