Re: [PATCH for-next 1/3] IB/hfi1: Define 16B Management Packets

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

 



On Wed, Apr 11, 2018 at 01:05:51PM -0700, Don Hiatt wrote:
> > > diff --git a/drivers/infiniband/hw/hfi1/verbs.h b/drivers/infiniband/hw/hfi1/verbs.h
> > > index 2d787b8..3ae26ac 100644
> > > +++ b/drivers/infiniband/hw/hfi1/verbs.h
> > > @@ -110,6 +110,12 @@ enum {
> > >   #define LRH_9B_BYTES (FIELD_SIZEOF(struct ib_header, lrh))
> > >   #define LRH_9B_DWORDS (LRH_9B_BYTES / sizeof(u32))
> > > +/* 24Bits for qpn, upper 8Bits reserved */
> > > +struct opa_16b_mgmt {
> > > +	__be32 dest_qpn;
> > > +	__be32 src_qpn;
> > > +} __packed;
> > Are all the packed's in this file really necessary?
> > 
> Yes, these packs are necessary as the structures are placed directly on the
> wire.

That isn't really how you answer this question. Point to where padding
is being eliminated or where the struct is used unaligned to justify
the __packed.

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