From: Sean Hefty Date: Fri, 6 Apr 2007 17:14:02 +0000 (-0700) Subject: RDMA/cma: fix 32-bit user / 64-bit kernel mismatch issue X-Git-Tag: v1.0-rc2~1 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=e4b9273f691dc1e5f645a60172978bc0129b6e43;p=~shefty%2Flibrdmacm.git RDMA/cma: fix 32-bit user / 64-bit kernel mismatch issue A 64-bit kernel will pad the size of the event structure to a multiple of 8-bytes. When using a 32-bit kernel, the structure is left aligned to a 4-byte boundary. This results in the userspace event structure being too small because of the padding. Fix this by increasing the padding at the end of the userspace event structure. Signed-off-by: Sean Hefty --- diff --git a/include/rdma/rdma_cma_abi.h b/include/rdma/rdma_cma_abi.h index 2ffcf929..8f3e42d5 100644 --- a/include/rdma/rdma_cma_abi.h +++ b/include/rdma/rdma_cma_abi.h @@ -148,6 +148,7 @@ struct ucma_abi_ud_param { __u8 private_data[RDMA_MAX_PRIVATE_DATA]; __u8 private_data_len; __u8 reserved[7]; + __u8 reserved2[4]; /* Round to 8-byte boundary to support 32/64 */ }; struct ucma_abi_connect {