summaryrefslogtreecommitdiff
path: root/drivers/misc/hisi_hikey_usb.c
diff options
context:
space:
mode:
authorNathan Chancellor <nathan@kernel.org>2021-12-27 12:17:57 -0700
committerJakub Kicinski <kuba@kernel.org>2022-01-09 16:25:53 -0800
commit4ccdcc8ffd955490feec05380223db6a48961eb5 (patch)
tree322ca1a5bce2ffd4221194776f68200bfedf7e78 /drivers/misc/hisi_hikey_usb.c
parent77bbcb60f734fe25e1d17a7bdc9a4260868efb0f (diff)
iwlwifi: mvm: Use div_s64 instead of do_div in iwl_mvm_ftm_rtt_smoothing()
When building ARCH=arm allmodconfig: drivers/net/wireless/intel/iwlwifi/mvm/ftm-initiator.c: In function ‘iwl_mvm_ftm_rtt_smoothing’: ./include/asm-generic/div64.h:222:35: error: comparison of distinct pointer types lacks a cast [-Werror] 222 | (void)(((typeof((n)) *)0) == ((uint64_t *)0)); \ | ^~ drivers/net/wireless/intel/iwlwifi/mvm/ftm-initiator.c:1070:9: note: in expansion of macro ‘do_div’ 1070 | do_div(rtt_avg, 100); | ^~~~~~ do_div() has to be used with an unsigned 64-bit integer dividend but rtt_avg is a signed 64-bit integer. div_s64() expects a signed 64-bit integer dividend and signed 32-bit divisor, which fits this scenario, so use that function here to fix the warning. Fixes: 8b0f92549f2c ("iwlwifi: mvm: fix 32-bit build in FTM") Signed-off-by: Nathan Chancellor <nathan@kernel.org> Link: https://lore.kernel.org/r/20211227191757.2354329-1-nathan@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/misc/hisi_hikey_usb.c')
0 files changed, 0 insertions, 0 deletions