diff mbox series

[1/2] ath11k: fix typo with swap16() and swap32()

Message ID 1560859413-8788-1-git-send-email-kvalo@codeaurora.org (mailing list archive)
State Accepted
Commit 3378cd644bcc42c88682f2280a726d5df9411a58
Delegated to: Kalle Valo
Headers show
Series [1/2] ath11k: fix typo with swap16() and swap32() | expand

Commit Message

Kalle Valo June 18, 2019, 12:03 p.m. UTC
Fix GCC errors on sparc64:

drivers/net/wireless/ath/ath11k/dp.h:1490:13: error: implicit declaration of function 'swap32' [-Werror=implicit-function-declaration]
drivers/net/wireless/ath/ath11k/dp.h:1491:13: error: implicit declaration of function 'swap16' [-Werror=implicit-function-declaration]

Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
---
 drivers/net/wireless/ath/ath11k/dp.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Kalle Valo June 20, 2019, 1:38 p.m. UTC | #1
Kalle Valo <kvalo@codeaurora.org> wrote:

> Fix GCC errors on sparc64:
> 
> drivers/net/wireless/ath/ath11k/dp.h:1490:13: error: implicit declaration of function 'swap32' [-Werror=implicit-function-declaration]
> drivers/net/wireless/ath/ath11k/dp.h:1491:13: error: implicit declaration of function 'swap16' [-Werror=implicit-function-declaration]
> 
> Reported-by: kbuild test robot <lkp@intel.com>
> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>

2 patches applied to ath11k-bringup branch of ath.git, thanks.

3378cd644bcc ath11k: fix typo with swap16() and swap32()
e0e87d74740a ath11k: include vmalloc.h to fix a compilation error on sparc64
diff mbox series

Patch

diff --git a/drivers/net/wireless/ath/ath11k/dp.h b/drivers/net/wireless/ath/ath11k/dp.h
index 037fcbd7604d..6eeeff99dbd8 100644
--- a/drivers/net/wireless/ath/ath11k/dp.h
+++ b/drivers/net/wireless/ath/ath11k/dp.h
@@ -1487,8 +1487,8 @@  static inline void dp_peer_map_get_mac_addr(u32 addr_l32, u16 addr_h16,
 					    u8 *addr)
 {
 #ifdef __BIG_ENDIAN
-	addr_l32 = swap32(addr_l32);
-	addr_h16 = swap16(addr_h16);
+	addr_l32 = swab32(addr_l32);
+	addr_h16 = swab16(addr_h16);
 #endif
 	memcpy(addr, &addr_l32, 4);
 	memcpy(addr + 4, &addr_h16, ETH_ALEN - 4);