diff options
author | Harvey Harrison <harvey.harrison@gmail.com> | 2009-01-17 20:11:57 -0500 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2009-01-17 20:11:57 -0500 |
commit | 9c3da0991754d480328eeaa2b90cb231a1cea9b6 (patch) | |
tree | 744f69e5b04af0e950658fb26ad95bd18868c8e8 /include/rdma | |
parent | f3b8436ad9a8ad36b3c9fa1fe030c7f38e5d3d0b (diff) |
IB: Remove __constant_{endian} uses
The base versions handle constant folding just fine, use them
directly. The replacements are OK in the include/ files as they are
not exported to userspace so we don't need the __ prefixed versions.
This patch does not affect code generation at all.
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'include/rdma')
-rw-r--r-- | include/rdma/ib_cm.h | 12 | ||||
-rw-r--r-- | include/rdma/ib_mad.h | 2 | ||||
-rw-r--r-- | include/rdma/ib_smi.h | 34 |
3 files changed, 24 insertions, 24 deletions
diff --git a/include/rdma/ib_cm.h b/include/rdma/ib_cm.h index ec7c6d99ed3f..938858304300 100644 --- a/include/rdma/ib_cm.h +++ b/include/rdma/ib_cm.h | |||
@@ -314,12 +314,12 @@ struct ib_cm_id *ib_create_cm_id(struct ib_device *device, | |||
314 | */ | 314 | */ |
315 | void ib_destroy_cm_id(struct ib_cm_id *cm_id); | 315 | void ib_destroy_cm_id(struct ib_cm_id *cm_id); |
316 | 316 | ||
317 | #define IB_SERVICE_ID_AGN_MASK __constant_cpu_to_be64(0xFF00000000000000ULL) | 317 | #define IB_SERVICE_ID_AGN_MASK cpu_to_be64(0xFF00000000000000ULL) |
318 | #define IB_CM_ASSIGN_SERVICE_ID __constant_cpu_to_be64(0x0200000000000000ULL) | 318 | #define IB_CM_ASSIGN_SERVICE_ID cpu_to_be64(0x0200000000000000ULL) |
319 | #define IB_CMA_SERVICE_ID __constant_cpu_to_be64(0x0000000001000000ULL) | 319 | #define IB_CMA_SERVICE_ID cpu_to_be64(0x0000000001000000ULL) |
320 | #define IB_CMA_SERVICE_ID_MASK __constant_cpu_to_be64(0xFFFFFFFFFF000000ULL) | 320 | #define IB_CMA_SERVICE_ID_MASK cpu_to_be64(0xFFFFFFFFFF000000ULL) |
321 | #define IB_SDP_SERVICE_ID __constant_cpu_to_be64(0x0000000000010000ULL) | 321 | #define IB_SDP_SERVICE_ID cpu_to_be64(0x0000000000010000ULL) |
322 | #define IB_SDP_SERVICE_ID_MASK __constant_cpu_to_be64(0xFFFFFFFFFFFF0000ULL) | 322 | #define IB_SDP_SERVICE_ID_MASK cpu_to_be64(0xFFFFFFFFFFFF0000ULL) |
323 | 323 | ||
324 | struct ib_cm_compare_data { | 324 | struct ib_cm_compare_data { |
325 | u8 data[IB_CM_COMPARE_SIZE]; | 325 | u8 data[IB_CM_COMPARE_SIZE]; |
diff --git a/include/rdma/ib_mad.h b/include/rdma/ib_mad.h index 5f6c40fffcf4..8cc71a130d1b 100644 --- a/include/rdma/ib_mad.h +++ b/include/rdma/ib_mad.h | |||
@@ -107,7 +107,7 @@ | |||
107 | #define IB_MGMT_RMPP_STATUS_ABORT_MAX 127 | 107 | #define IB_MGMT_RMPP_STATUS_ABORT_MAX 127 |
108 | 108 | ||
109 | #define IB_QP0 0 | 109 | #define IB_QP0 0 |
110 | #define IB_QP1 __constant_htonl(1) | 110 | #define IB_QP1 cpu_to_be32(1) |
111 | #define IB_QP1_QKEY 0x80010000 | 111 | #define IB_QP1_QKEY 0x80010000 |
112 | #define IB_QP_SET_QKEY 0x80000000 | 112 | #define IB_QP_SET_QKEY 0x80000000 |
113 | 113 | ||
diff --git a/include/rdma/ib_smi.h b/include/rdma/ib_smi.h index aaca0878668f..98b9086d769a 100644 --- a/include/rdma/ib_smi.h +++ b/include/rdma/ib_smi.h | |||
@@ -63,25 +63,25 @@ struct ib_smp { | |||
63 | u8 return_path[IB_SMP_MAX_PATH_HOPS]; | 63 | u8 return_path[IB_SMP_MAX_PATH_HOPS]; |
64 | } __attribute__ ((packed)); | 64 | } __attribute__ ((packed)); |
65 | 65 | ||
66 | #define IB_SMP_DIRECTION __constant_htons(0x8000) | 66 | #define IB_SMP_DIRECTION cpu_to_be16(0x8000) |
67 | 67 | ||
68 | /* Subnet management attributes */ | 68 | /* Subnet management attributes */ |
69 | #define IB_SMP_ATTR_NOTICE __constant_htons(0x0002) | 69 | #define IB_SMP_ATTR_NOTICE cpu_to_be16(0x0002) |
70 | #define IB_SMP_ATTR_NODE_DESC __constant_htons(0x0010) | 70 | #define IB_SMP_ATTR_NODE_DESC cpu_to_be16(0x0010) |
71 | #define IB_SMP_ATTR_NODE_INFO __constant_htons(0x0011) | 71 | #define IB_SMP_ATTR_NODE_INFO cpu_to_be16(0x0011) |
72 | #define IB_SMP_ATTR_SWITCH_INFO __constant_htons(0x0012) | 72 | #define IB_SMP_ATTR_SWITCH_INFO cpu_to_be16(0x0012) |
73 | #define IB_SMP_ATTR_GUID_INFO __constant_htons(0x0014) | 73 | #define IB_SMP_ATTR_GUID_INFO cpu_to_be16(0x0014) |
74 | #define IB_SMP_ATTR_PORT_INFO __constant_htons(0x0015) | 74 | #define IB_SMP_ATTR_PORT_INFO cpu_to_be16(0x0015) |
75 | #define IB_SMP_ATTR_PKEY_TABLE __constant_htons(0x0016) | 75 | #define IB_SMP_ATTR_PKEY_TABLE cpu_to_be16(0x0016) |
76 | #define IB_SMP_ATTR_SL_TO_VL_TABLE __constant_htons(0x0017) | 76 | #define IB_SMP_ATTR_SL_TO_VL_TABLE cpu_to_be16(0x0017) |
77 | #define IB_SMP_ATTR_VL_ARB_TABLE __constant_htons(0x0018) | 77 | #define IB_SMP_ATTR_VL_ARB_TABLE cpu_to_be16(0x0018) |
78 | #define IB_SMP_ATTR_LINEAR_FORWARD_TABLE __constant_htons(0x0019) | 78 | #define IB_SMP_ATTR_LINEAR_FORWARD_TABLE cpu_to_be16(0x0019) |
79 | #define IB_SMP_ATTR_RANDOM_FORWARD_TABLE __constant_htons(0x001A) | 79 | #define IB_SMP_ATTR_RANDOM_FORWARD_TABLE cpu_to_be16(0x001A) |
80 | #define IB_SMP_ATTR_MCAST_FORWARD_TABLE __constant_htons(0x001B) | 80 | #define IB_SMP_ATTR_MCAST_FORWARD_TABLE cpu_to_be16(0x001B) |
81 | #define IB_SMP_ATTR_SM_INFO __constant_htons(0x0020) | 81 | #define IB_SMP_ATTR_SM_INFO cpu_to_be16(0x0020) |
82 | #define IB_SMP_ATTR_VENDOR_DIAG __constant_htons(0x0030) | 82 | #define IB_SMP_ATTR_VENDOR_DIAG cpu_to_be16(0x0030) |
83 | #define IB_SMP_ATTR_LED_INFO __constant_htons(0x0031) | 83 | #define IB_SMP_ATTR_LED_INFO cpu_to_be16(0x0031) |
84 | #define IB_SMP_ATTR_VENDOR_MASK __constant_htons(0xFF00) | 84 | #define IB_SMP_ATTR_VENDOR_MASK cpu_to_be16(0xFF00) |
85 | 85 | ||
86 | struct ib_port_info { | 86 | struct ib_port_info { |
87 | __be64 mkey; | 87 | __be64 mkey; |