diff options
| author | Arnd Bergmann <arnd@arndb.de> | 2021-09-27 14:13:57 +0200 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-10-27 09:32:37 +0200 |
| commit | 9e287e00e8a62565039dc5b525dfbeb07d1a20f4 (patch) | |
| tree | 1f2421d1753ec36b7b5082a9ecc6ecc93d255335 /include/linux/avtimer_kernel.h | |
| parent | a24bb7bf519089c1dfbef8e76c73175d95ee5ff2 (diff) | |
cb710: avoid NULL pointer subtraction
commit 42641042c10c757fe10cc09088cf3f436cec5007 upstream.
clang-14 complains about an unusual way of converting a pointer to
an integer:
drivers/misc/cb710/sgbuf2.c:50:15: error: performing pointer subtraction with a null pointer has undefined behavior [-Werror,-Wnull-pointer-subtraction]
return ((ptr - NULL) & 3) != 0;
Replace this with a normal cast to uintptr_t.
Fixes: 5f5bac8272be ("mmc: Driver for CB710/720 memory card reader (MMC part)")
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20210927121408.939246-1-arnd@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/avtimer_kernel.h')
0 files changed, 0 insertions, 0 deletions
