<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/drivers/staging/rtl8723bs, branch v5.11</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>staging: rtl8723bs: Move wiphy setup to after reading the regulatory settings from the chip</title>
<updated>2021-02-01T18:26:10+00:00</updated>
<author>
<name>Hans de Goede</name>
<email>hdegoede@redhat.com</email>
</author>
<published>2021-02-01T15:29:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=50af06d43eab6b09afc37aa7c8bbf69b14a3b2f7'/>
<id>50af06d43eab6b09afc37aa7c8bbf69b14a3b2f7</id>
<content type='text'>
Commit 81f153faacd0 ("staging: rtl8723bs: fix wireless regulatory API
misuse") moved the wiphy_apply_custom_regulatory() call to earlier in the
driver's init-sequence, so that it gets called before wiphy_register().

But at this point in time the eFuses which code the regulatory-settings
for the chip have not been read by the driver yet, causing
_rtw_reg_apply_flags() to set the IEEE80211_CHAN_DISABLED flag on *all*
channels.

On the device where I initially tested the fix, a Jumper EZpad 7 tablet,
this does not cause any problems because shortly after init the
rtw_reg_notifier() gets called fixing things up. I guess this happens
into response to receiving a (broadcast) packet with regulatory info
from the access-point ?

But on another device with a RTL8723BS wifi chip, an Acer Switch 10E
(SW3-016), the rtw_reg_notifier() never gets called. I assume that some
fuse has been set on this device to ignore regulatory info received from
access-points.

This means that on the Acer the driver is stuck in a state with all
channels disabled, leading to non working Wifi.

We cannot move the wiphy_apply_custom_regulatory() call back, because
that call must be made before the wiphy_register() call.

Instead move the entire rtw_wdev_alloc() call to after the Efuses have
been read, fixing all channels being disabled in the initial channel-map.

Fixes: 81f153faacd0 ("staging: rtl8723bs: fix wireless regulatory API misuse")
Cc: Johannes Berg &lt;johannes.berg@intel.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Link: https://lore.kernel.org/r/20210201152956.370186-2-hdegoede@redhat.com
Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 81f153faacd0 ("staging: rtl8723bs: fix wireless regulatory API
misuse") moved the wiphy_apply_custom_regulatory() call to earlier in the
driver's init-sequence, so that it gets called before wiphy_register().

But at this point in time the eFuses which code the regulatory-settings
for the chip have not been read by the driver yet, causing
_rtw_reg_apply_flags() to set the IEEE80211_CHAN_DISABLED flag on *all*
channels.

On the device where I initially tested the fix, a Jumper EZpad 7 tablet,
this does not cause any problems because shortly after init the
rtw_reg_notifier() gets called fixing things up. I guess this happens
into response to receiving a (broadcast) packet with regulatory info
from the access-point ?

But on another device with a RTL8723BS wifi chip, an Acer Switch 10E
(SW3-016), the rtw_reg_notifier() never gets called. I assume that some
fuse has been set on this device to ignore regulatory info received from
access-points.

This means that on the Acer the driver is stuck in a state with all
channels disabled, leading to non working Wifi.

We cannot move the wiphy_apply_custom_regulatory() call back, because
that call must be made before the wiphy_register() call.

Instead move the entire rtw_wdev_alloc() call to after the Efuses have
been read, fixing all channels being disabled in the initial channel-map.

Fixes: 81f153faacd0 ("staging: rtl8723bs: fix wireless regulatory API misuse")
Cc: Johannes Berg &lt;johannes.berg@intel.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Link: https://lore.kernel.org/r/20210201152956.370186-2-hdegoede@redhat.com
Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: fix wireless regulatory API misuse</title>
<updated>2021-01-26T11:21:42+00:00</updated>
<author>
<name>Johannes Berg</name>
<email>johannes.berg@intel.com</email>
</author>
<published>2021-01-26T10:54:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=81f153faacd04c049e5482d6ff33daddc30ed44e'/>
<id>81f153faacd04c049e5482d6ff33daddc30ed44e</id>
<content type='text'>
This code ends up calling wiphy_apply_custom_regulatory(), for which
we document that it should be called before wiphy_register(). This
driver doesn't do that, but calls it from ndo_open() with the RTNL
held, which caused deadlocks.

Since the driver just registers static regdomain data and then the
notifier applies the channel changes if any, there's no reason for
it to call this in ndo_open(), move it earlier to fix the deadlock.

Reported-and-tested-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Fixes: 51d62f2f2c50 ("cfg80211: Save the regulatory domain with a lock")
Link: https://lore.kernel.org/r/20210126115409.d5fd6f8fe042.Ib5823a6feb2e2aa01ca1a565d2505367f38ad246@changeid
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This code ends up calling wiphy_apply_custom_regulatory(), for which
we document that it should be called before wiphy_register(). This
driver doesn't do that, but calls it from ndo_open() with the RTNL
held, which caused deadlocks.

Since the driver just registers static regdomain data and then the
notifier applies the channel changes if any, there's no reason for
it to call this in ndo_open(), move it earlier to fix the deadlock.

Reported-and-tested-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Fixes: 51d62f2f2c50 ("cfg80211: Save the regulatory domain with a lock")
Link: https://lore.kernel.org/r/20210126115409.d5fd6f8fe042.Ib5823a6feb2e2aa01ca1a565d2505367f38ad246@changeid
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: remove ELEMENT_ID enum</title>
<updated>2020-12-08T08:55:52+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8764c27fbd2f257405853e73bf3a6b44920a20ab'/>
<id>8764c27fbd2f257405853e73bf3a6b44920a20ab</id>
<content type='text'>
The ELEMENT_ID enum is no longer used, remove it.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-22-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The ELEMENT_ID enum is no longer used, remove it.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-22-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: remove unused macros</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=a228b401951ebe188be09d77c3ab80c4f5a7a96c'/>
<id>a228b401951ebe188be09d77c3ab80c4f5a7a96c</id>
<content type='text'>
Remove many macros from wifi.h and ieee80211.h because they are unused.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-21-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove many macros from wifi.h and ieee80211.h because they are unused.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-21-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: replace EID_EXTCapability</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=5b45010f2ef9cb7001d2e29cde9aacf67dc0e02e'/>
<id>5b45010f2ef9cb7001d2e29cde9aacf67dc0e02e</id>
<content type='text'>
Replace unique EID_EXTCapability constant with kernel provided
WLAN_EID_EXT_CAPABILITY from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-20-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace unique EID_EXTCapability constant with kernel provided
WLAN_EID_EXT_CAPABILITY from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-20-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: replace EID_BSSIntolerantChlReport</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=d7ca2c3d2d47942f224107c754a008c30826ba88'/>
<id>d7ca2c3d2d47942f224107c754a008c30826ba88</id>
<content type='text'>
Replace unique EID_BSSIntolerantChlReport constant with kernel provided
WLAN_EID_BSS_INTOLERANT_CHL_REPORT from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-19-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace unique EID_BSSIntolerantChlReport constant with kernel provided
WLAN_EID_BSS_INTOLERANT_CHL_REPORT from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-19-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: replace EID_BSSCoexistence</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=9b5d8c1fe14bf445fe324505d451b4ddc5a68a8d'/>
<id>9b5d8c1fe14bf445fe324505d451b4ddc5a68a8d</id>
<content type='text'>
Replace unique EID_BSSCoexistence constant with kernel provided
WLAN_EID_BSS_COEX_2040 from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-18-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace unique EID_BSSCoexistence constant with kernel provided
WLAN_EID_BSS_COEX_2040 from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-18-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: replace _MME_IE_</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=99bb776980eeb231558a6ede0a1dd8d1a6e8ec0c'/>
<id>99bb776980eeb231558a6ede0a1dd8d1a6e8ec0c</id>
<content type='text'>
Replace unique _MME_IE_ macro with kernel provided WLAN_EID_MMIE from
linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-17-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace unique _MME_IE_ macro with kernel provided WLAN_EID_MMIE from
linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-17-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: replace _WAPI_IE_</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=fc41e9618fc65bea5d615d487ca7de3b0e1110bc'/>
<id>fc41e9618fc65bea5d615d487ca7de3b0e1110bc</id>
<content type='text'>
Replace unique _WAPI_IE_ macro with kernel provided
WLAN_EID_BSS_AC_ACCESS_DELAY from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-16-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace unique _WAPI_IE_ macro with kernel provided
WLAN_EID_BSS_AC_ACCESS_DELAY from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-16-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: rtl8723bs: replace _EXT_SUPPORTEDRATES_IE_</title>
<updated>2020-12-08T08:55:51+00:00</updated>
<author>
<name>Ross Schmidt</name>
<email>ross.schm.dev@gmail.com</email>
</author>
<published>2020-12-08T04:07:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=00f0b682841337c4d2e7dd2e75d86acb6b7ce2d8'/>
<id>00f0b682841337c4d2e7dd2e75d86acb6b7ce2d8</id>
<content type='text'>
Replace unique _EXT_SUPPORTEDRATES_IE_ macro with kernel provided
WLAN_EID_EXT_SUPP_RATES from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-15-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace unique _EXT_SUPPORTEDRATES_IE_ macro with kernel provided
WLAN_EID_EXT_SUPP_RATES from linux/ieee80211.h.

Signed-off-by: Ross Schmidt &lt;ross.schm.dev@gmail.com&gt;
Link: https://lore.kernel.org/r/20201208040733.379197-15-ross.schm.dev@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
