diff options
author | Moritz Muehlenhoff <jmm@debian.org> | 2009-02-18 19:50:07 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-04-03 14:53:24 -0700 |
commit | 18c7f792be75c2430cbf16e22dca1ab6a9881a63 (patch) | |
tree | a40ba16d289a168c413cd4df65997924ab81826d /drivers/staging/wlan-ng/hfa384x.h | |
parent | 465e7417b15348909606c3edce5f018818235a54 (diff) | |
download | op-kernel-dev-18c7f792be75c2430cbf16e22dca1ab6a9881a63.zip op-kernel-dev-18c7f792be75c2430cbf16e22dca1ab6a9881a63.tar.gz |
Staging: wlan-ng: Replace local byteorder macros
Replace hfa384x2host_16(), hfa384x2host_32(), host2hfa384x_16()
and host2hfa384x_32() with standard byteorder macros.
Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/wlan-ng/hfa384x.h')
-rw-r--r-- | drivers/staging/wlan-ng/hfa384x.h | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/drivers/staging/wlan-ng/hfa384x.h b/drivers/staging/wlan-ng/hfa384x.h index ddfa566..f3e8717 100644 --- a/drivers/staging/wlan-ng/hfa384x.h +++ b/drivers/staging/wlan-ng/hfa384x.h @@ -328,14 +328,6 @@ PD Record codes #define HFA384x_STATUS_RESULT_SET(value) (((u16)(value)) << 8) -/* Byte Order */ -#ifdef __KERNEL__ -#define hfa384x2host_16(n) (__le16_to_cpu((u16)(n))) -#define hfa384x2host_32(n) (__le32_to_cpu((u32)(n))) -#define host2hfa384x_16(n) (__cpu_to_le16((u16)(n))) -#define host2hfa384x_32(n) (__cpu_to_le32((u32)(n))) -#endif - /* Host Maintained State Info */ #define HFA384x_STATE_PREINIT 0 #define HFA384x_STATE_INIT 1 @@ -1143,13 +1135,13 @@ static inline int hfa384x_drvr_getconfig16(hfa384x_t *hw, u16 rid, void *val) int result = 0; result = hfa384x_drvr_getconfig(hw, rid, val, sizeof(u16)); if (result == 0) - *((u16 *) val) = hfa384x2host_16(*((u16 *) val)); + *((u16 *) val) = le16_to_cpu(*((u16 *) val)); return result; } static inline int hfa384x_drvr_setconfig16(hfa384x_t *hw, u16 rid, u16 val) { - u16 value = host2hfa384x_16(val); + u16 value = cpu_to_le16(val); return hfa384x_drvr_setconfig(hw, rid, &value, sizeof(value)); } @@ -1166,7 +1158,7 @@ hfa384x_drvr_setconfig_async(hfa384x_t *hw, static inline int hfa384x_drvr_setconfig16_async(hfa384x_t *hw, u16 rid, u16 val) { - u16 value = host2hfa384x_16(val); + u16 value = cpu_to_le16(val); return hfa384x_drvr_setconfig_async(hw, rid, &value, sizeof(value), NULL, NULL); } |