Whamcloud - gitweb
* fixed openibnal/iibnal wire structs to use WIRE_ATTR. This (for openibnal)
authoreeb <eeb>
Tue, 9 Aug 2005 14:50:26 +0000 (14:50 +0000)
committereeb <eeb>
Tue, 9 Aug 2005 14:50:26 +0000 (14:50 +0000)
   is part of a fix for bz 7217

lnet/klnds/iiblnd/iiblnd.h
lnet/klnds/openiblnd/openiblnd.h

index 82cdd3c..32f2921 100644 (file)
@@ -249,13 +249,13 @@ typedef struct
 {
         __u32                 rd_nob;           /* # of bytes */
         __u64                 rd_addr;          /* remote io vaddr */
-} kib_rdma_desc_t __attribute__((packed));
+} WIRE_ATTR kib_rdma_desc_t;
 
 typedef struct
 {
         ptl_hdr_t         ibim_hdr;             /* portals header */
         char              ibim_payload[0];      /* piggy-backed payload */
-} kib_immediate_msg_t __attribute__((packed));
+} WIRE_ATTR kib_immediate_msg_t;
 
 /* these arrays serve two purposes during rdma.  they are built on the passive
  * side and sent to the active side as remote arguments.  On the active side
@@ -268,7 +268,7 @@ typedef struct
         __u32             ibrm_num_descs;       /* how many descs */
         __u32             rd_key;               /* remote key */
         kib_rdma_desc_t   ibrm_desc[0];         /* where to suck/blow */
-} kib_rdma_msg_t __attribute__((packed));
+} WIRE_ATTR kib_rdma_msg_t;
 
 #define kib_rdma_msg_len(num_descs) \
         offsetof(kib_msg_t, ibm_u.rdma.ibrm_desc[num_descs])
@@ -277,7 +277,7 @@ typedef struct
 {
         __u64             ibcm_cookie;          /* opaque completion cookie */
         __u32             ibcm_status;          /* completion status */
-} kib_completion_msg_t __attribute__((packed));
+} WIRE_ATTR kib_completion_msg_t;
 
 typedef struct
 {
@@ -293,8 +293,8 @@ typedef struct
                 kib_immediate_msg_t   immediate;
                 kib_rdma_msg_t        rdma;
                 kib_completion_msg_t  completion;
-        } ibm_u __attribute__((packed));
-} kib_msg_t __attribute__((packed));
+        } WIRE_ATTR ibm_u;
+} WIRE_ATTR kib_msg_t;
 
 #define IBNAL_MSG_MAGIC       0x0be91b91        /* unique magic */
 #define IBNAL_MSG_VERSION              1        /* current protocol version */
index de52aab..5ba102e 100644 (file)
@@ -229,12 +229,12 @@ typedef struct kib_svcrsp                       /* service response */
         __u64             ibsr_svc_id;          /* service's id */
         __u8              ibsr_svc_gid[16];     /* service's gid */
         __u16             ibsr_svc_pkey;        /* service's pkey */
-} kib_svcrsp_t;
+} WIRE_ATTR kib_svcrsp_t;
 
 typedef struct kib_connparams
 {
         __u32             ibcp_queue_depth;
-} kib_connparams_t;
+} WIRE_ATTR kib_connparams_t;
 
 typedef struct
 {
@@ -252,26 +252,26 @@ typedef struct
         __u32             rd_key;               /* remote key */
         __u32             rd_nob;               /* # of bytes */
         __u64             rd_addr;              /* remote io vaddr */
-} kib_rdma_desc_t;
+} WIRE_ATTR kib_rdma_desc_t;
 
 typedef struct
 {
         ptl_hdr_t         ibim_hdr;             /* portals header */
         char              ibim_payload[0];      /* piggy-backed payload */
-} kib_immediate_msg_t;
+} WIRE_ATTR kib_immediate_msg_t;
 
 typedef struct
 {
         ptl_hdr_t         ibrm_hdr;             /* portals header */
         __u64             ibrm_cookie;          /* opaque completion cookie */
         kib_rdma_desc_t   ibrm_desc;            /* where to suck/blow */
-} kib_rdma_msg_t;
+} WIRE_ATTR kib_rdma_msg_t;
 
 typedef struct
 {
         __u64             ibcm_cookie;          /* opaque completion cookie */
         __u32             ibcm_status;          /* completion status */
-} kib_completion_msg_t;
+} WIRE_ATTR kib_completion_msg_t;
 
 typedef struct
 {
@@ -293,8 +293,8 @@ typedef struct
                 kib_immediate_msg_t   immediate;
                 kib_rdma_msg_t        rdma;
                 kib_completion_msg_t  completion;
-        }                    ibm_u;
-} kib_msg_t;
+        } WIRE_ATTR       ibm_u;
+} WIRE_ATTR kib_msg_t;
 
 #define IBNAL_MSG_MAGIC       0x0be91b91        /* unique magic */
 #define IBNAL_MSG_VERSION              2        /* current protocol version */