android_kernel_motorola_sm6375/drivers/net
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Arnd Bergmann e7ea088cd0 ath10k: fix invalid dma_addr_t token assignment
commit 937e79c67740d1d84736730d679f3cb2552f990e upstream.

Using a kernel pointer in place of a dma_addr_t token can
lead to undefined behavior if that makes it into cache
management functions. The compiler caught one such attempt
in a cast:

drivers/net/wireless/ath/ath10k/mac.c: In function 'ath10k_add_interface':
drivers/net/wireless/ath/ath10k/mac.c:5586:47: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
 5586 |                         arvif->beacon_paddr = (dma_addr_t)arvif->beacon_buf;
      |                                               ^

Looking through how this gets used down the way, I'm fairly
sure that beacon_paddr is never accessed again for ATH10K_DEV_TYPE_HL
devices, and if it was accessed, that would be a bug.

Change the assignment to use a known-invalid address token
instead, which avoids the warning and makes it easier to catch
bugs if it does end up getting used.

Fixes: e263bdab9c0e ("ath10k: high latency fixes for beacon buffer")
Signed-off-by: Arnd Bergmann <[email protected]>
Signed-off-by: Kalle Valo <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
2021-11-17 09:48:50 +01:00
..
appletalk net: appletalk: cops: Fix data race in cops_probe1 2021-06-16 11:59:36 +02:00
arcnet
bonding bonding: Fix a use-after-free problem when bond_sysfs_slave_add() failed 2021-11-17 09:48:47 +01:00
caif net: caif: fix memory leak in ldisc_open 2021-06-30 08:47:47 -04:00
can can: peak_pci: peak_pci_remove(): fix UAF 2021-10-27 09:54:26 +02:00
dsa net: dsa: rtl8366rb: Fix off-by-one bug 2021-11-17 09:48:34 +01:00
ethernet cxgb4: fix eeprom len when diagnostics not implemented 2021-11-17 09:48:48 +01:00
fddi net: fddi: fix UAF in fza_probe 2021-07-25 14:35:15 +02:00
fjes fjes: check return value after calling platform_get_resource() 2021-07-19 08:53:10 +02:00
hamradio net: 6pack: Fix tx timeout and slot time 2021-09-30 10:09:26 +02:00
hippi
hyperv
ieee802154 ieee802154: hwsim: fix GPF in hwsim_new_edge_nl 2021-08-18 08:56:57 +02:00
ipvlan
netdevsim
phy net: phylink: avoid mvneta warning when setting pause parameters 2021-11-17 09:48:40 +01:00
plip
ppp ppp: Fix generating ifname when empty IFLA_IFNAME is specified 2021-08-18 08:56:59 +02:00
slip
team
usb net: lan78xx: fix division by zero in send path 2021-11-02 19:46:13 +01:00
vmxnet3 vmxnet3: do not stop tx queues after netif_device_detach() 2021-11-17 09:48:21 +01:00
wan
wimax
wireless ath10k: fix invalid dma_addr_t token assignment 2021-11-17 09:48:50 +01:00
xen-netback xen-netback: correct success/error reporting for the SKB-with-fraglist case 2021-10-09 14:39:49 +02:00
dummy.c
eql.c
geneve.c
gtp.c
ifb.c
Kconfig
LICENSE.SRC
loopback.c
macsec.c
macvlan.c
macvtap.c
Makefile
mdio.c
mii.c
net_failover.c
netconsole.c
nlmon.c
ntb_netdev.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tap.c
thunderbolt.c
tun.c
veth.c
virtio_net.c virtio-net: use NETIF_F_GRO_HW instead of NETIF_F_LRO 2021-08-26 08:36:18 -04:00
vrf.c vrf: run conntrack only in context of lower/physdev for locally generated packets 2021-11-17 09:48:32 +01:00
vsockmon.c
vxlan.c vxlan: add missing rcu_read_lock() in neigh_reduce() 2021-07-14 16:53:31 +02:00
xen-netfront.c xen/netfront: stop tx queues during live migration 2021-11-17 09:48:21 +01:00