linux-stable/drivers/misc
Arnd Bergmann cf79c98d52 cb710: avoid NULL pointer subtraction
commit 42641042c1 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: 5f5bac8272 ("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>
2021-10-20 10:42:03 +02:00
..
altera-stapl altera-stapl: altera_get_note: prevent write beyond end of 'key' 2020-04-02 16:34:14 +02:00
c2port
cb710 cb710: avoid NULL pointer subtraction 2021-10-20 10:42:03 +02:00
cxl cxl: Fix kobject memleak 2020-08-21 09:48:08 +02:00
echo misc: echo: Remove unnecessary parentheses and simplify check for zero 2020-04-24 08:00:51 +02:00
eeprom eeprom: idt_89hpesx: Put fwnode in matching case during ->probe() 2021-07-20 16:17:40 +02:00
genwqe
ibmasm misc/libmasm/module: Fix two use after free in ibmasm_init_one 2021-07-20 16:17:48 +02:00
lis3lv02d platform/x86: hp_accel: Avoid invoking _INI to speed up resume 2021-06-03 08:36:20 +02:00
mei mei: request autosuspend after sending rx flow control 2021-06-03 08:36:16 +02:00
mic misc: vop: add round_up(x,4) for vring_size to avoid kernel panic 2020-10-29 09:07:17 +01:00
sgi-gru
sgi-xp
ti-st
vmw_vmci VMCI: fix NULL pointer dereference when unmapping queue pair 2021-09-22 11:45:25 +02:00
ad525x_dpot-i2c.c
ad525x_dpot-spi.c
ad525x_dpot.c
ad525x_dpot.h
apds990x.c
apds9802als.c
aspeed-lpc-ctrl.c soc: aspeed: lpc-ctrl: Fix boundary check for mmap 2021-09-22 11:45:24 +02:00
aspeed-lpc-snoop.c
atmel-ssc.c misc: atmel-ssc: lock with mutex instead of spinlock 2020-07-22 09:22:28 +02:00
atmel_tclib.c
bh1770glc.c
cs5535-mfgpt.c
ds1682.c
dummy-irq.c
enclosure.c
fsa9480.c
hmc6352.c
hpilo.c
hpilo.h
ics932s401.c
ioc4.c
isl29003.c
isl29020.c
Kconfig
kgdbts.c kgdb: fix gcc-11 warnings harder 2021-06-03 08:36:15 +02:00
lattice-ecp3-config.c
lkdtm.h
lkdtm_bugs.c
lkdtm_core.c
lkdtm_heap.c
lkdtm_perms.c
lkdtm_refcount.c
lkdtm_rodata.c
lkdtm_usercopy.c
Makefile
pch_phub.c
pci_endpoint_test.c misc: pci_endpoint_test: Fix to support > 10 pci-endpoint-test devices 2020-04-13 10:34:24 +02:00
phantom.c
pti.c
qcom-coincell.c
spear13xx_pcie_gadget.c
sram-exec.c
sram.c
sram.h
ti_dac7512.c
tifm_7xx1.c
tifm_core.c
tsl2550.c
vexpress-syscfg.c
vmw_balloon.c