<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/net/wireless/ti, branch v4.14.263</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v4.14.263</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v4.14.263'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2021-07-20T14:17:44+00:00</updated>
<entry>
<title>wl1251: Fix possible buffer overflow in wl1251_cmd_scan</title>
<updated>2021-07-20T14:17:44+00:00</updated>
<author>
<name>Lee Gibson</name>
<email>leegib@gmail.com</email>
</author>
<published>2021-04-28T11:55:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=0f6c0488368c9ac1aa685821916fadba32f5d1ef'/>
<id>urn:sha1:0f6c0488368c9ac1aa685821916fadba32f5d1ef</id>
<content type='text'>
[ Upstream commit d10a87a3535cce2b890897914f5d0d83df669c63 ]

Function wl1251_cmd_scan calls memcpy without checking the length.
Harden by checking the length is within the maximum allowed size.

Signed-off-by: Lee Gibson &lt;leegib@gmail.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20210428115508.25624-1-leegib@gmail.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>wlcore/wl12xx: Fix wl12xx get_mac error if device is in ELP</title>
<updated>2021-07-20T14:17:44+00:00</updated>
<author>
<name>Tony Lindgren</name>
<email>tony@atomide.com</email>
</author>
<published>2021-06-03T06:28:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6bb8e970546da4527963f3e49b362fa03d86ee81'/>
<id>urn:sha1:6bb8e970546da4527963f3e49b362fa03d86ee81</id>
<content type='text'>
[ Upstream commit 11ef6bc846dcdce838f0b00c5f6a562c57e5d43b ]

At least on wl12xx, reading the MAC after boot can fail with a warning
at drivers/net/wireless/ti/wlcore/sdio.c:78 wl12xx_sdio_raw_read.
The failed call comes from wl12xx_get_mac() that wlcore_nvs_cb() calls
after request_firmware_work_func().

After the error, no wireless interface is created. Reloading the wl12xx
module makes the interface work.

Turns out the wlan controller can be in a low-power ELP state after the
boot from the bootloader or kexec, and needs to be woken up first.

Let's wake the hardware and add a sleep after that similar to
wl12xx_pre_boot() is already doing.

Note that a similar issue could exist for wl18xx, but I have not seen it
so far. And a search for wl18xx_get_mac and wl12xx_sdio_raw_read did not
produce similar errors.

Cc: Carl Philipp Klemm &lt;philipp@uvos.xyz&gt;
Signed-off-by: Tony Lindgren &lt;tony@atomide.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20210603062814.19464-1-tony@atomide.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>wlcore: Fix command execute failure 19 for wl12xx</title>
<updated>2021-03-07T10:27:44+00:00</updated>
<author>
<name>Tony Lindgren</name>
<email>tony@atomide.com</email>
</author>
<published>2021-01-15T06:56:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=cc166012c16ed2075fbbc92f7fc415619a6d71bb'/>
<id>urn:sha1:cc166012c16ed2075fbbc92f7fc415619a6d71bb</id>
<content type='text'>
[ Upstream commit cb88d01b67383a095e3f7caeb4cdade5a6cf0417 ]

We can currently get a "command execute failure 19" error on beacon loss
if the signal is weak:

wlcore: Beacon loss detected. roles:0xff
wlcore: Connection loss work (role_id: 0).
...
wlcore: ERROR command execute failure 19
...
WARNING: CPU: 0 PID: 1552 at drivers/net/wireless/ti/wlcore/main.c:803
...
(wl12xx_queue_recovery_work.part.0 [wlcore])
(wl12xx_cmd_role_start_sta [wlcore])
(wl1271_op_bss_info_changed [wlcore])
(ieee80211_prep_connection [mac80211])

Error 19 is defined as CMD_STATUS_WRONG_NESTING from the wlcore firmware,
and seems to mean that the firmware no longer wants to see the quirk
handling for WLCORE_QUIRK_START_STA_FAILS done.

