diff options
author | Imre Kaloz <kaloz@openwrt.org> | 2008-06-04 13:16:18 +0000 |
---|---|---|
committer | Imre Kaloz <kaloz@openwrt.org> | 2008-06-04 13:16:18 +0000 |
commit | 0244e57bb9fb9ebd1dd224bd5789ad9cc24b0175 (patch) | |
tree | df3661a97c04b17e7226289fb1a50b61c29f4603 /package/madwifi/patches/400-changeset_r3402.patch | |
parent | 40a175150e8ca6d66023d419196701aa337f8612 (diff) | |
download | upstream-0244e57bb9fb9ebd1dd224bd5789ad9cc24b0175.tar.gz upstream-0244e57bb9fb9ebd1dd224bd5789ad9cc24b0175.tar.bz2 upstream-0244e57bb9fb9ebd1dd224bd5789ad9cc24b0175.zip |
refresh madwifi patches using upstream style
SVN-Revision: 11351
Diffstat (limited to 'package/madwifi/patches/400-changeset_r3402.patch')
-rw-r--r-- | package/madwifi/patches/400-changeset_r3402.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/package/madwifi/patches/400-changeset_r3402.patch b/package/madwifi/patches/400-changeset_r3402.patch new file mode 100644 index 0000000000..af7e6d5733 --- /dev/null +++ b/package/madwifi/patches/400-changeset_r3402.patch @@ -0,0 +1,35 @@ +--- a/ath_hal/ah_os.h ++++ b/ath_hal/ah_os.h +@@ -194,10 +194,6 @@ + */ + #if (AH_BYTE_ORDER == AH_BIG_ENDIAN) + #define is_reg_le(__reg) ((0x4000 <= (__reg) && (__reg) < 0x5000)) +-#else +-#define is_reg_le(__reg) 1 +-#endif +- + #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,12) + #define _OS_REG_WRITE(_ah, _reg, _val) do { \ + is_reg_le(_reg) ? \ +@@ -219,6 +215,21 @@ + readl((_ah)->ah_sh + (_reg)) : \ + cpu_to_le32(readl((_ah)->ah_sh + (_reg)))) + #endif /* KERNEL_VERSION(2,6,12) */ ++#else /* AH_BYTE_ORDER != AH_BIG_ENDIAN */ ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,12) ++#define _OS_REG_WRITE(_ah, _reg, _val) do { \ ++ iowrite32((_val), (_ah)->ah_sh + (_reg)); \ ++ } while (0) ++#define _OS_REG_READ(_ah, _reg) \ ++ ioread32((_ah)->ah_sh + (_reg)) ++#else ++#define _OS_REG_WRITE(_ah, _reg, _val) do { \ ++ writel((_val), (_ah)->ah_sh + (_reg)); \ ++ } while (0) ++#define _OS_REG_READ(_ah, _reg) \ ++ readl((_ah)->ah_sh + (_reg)) ++#endif /* KERNEL_VERSION(2,6,12) */ ++#endif /* AH_BYTE_ORDER != AH_BIG_ENDIAN */ + + /* + * The functions in this section are not intended to be invoked by MadWifi |