From: Oleksij Rempel Date: Sun, 17 Mar 2013 16:15:20 +0000 (+0100) Subject: build fix: src on memcpy is allways const X-Git-Tag: 1.3.2~12^2~28 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=cc00204d96a1b3b6a0dc2af28cad5894dd055484;p=librecmc%2Fopen-ath9k-htc-firmware.git build fix: src on memcpy is allways const Signed-off-by: Oleksij Rempel --- diff --git a/target_firmware/magpie_fw_dev/target/adf/adf_os_mem_pvt.h b/target_firmware/magpie_fw_dev/target/adf/adf_os_mem_pvt.h index 0519ad1..b5bcfa1 100755 --- a/target_firmware/magpie_fw_dev/target/adf/adf_os_mem_pvt.h +++ b/target_firmware/magpie_fw_dev/target/adf/adf_os_mem_pvt.h @@ -51,7 +51,7 @@ static inline void __adf_os_mem_free(void *buf) } /* move a memory buffer */ -static inline void __adf_os_mem_copy(void *dst, void *src, adf_os_size_t size) +static inline void __adf_os_mem_copy(void *dst, const void *src, adf_os_size_t size) { A_MEMCPY(dst,src,size); } diff --git a/target_firmware/magpie_fw_dev/target/inc/adf_os_mem.h b/target_firmware/magpie_fw_dev/target/inc/adf_os_mem.h index 2e8b44a..ec7691f 100755 --- a/target_firmware/magpie_fw_dev/target/inc/adf_os_mem.h +++ b/target_firmware/magpie_fw_dev/target/inc/adf_os_mem.h @@ -76,7 +76,7 @@ adf_os_mem_free(void *buf) * @param[in] size buffer size */ static inline void -adf_os_mem_copy(void *dst, void *src, adf_os_size_t size) +adf_os_mem_copy(void *dst, const void *src, adf_os_size_t size) { __adf_os_mem_copy(dst, src, size); } diff --git a/target_firmware/wlan/ah_osdep.c b/target_firmware/wlan/ah_osdep.c index 9fda074..7cb2266 100755 --- a/target_firmware/wlan/ah_osdep.c +++ b/target_firmware/wlan/ah_osdep.c @@ -142,7 +142,7 @@ ath_hal_memzero(void *dst, adf_os_size_t n) } void * __ahdecl -ath_hal_memcpy(void *dst, void *src, adf_os_size_t n) +ath_hal_memcpy(void *dst, const void *src, adf_os_size_t n) { adf_os_mem_copy(dst, src, n); return 0; diff --git a/target_firmware/wlan/ah_osdep.h b/target_firmware/wlan/ah_osdep.h index 54b2a9b..d62de3d 100755 --- a/target_firmware/wlan/ah_osdep.h +++ b/target_firmware/wlan/ah_osdep.h @@ -131,7 +131,7 @@ extern void* __ahdecl ath_hal_ioremap(a_uint32_t addr, a_uint32_t len); #define OS_MEMZERO(_a, _n) ath_hal_memzero((_a), (_n)) extern void __ahdecl ath_hal_memzero(void *, size_t); #define OS_MEMCPY(_d, _s, _n) ath_hal_memcpy(_d,_s,_n) -extern void * __ahdecl ath_hal_memcpy(void *, void *, size_t); +extern void * __ahdecl ath_hal_memcpy(void *, const void *, size_t); #ifndef abs #define abs(_a) __builtin_abs(_a)