This quirk got added with commit 18eab430700d ("wlcore: workaround
start_sta problem in wl12xx fw"), and it seems that this already got fixed
in the firmware long time ago back in 2012 as wl18xx never had this quirk
in place to start with.

As we no longer even support firmware that early, to me it seems that it's
safe to just drop WLCORE_QUIRK_START_STA_FAILS to fix the error. Looks
like earlier firmware got disabled back in 2013 with commit 0e284c074ef9
("wl12xx: increase minimum singlerole firmware version required").

If it turns out we still need WLCORE_QUIRK_START_STA_FAILS with any
firmware that the driver works with, we can simply revert this patch and
add extra checks for firmware version used.

With this fix wlcore reconnects properly after a beacon loss.

Cc: Raz Bouganim &lt;r-bouganim@ti.com&gt;
Signed-off-by: Tony Lindgren &lt;tony@atomide.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20210115065613.7731-1-tony@atomide.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>wl1251: fix always return 0 error</title>
<updated>2020-08-21T07:48:11+00:00</updated>
<author>
<name>Wang Hai</name>
<email>wanghai38@huawei.com</email>
</author>
<published>2020-07-30T07:39:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=96f448206b4b6679b93a25dc30feb0ce1f996278'/>
<id>urn:sha1:96f448206b4b6679b93a25dc30feb0ce1f996278</id>
<content type='text'>
[ Upstream commit 20e6421344b5bc2f97b8e2db47b6994368417904 ]

wl1251_event_ps_report() should not always return 0 because
wl1251_ps_set_mode() may fail. Change it to return 'ret'.

Fixes: f7ad1eed4d4b ("wl1251: retry power save entry")
Reported-by: Hulk Robot &lt;hulkci@huawei.com&gt;
Signed-off-by: Wang Hai &lt;wanghai38@huawei.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20200730073939.33704-1-wanghai38@huawei.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>wlcore: Fix the return value in case of error in 'wlcore_vendor_cmd_smart_config_start()'</title>
<updated>2019-12-01T08:14:05+00:00</updated>
<author>
<name>Christophe JAILLET</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2018-10-16T07:39:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c9a9d45a69a1c4d8f8307158f22579b39a70f3d0'/>
<id>urn:sha1:c9a9d45a69a1c4d8f8307158f22579b39a70f3d0</id>
<content type='text'>
[ Upstream commit 3419348a97bcc256238101129d69b600ceb5cc70 ]

We return 0 unconditionally at the end of
'wlcore_vendor_cmd_smart_config_start()'.
However, 'ret' is set to some error codes in several error handling paths
and we already return some error codes at the beginning of the function.

Return 'ret' instead to propagate the error code.

Fixes: 80ff8063e87c ("wlcore: handle smart config vendor commands")
Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>wlcore: Fix memory leak in case wl12xx_fetch_firmware failure</title>
<updated>2019-04-05T20:31:40+00:00</updated>
<author>
<name>Zumeng Chen</name>
<email>zumeng.chen@gmail.com</email>
</author>
<published>2018-12-19T07:50:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=d2a1b60a109be0a938d7ddcc4d10da0f9e94e8e3'/>
<id>urn:sha1:d2a1b60a109be0a938d7ddcc4d10da0f9e94e8e3</id>
<content type='text'>
[ Upstream commit ba2ffc96321c8433606ceeb85c9e722b8113e5a7 ]

Release fw_status, raw_fw_status, and tx_res_if when wl12xx_fetch_firmware
failed instead of meaningless goto out to avoid the following memory leak
reports(Only the last one listed):

unreferenced object 0xc28a9a00 (size 512):
  comm "kworker/0:4", pid 31298, jiffies 2783204 (age 203.290s)
  hex dump (first 32 bytes):
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
    00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
  backtrace:
    [&lt;6624adab&gt;] kmemleak_alloc+0x40/0x74
    [&lt;500ddb31&gt;] kmem_cache_alloc_trace+0x1ac/0x270
    [&lt;db4d731d&gt;] wl12xx_chip_wakeup+0xc4/0x1fc [wlcore]
    [&lt;76c5db53&gt;] wl1271_op_add_interface+0x4a4/0x8f4 [wlcore]
    [&lt;cbf30777&gt;] drv_add_interface+0xa4/0x1a0 [mac80211]
    [&lt;65bac325&gt;] ieee80211_reconfig+0x9c0/0x1644 [mac80211]
    [&lt;2817c80e&gt;] ieee80211_restart_work+0x90/0xc8 [mac80211]
    [&lt;7e1d425a&gt;] process_one_work+0x284/0x42c
    [&lt;55f9432e&gt;] worker_thread+0x2fc/0x48c
    [&lt;abb582c6&gt;] kthread+0x148/0x160
    [&lt;63144b13&gt;] ret_from_fork+0x14/0x2c
    [&lt; (null)&gt;] (null)
    [&lt;1f6e7715&gt;] 0xffffffff

Signed-off-by: Zumeng Chen &lt;zumeng.chen@gmail.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>Revert "wlcore: Add missing PM call for wlcore_cmd_wait_for_event_or_timeout()"</title>
<updated>2018-12-05T18:41:16+00:00</updated>
<author>
<name>Sasha Levin</name>
<email>sashal@kernel.org</email>
</author>
<published>2018-12-02T15:03:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=04d269610ea35656fe4d9609f5a5fa043daa866e'/>
<id>urn:sha1:04d269610ea35656fe4d9609f5a5fa043daa866e</id>
<content type='text'>
This reverts commit e87efc44dd36ba3db59847c418354711ebad779b which was
upstream commit 4ec7cece87b3ed21ffcd407c62fb2f151a366bc1.

From Dietmar May's report on the stable mailing list
(https://www.spinics.net/lists/stable/msg272201.html):

&gt; I've run into some problems which appear due to (a) recent patch(es) on
&gt; the wlcore wifi driver.
&gt;
&gt; 4.4.160 - commit 3fdd34643ffc378b5924941fad40352c04610294
&gt; 4.9.131 - commit afeeecc764436f31d4447575bb9007732333818c
&gt;
&gt; Earlier versions (4.9.130 and 4.4.159 - tested back to 4.4.49) do not
&gt; exhibit this problem. It is still present in 4.9.141.
&gt;
&gt; master as of 4.20.0-rc4 does not exhibit this problem.
&gt;
&gt; Basically, during client association when in AP mode (running hostapd),
&gt; handshake may or may not complete following a noticeable delay. If
&gt; successful, then the driver fails consistently in warn_slowpath_null
&gt; during disassociation. If unsuccessful, the wifi client attempts multiple
&gt; times, sometimes failing repeatedly. I've had clients unable to connect
&gt; for 3-5 minutes during testing, with the syslog filled with dozens of
&gt; backtraces. syslog details are below.
&gt;
&gt; I'm working on an embedded device with a TI 3352 ARM processor and a
&gt; murata wl1271 module in sdio mode. We're running a fully patched ubuntu
&gt; 18.04 ARM build, with a kernel built from kernel.org's stable/linux repo &lt;https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-4.9.y&amp;id=afeeecc764436f31d4447575bb9007732333818c&gt;.
&gt; Relevant parts of the kernel config are included below.
&gt;
&gt; The commit message states:
&gt;
&gt; &gt; /I've only seen this few times with the runtime PM patches enabled so
&gt; &gt; this one is probably not needed before that. This seems to work
&gt; &gt; currently based on the current PM implementation timer. Let's apply
&gt; &gt; this separately though in case others are hitting this issue./
&gt; We're not doing anything explicit with power management. The device is an
&gt; IoT edge gateway with battery backup, normally running on wall power. The
&gt; battery is currently used solely to shut down the system cleanly to avoid
&gt; filesystem corruption.
&gt;
&gt; The device tree is configured to keep power in suspend; but the device
&gt; should never suspend, so in our case, there is no need to call
&gt; wl1271_ps_elp_wakeup() or wl1271_ps_elp_sleep(), as occurs in the patch.

Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>wlcore: Add missing PM call for wlcore_cmd_wait_for_event_or_timeout()</title>
<updated>2018-10-04T00:00:52+00:00</updated>
<author>
<name>Tony Lindgren</name>
<email>tony@atomide.com</email>
</author>
<published>2018-06-19T09:43:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e87efc44dd36ba3db59847c418354711ebad779b'/>
<id>urn:sha1:e87efc44dd36ba3db59847c418354711ebad779b</id>
<content type='text'>
[ Upstream commit 4ec7cece87b3ed21ffcd407c62fb2f151a366bc1 ]

Otherwise we can get:

WARNING: CPU: 0 PID: 55 at drivers/net/wireless/ti/wlcore/io.h:84

I've only seen this few times with the runtime PM patches enabled
so this one is probably not needed before that. This seems to
work currently based on the current PM implementation timer. Let's
apply this separately though in case others are hitting this issue.

Signed-off-by: Tony Lindgren &lt;tony@atomide.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wlcore: Set rx_status boottime_ns field on rx</title>
<updated>2018-09-19T20:43:41+00:00</updated>
<author>
<name>Loic Poulain</name>
<email>loic.poulain@linaro.org</email>
</author>
<published>2018-07-27T16:30:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=0e890d1cf491ee34dc82f0841f1126e5bb750b7f'/>
<id>urn:sha1:0e890d1cf491ee34dc82f0841f1126e5bb750b7f</id>
<content type='text'>
[ Upstream commit 37a634f60fd6dfbda2c312657eec7ef0750546e7 ]

When receiving a beacon or probe response, we should update the
boottime_ns field which is the timestamp the frame was received at.
(cf mac80211.h)

This fixes a scanning issue with Android since it relies on this
timestamp to determine when the AP has been seen for the last time
(via the nl80211 BSS_LAST_SEEN_BOOTTIME parameter).

Signed-off-by: Loic Poulain &lt;loic.poulain@linaro.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wlcore: sdio: check for valid platform device data before suspend</title>
<updated>2018-08-03T05:50:28+00:00</updated>
<author>
<name>Eyal Reizer</name>
<email>eyalreizer@gmail.com</email>
</author>
<published>2018-05-28T08:36:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6f8688bf299b35b5d585a96fa670ea257257fbd3'/>
<id>urn:sha1:6f8688bf299b35b5d585a96fa670ea257257fbd3</id>
<content type='text'>
[ Upstream commit 6e91d48371e79862ea2c05867aaebe4afe55a865 ]

the wl pointer can be null In case only wlcore_sdio is probed while
no WiLink module is successfully probed, as in the case of mounting a
wl12xx module while using a device tree file configured with wl18xx
related settings.
In this case the system was crashing in wl1271_suspend() as platform
device data is not set.
Make sure wl the pointer is valid before using it.

Signed-off-by: Eyal Reizer &lt;eyalr@ti.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
