diff options
author | Arnd Bergmann <[email protected]> | 2021-09-27 14:16:35 +0200 |
---|---|---|
committer | Kalle Valo <[email protected]> | 2021-09-28 17:42:26 +0300 |
commit | 603a1621caa097be23c7784e36cb8edf23cd31db (patch) | |
tree | 02d1b573ff16df691cfd77aa3ed746b957eefca7 /scripts/gdb/linux/utils.py | |
parent | 151a7c12c4fc8340b51e849e4d1fcb7d794777a5 (diff) |
mwifiex: avoid null-pointer-subtraction warning
clang complains about some NULL pointer arithmetic in this driver:
drivers/net/wireless/marvell/mwifiex/sta_tx.c:65:59: error: performing pointer subtraction with a null pointer has undefined behavior [-Werror,-Wnull-pointer-subtraction]
pad = ((void *)skb->data - (sizeof(*local_tx_pd) + hroom)-
^
drivers/net/wireless/marvell/mwifiex/uap_txrx.c:478:53: error: performing pointer subtraction with a null pointer has undefined behavior [-Werror,-Wnull-pointer-subtraction]
pad = ((void *)skb->data - (sizeof(*txpd) + hroom) - NULL) &
Rework that expression to do the same thing using a uintptr_t.
Signed-off-by: Arnd Bergmann <[email protected]>
Signed-off-by: Kalle Valo <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions