[PATCH 04/31] build fix: remove byte order/swapping support

Oleksij Rempel linux at rempel-privat.de
Fri Mar 29 05:01:38 EDT 2013


currently AH_BYTE_ORDER is not defined. So this parst is unused any way.

Signed-off-by: Oleksij Rempel <linux at rempel-privat.de>
---
 target_firmware/wlan/ah_osdep.h | 29 -----------------------------
 1 file changed, 29 deletions(-)

diff --git a/target_firmware/wlan/ah_osdep.h b/target_firmware/wlan/ah_osdep.h
index d62de3d..58a07ec 100755
--- a/target_firmware/wlan/ah_osdep.h
+++ b/target_firmware/wlan/ah_osdep.h
@@ -141,41 +141,12 @@ struct ath_hal;
 extern  a_uint32_t __ahdecl ath_hal_getuptime(struct ath_hal *);
 #define OS_GETUPTIME(_ah)   ath_hal_getuptime(_ah)
 
-/*
- * Byte order/swapping support.
- */
-#define AH_LITTLE_ENDIAN    1234
-#define AH_BIG_ENDIAN       4321
-
-#if AH_BYTE_ORDER == AH_BIG_ENDIAN
-/*
- * This could be optimized but since we only use it for
- * a few registers there's little reason to do so.
- */
-#ifndef __bswap32
-static inline a_uint32_t
-__bswap32(a_uint32_t _x)
-{
-    return ((a_uint32_t)(
-          (((const a_uint8_t *)(&_x))[0]    ) |
-          (((const a_uint8_t *)(&_x))[1]<< 8) |
-          (((const a_uint8_t *)(&_x))[2]<<16) |
-          (((const a_uint8_t *)(&_x))[3]<<24))
-    );
-}
-#endif
-#ifndef __bswap16
-#define __bswap16(_x) ( (a_uint16_t)( (((const a_uint8_t *)(&_x))[0] ) |\
-                         ( ( (const a_uint8_t *)( &_x ) )[1]<< 8) ) )
-#endif
-#else
 #ifndef __bswap32
 #define __bswap32(_x)	(_x)
 #endif
 #ifndef __bswap16
 #define __bswap16(_x)	(_x)
 #endif
-#endif
 
 #define OS_REG_WRITE(_ah, _reg, _val)   ath_hal_reg_write_target(_ah, _reg, _val)
 #define OS_REG_READ(_ah, _reg)      ath_hal_reg_read_target(_ah, _reg)
-- 
1.8.1.2




More information about the Ath9k_htc_fw mailing list