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 04, 2018 at 08:10:11PM -0700, Dennis Dalessandro wrote:
> From: Don Hiatt <don.hiatt@xxxxxxxxx>
> 
> Add 16B Management Packet definition. This optimized packet
> format replaces the ib_other_headers and BTH with a source
> and destination QP number.
> 
> To support these packets we introduce struct opa_16b_mgmt
> into the struct hfi1_16b_header.
> 
> This packet format is only used for MAD packets using the
> IB_OPCODE_UD_SEND_ONLY opcode on QP0/1.
> 
> The original 16B implementation failed to use 16B management
> packets so now we add their definition.
> 
> Reviewed-by: Ira Weiny <ira.weiny@xxxxxxxxx>
> Signed-off-by: Don Hiatt <don.hiatt@xxxxxxxxx>
> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@xxxxxxxxx>
>  drivers/infiniband/hw/hfi1/hfi.h   |    1 +
>  drivers/infiniband/hw/hfi1/verbs.h |    7 +++++++
>  2 files changed, 8 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/infiniband/hw/hfi1/hfi.h b/drivers/infiniband/hw/hfi1/hfi.h
> index 777abb8..b4c7049 100644
> +++ b/drivers/infiniband/hw/hfi1/hfi.h
> @@ -393,6 +393,7 @@ struct hfi1_packet {
>   */
>  #define OPA_16B_L4_9B		0x00
>  #define OPA_16B_L2_TYPE		0x02
> +#define OPA_16B_L4_FM		0x08
>  #define OPA_16B_L4_IB_LOCAL	0x09
>  #define OPA_16B_L4_IB_GLOBAL	0x0A
>  #define OPA_16B_L4_ETHR		OPA_VNIC_L4_ETHR
> 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?

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