linux_dsm_epyc7002/drivers/net/wireless
Luis Felipe Dominguez Vega 7c62940165 rtlwifi: Fix NULL dereference when PCI driver used as an AP
In commit 33511b157b ("rtlwifi: add support to
send beacon frame"), the mechanism for sending beacons was established. That
patch works correctly for rtl8192cu, but there is a possibility of getting
the following warnings in the PCI drivers:

WARNING: CPU: 1 PID: 2439 at net/mac80211/driver-ops.h:12
ieee80211_bss_info_change_notify+0x179/0x1d0 [mac80211]()
wlp5s0:  Failed check-sdata-in-driver check, flags: 0x0

The warning is followed by a NULL pointer dereference as follows:

BUG: unable to handle kernel NULL pointer dereference at 0000000000000006
IP: [<ffffffffc073998e>] rtl_get_tcb_desc+0x5e/0x760 [rtlwifi]

This problem was reported at http://thread.gmane.org/gmane.linux.kernel.wireless.general/138645,
but no solution was found at that time.

The problem was also reported at https://bugzilla.kernel.org/show_bug.cgi?id=9744
and this solution was developed and tested there.

The USB driver works with a NULL final argument in the adapter_tx() callback;
however, the PCI drivers need a struct rtl_tcb_desc in that position.

Fixes: 33511b157b ("rtlwifi: add support to send beacon frame.")
Signed-off-by: Luis Felipe Dominguez Vega <lfdominguez@nauta.cu>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org> [3.19+]
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-07-31 09:25:35 +03:00
..
ath ath9k_hw: fix device ID check for AR956x 2015-07-11 19:58:56 +03:00
b43 b43: fix extpa_gain check for 2GHz 2015-07-31 09:24:11 +03:00
b43legacy mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
brcm80211 Major changes: 2015-06-23 01:03:18 -07:00
cw1200 mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
hostap wireless: Use eth_<foo>_addr instead of memset 2015-03-03 17:01:36 -05:00
ipw2x00 Lots of updates for net-next; along with the usual flurry 2015-03-31 16:39:04 -04:00
iwlegacy mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
iwlwifi iwlwifi: pcie: fix stuck queue detection for sleeping clients 2015-07-30 21:38:14 +03:00
libertas cfg80211: properly send NL80211_ATTR_DISCONNECTED_BY_AP in disconnect 2015-05-26 15:21:27 +02:00
libertas_tf Minor merge needed, due to function move. 2015-07-01 10:49:25 -07:00
mediatek Major changes: 2015-06-23 01:03:18 -07:00
mwifiex mwifiex: add missing break statement in switch case 2015-06-16 11:33:16 +03:00
orinoco Lots of updates for net-next; along with the usual flurry 2015-03-31 16:39:04 -04:00
p54 mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
prism54
rsi rsi: Fix failure to load firmware after memory leak fix and fix the leak 2015-07-31 09:22:44 +03:00
rt2x00 Major changes: 2015-06-23 01:03:18 -07:00
rtl818x mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
rtlwifi rtlwifi: Fix NULL dereference when PCI driver used as an AP 2015-07-31 09:25:35 +03:00
ti Major changes: 2015-06-23 01:03:18 -07:00
zd1211rw mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
adm8211.c mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
adm8211.h
airo_cs.c
airo.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2015-04-15 09:00:47 -07:00
airo.h
at76c50x-usb.c mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
at76c50x-usb.h mac80211: remove support for IFF_PROMISC 2015-04-24 11:14:13 +02:00
atmel_cs.c
atmel_pci.c
atmel.c wireless: Use eth_<foo>_addr instead of memset 2015-03-03 17:01:36 -05:00
atmel.h
Kconfig add mt7601u driver 2015-05-28 11:33:20 +03:00
mac80211_hwsim.c mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
mac80211_hwsim.h
Makefile add mt7601u driver 2015-05-28 11:33:20 +03:00
mwl8k.c mac80211: convert HW flags to unsigned long bitmap 2015-06-10 16:05:36 +02:00
ray_cs.c ray_cs: Change 1 to true for bool type variable. 2015-06-02 23:30:14 +03:00
ray_cs.h
rayctl.h
rndis_wlan.c new driver mt7601u for MediaTek Wi-Fi devices MT7601U 2015-06-03 23:44:57 -07:00
wl3501_cs.c
wl3501.h
zd1201.c
zd1201.h