All of lore.kernel.org
 help / color / mirror / Atom feed
* [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
@ 2018-08-23 17:30 prabhu
  2018-08-23 18:11 ` Michael Büsch
  2018-08-23 19:20 ` Larry Finger
  0 siblings, 2 replies; 12+ messages in thread
From: prabhu @ 2018-08-23 17:30 UTC (permalink / raw)
  To: linux-wireless, b43-dev

Hi,

BCM 4312 wifi card stopped working from kernel version 4.18
After boot up it tries to reconnect for few times and after that it
disconnected completely.

Here is the snippet from dmesg:
[ 70.826051] [drm:radeon_cs_parser_relocs [radeon]] *ERROR* gem object
lookup failed 0xd
[ 70.826090] [drm:radeon_cs_ioctl [radeon]] *ERROR* Failed to parse
relocation -2!
[ 238.066341] b43-phy0: Controller RESET (Out of order TX) ...
[ 238.306116] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 245.443095] b43-phy0: Controller restarted
[ 285.552662] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
6=CLASS2_FRAME_FROM_NONAUTH_STA)
[ 285.639719] wlan0: authenticate with 98:de:d0:4b:e6:f6
[ 285.656291] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
[ 285.658957] wlan0: authenticated
[ 285.662386] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
[ 285.665581] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
status=0 aid=2)
[ 285.666396] wlan0: associated
[ 309.348063] b43-phy0: Controller RESET (Out of order TX) ...
[ 309.592485] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 316.742829] b43-phy0: Controller restarted
[ 329.268570] perf: interrupt took too long (2513 > 2500), lowering
kernel.perf_event_max_sample_rate to 79500
[ 400.542426] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
6=CLASS2_FRAME_FROM_NONAUTH_STA)
[ 400.636523] wlan0: authenticate with 98:de:d0:4b:e6:f6
[ 400.652666] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
[ 400.655070] wlan0: authenticated
[ 400.655447] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
[ 400.658583] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
status=0 aid=2)
[ 400.659276] wlan0: associated
[ 412.256359] perf: interrupt took too long (3246 > 3141), lowering
kernel.perf_event_max_sample_rate to 61500
[ 555.832079] b43-phy0: Controller RESET (Out of order TX) ...
[ 556.082050] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 563.172269] b43-phy0: Controller restarted
[ 619.628212] perf: interrupt took too long (4066 > 4057), lowering
kernel.perf_event_max_sample_rate to 48900
[ 766.268349] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
6=CLASS2_FRAME_FROM_NONAUTH_STA)
[ 766.317708] wlan0: authenticate with 98:de:d0:4b:e6:f6
[ 766.338515] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
[ 766.345731] wlan0: authenticated
[ 766.347959] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
[ 766.352674] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
status=0 aid=2)
[ 766.353351] wlan0: associated
[ 801.234010] perf: interrupt took too long (5097 > 5082), lowering
kernel.perf_event_max_sample_rate to 39000
[ 1780.122837] perf: interrupt took too long (6979 > 6371), lowering
kernel.perf_event_max_sample_rate to 28500
[ 2347.465072] b43-phy0: Controller RESET (Out of order TX) ...
[ 2347.705572] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 2354.735641] b43-phy0: Controller restarted
[ 2388.784785] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
6=CLASS2_FRAME_FROM_NONAUTH_STA)
[ 2388.901388] wlan0: authenticate with 98:de:d0:4b:e6:f6
[ 2388.918575] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
[ 2388.920893] wlan0: authenticated
[ 2388.921243] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
[ 2388.924310] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
status=0 aid=2)
[ 2388.925336] wlan0: associated
[ 2973.297286] b43-phy0: Controller RESET (Out of order TX) ...
[ 2973.532792] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 2980.496495] b43-phy0: Controller restarted
[ 5306.648339] wlan0: deauthenticating from 98:de:d0:4b:e6:f6 by local
choice (Reason: 3=DEAUTH_LEAVING)
[ 5306.909377] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 5313.899248] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[ 5320.225907] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
[ 5327.189103] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[ 5328.567334] wlan0: authenticate with 98:de:d0:4b:e6:f6
[ 5328.599382] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
[ 5328.601751] wlan0: authenticated
[ 5328.602238] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
[ 5328.605468] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
status=0 aid=2)
[ 5328.606369] wlan0: associated
[ 5328.615757] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
[ 5348.732714] b43-phy0: Controller RESET (Out of order TX) ...

The following commits introduce this regression in 4.18
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=66cffd6daab76caebab26eb803b92182414fc182

I verified that in two ways:
1. Downgrade the kernel to 4.17.14 - Fixes the Issue
2. Revert that commit in 4.18.4 - Fixes the Issue

Regards,
D.Prabhu

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-23 17:30 [Regression]BCM4312 is broken in kernel 4.18[Root cause found] prabhu
@ 2018-08-23 18:11 ` Michael Büsch
  2018-08-24  8:23   ` Kalle Valo
  2018-08-23 19:20 ` Larry Finger
  1 sibling, 1 reply; 12+ messages in thread
From: Michael Büsch @ 2018-08-23 18:11 UTC (permalink / raw)
  To: Kalle Valo; +Cc: prabhu, linux-wireless, b43-dev

[-- Attachment #1: Type: text/plain, Size: 366 bytes --]

On Thu, 23 Aug 2018 23:00:53 +0530
prabhu <d.praabhu@gmail.com> wrote:

> The following commits introduce this regression in 4.18
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=66cffd6daab76caebab26eb803b92182414fc182


Ok. Kalle, can you please revert the commit
66cffd6daab76caebab26eb803b92182414fc182
?

-- 
Michael

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-23 17:30 [Regression]BCM4312 is broken in kernel 4.18[Root cause found] prabhu
  2018-08-23 18:11 ` Michael Büsch
@ 2018-08-23 19:20 ` Larry Finger
  2018-08-24  7:54   ` prabhu
  1 sibling, 1 reply; 12+ messages in thread
From: Larry Finger @ 2018-08-23 19:20 UTC (permalink / raw)
  To: prabhu, linux-wireless, b43-dev

[-- Attachment #1: Type: text/plain, Size: 5801 bytes --]

On 08/23/2018 12:30 PM, prabhu wrote:
> Hi,
> 
> BCM 4312 wifi card stopped working from kernel version 4.18
> After boot up it tries to reconnect for few times and after that it
> disconnected completely.
> 
> Here is the snippet from dmesg:
> [ 70.826051] [drm:radeon_cs_parser_relocs [radeon]] *ERROR* gem object
> lookup failed 0xd
> [ 70.826090] [drm:radeon_cs_ioctl [radeon]] *ERROR* Failed to parse
> relocation -2!
> [ 238.066341] b43-phy0: Controller RESET (Out of order TX) ...
> [ 238.306116] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 245.443095] b43-phy0: Controller restarted
> [ 285.552662] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> [ 285.639719] wlan0: authenticate with 98:de:d0:4b:e6:f6
> [ 285.656291] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> [ 285.658957] wlan0: authenticated
> [ 285.662386] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> [ 285.665581] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> status=0 aid=2)
> [ 285.666396] wlan0: associated
> [ 309.348063] b43-phy0: Controller RESET (Out of order TX) ...
> [ 309.592485] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 316.742829] b43-phy0: Controller restarted
> [ 329.268570] perf: interrupt took too long (2513 > 2500), lowering
> kernel.perf_event_max_sample_rate to 79500
> [ 400.542426] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> [ 400.636523] wlan0: authenticate with 98:de:d0:4b:e6:f6
> [ 400.652666] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> [ 400.655070] wlan0: authenticated
> [ 400.655447] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> [ 400.658583] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> status=0 aid=2)
> [ 400.659276] wlan0: associated
> [ 412.256359] perf: interrupt took too long (3246 > 3141), lowering
> kernel.perf_event_max_sample_rate to 61500
> [ 555.832079] b43-phy0: Controller RESET (Out of order TX) ...
> [ 556.082050] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 563.172269] b43-phy0: Controller restarted
> [ 619.628212] perf: interrupt took too long (4066 > 4057), lowering
> kernel.perf_event_max_sample_rate to 48900
> [ 766.268349] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> [ 766.317708] wlan0: authenticate with 98:de:d0:4b:e6:f6
> [ 766.338515] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> [ 766.345731] wlan0: authenticated
> [ 766.347959] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> [ 766.352674] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> status=0 aid=2)
> [ 766.353351] wlan0: associated
> [ 801.234010] perf: interrupt took too long (5097 > 5082), lowering
> kernel.perf_event_max_sample_rate to 39000
> [ 1780.122837] perf: interrupt took too long (6979 > 6371), lowering
> kernel.perf_event_max_sample_rate to 28500
> [ 2347.465072] b43-phy0: Controller RESET (Out of order TX) ...
> [ 2347.705572] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 2354.735641] b43-phy0: Controller restarted
> [ 2388.784785] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> [ 2388.901388] wlan0: authenticate with 98:de:d0:4b:e6:f6
> [ 2388.918575] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> [ 2388.920893] wlan0: authenticated
> [ 2388.921243] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> [ 2388.924310] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> status=0 aid=2)
> [ 2388.925336] wlan0: associated
> [ 2973.297286] b43-phy0: Controller RESET (Out of order TX) ...
> [ 2973.532792] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 2980.496495] b43-phy0: Controller restarted
> [ 5306.648339] wlan0: deauthenticating from 98:de:d0:4b:e6:f6 by local
> choice (Reason: 3=DEAUTH_LEAVING)
> [ 5306.909377] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 5313.899248] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
> [ 5320.225907] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> [ 5327.189103] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
> [ 5328.567334] wlan0: authenticate with 98:de:d0:4b:e6:f6
> [ 5328.599382] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> [ 5328.601751] wlan0: authenticated
> [ 5328.602238] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> [ 5328.605468] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> status=0 aid=2)
> [ 5328.606369] wlan0: associated
> [ 5328.615757] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
> [ 5348.732714] b43-phy0: Controller RESET (Out of order TX) ...
> 
> The following commits introduce this regression in 4.18
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=66cffd6daab76caebab26eb803b92182414fc182
> 
> I verified that in two ways:
> 1. Downgrade the kernel to 4.17.14 - Fixes the Issue
> 2. Revert that commit in 4.18.4 - Fixes the Issue

Prabhu,

Thanks for your diagnosis of the problem.

Unfortunately, I was not able to reproduce your problem with my BCM4312 using 
kernel 4.18. The only difference  I could see is that I am using firmware 
version 784.2 rather than 666.2, which you are using. I do not think there was 
any difference for LP cores, thus I doubt that the differing versions makes any 
difference, but I would like you to see if you can update the firmware. If your 
distro does not support newer firmware, let me know and I can send you a couple 
of files needed to do an update.

If updating the firmware does not help, then please try the attached patch for 
mainline 4.18. It uses the controller reset from the offending patch, but limits 
the resets to once every 40 out-of-order reports.

Larry


[-- Attachment #2: trial_fix_for_b43.patch --]
[-- Type: text/x-patch, Size: 1807 bytes --]

diff --git a/drivers/net/wireless/broadcom/b43/dma.c b/drivers/net/wireless/broadcom/b43/dma.c
index 6b0e1ec346cb..8291965518ae 100644
--- a/drivers/net/wireless/broadcom/b43/dma.c
+++ b/drivers/net/wireless/broadcom/b43/dma.c
@@ -1484,7 +1484,7 @@ void b43_dma_handle_txstatus(struct b43_wldev *dev,
 	int slot, firstused;
 	bool frame_succeed;
 	int skip;
-	static u8 err_out1;
+	static u8 err_out1, err_out2;
 
 	ring = parse_cookie(dev, status->cookie, &slot);
 	if (unlikely(!ring))
@@ -1519,12 +1519,16 @@ void b43_dma_handle_txstatus(struct b43_wldev *dev,
 		} else {
 			/* More than a single header/data pair were missed.
 			 * Report this error, and reset the controller to
-			 * revive operation.
+			 * revive operation. Do this only every 40 such errors.
 			 */
-			b43dbg(dev->wl,
-			       "Out of order TX status report on DMA ring %d. Expected %d, but got %d\n",
-			       ring->index, firstused, slot);
-			b43_controller_restart(dev, "Out of order TX");
+			if (!err_out2) {
+				b43dbg(dev->wl,
+				       "Out of order TX status report on DMA ring %d. Expected %d, but got %d\n",
+				       ring->index, firstused, slot);
+			}
+			if (!(err_out2 % 40))
+				b43_controller_restart(dev, "Out of order TX");
+			err_out2 += 1;
 			return;
 		}
 	}
diff --git a/drivers/staging/rtl8192e/rtllib_module.c b/drivers/staging/rtl8192e/rtllib_module.c
index cdf4c9060c51..834896be0022 100644
--- a/drivers/staging/rtl8192e/rtllib_module.c
+++ b/drivers/staging/rtl8192e/rtllib_module.c
@@ -95,6 +95,7 @@ struct net_device *alloc_rtllib(int sizeof_priv)
 		pr_err("Unable to allocate net_device.\n");
 		return NULL;
 	}
+	strcpy(dev->name, "wlan%d");
 	ieee = (struct rtllib_device *)netdev_priv_rsl(dev);
 	memset(ieee, 0, sizeof(struct rtllib_device)+sizeof_priv);
 	ieee->dev = dev;

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-23 19:20 ` Larry Finger
@ 2018-08-24  7:54   ` prabhu
  0 siblings, 0 replies; 12+ messages in thread
From: prabhu @ 2018-08-24  7:54 UTC (permalink / raw)
  To: Larry.Finger; +Cc: linux-wireless, b43-dev

Larry,

I am using archlinux and in their wiki they specifically mentioned to
not update firmware for BCM4312.
https://wiki.archlinux.org/index.php/broadcom_wireless

>From the build script I can see that I am using version
"broadcom-wl-5.100.138.tar.bz2."
And I guess, you ask me to update to version
"broadcom-wl-6.30.163.46.tar.bz2", which they suggest not to do.

This is the reason I stick with older FW version.

So my question is,
do you still want me to update the firmware or try with the attached patch?
On Fri, Aug 24, 2018 at 12:50 AM Larry Finger <Larry.Finger@lwfinger.net> wrote:
>
> On 08/23/2018 12:30 PM, prabhu wrote:
> > Hi,
> >
> > BCM 4312 wifi card stopped working from kernel version 4.18
> > After boot up it tries to reconnect for few times and after that it
> > disconnected completely.
> >
> > Here is the snippet from dmesg:
> > [ 70.826051] [drm:radeon_cs_parser_relocs [radeon]] *ERROR* gem object
> > lookup failed 0xd
> > [ 70.826090] [drm:radeon_cs_ioctl [radeon]] *ERROR* Failed to parse
> > relocation -2!
> > [ 238.066341] b43-phy0: Controller RESET (Out of order TX) ...
> > [ 238.306116] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 245.443095] b43-phy0: Controller restarted
> > [ 285.552662] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> > 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> > [ 285.639719] wlan0: authenticate with 98:de:d0:4b:e6:f6
> > [ 285.656291] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 285.658957] wlan0: authenticated
> > [ 285.662386] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 285.665581] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> > status=0 aid=2)
> > [ 285.666396] wlan0: associated
> > [ 309.348063] b43-phy0: Controller RESET (Out of order TX) ...
> > [ 309.592485] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 316.742829] b43-phy0: Controller restarted
> > [ 329.268570] perf: interrupt took too long (2513 > 2500), lowering
> > kernel.perf_event_max_sample_rate to 79500
> > [ 400.542426] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> > 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> > [ 400.636523] wlan0: authenticate with 98:de:d0:4b:e6:f6
> > [ 400.652666] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 400.655070] wlan0: authenticated
> > [ 400.655447] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 400.658583] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> > status=0 aid=2)
> > [ 400.659276] wlan0: associated
> > [ 412.256359] perf: interrupt took too long (3246 > 3141), lowering
> > kernel.perf_event_max_sample_rate to 61500
> > [ 555.832079] b43-phy0: Controller RESET (Out of order TX) ...
> > [ 556.082050] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 563.172269] b43-phy0: Controller restarted
> > [ 619.628212] perf: interrupt took too long (4066 > 4057), lowering
> > kernel.perf_event_max_sample_rate to 48900
> > [ 766.268349] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> > 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> > [ 766.317708] wlan0: authenticate with 98:de:d0:4b:e6:f6
> > [ 766.338515] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 766.345731] wlan0: authenticated
> > [ 766.347959] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 766.352674] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> > status=0 aid=2)
> > [ 766.353351] wlan0: associated
> > [ 801.234010] perf: interrupt took too long (5097 > 5082), lowering
> > kernel.perf_event_max_sample_rate to 39000
> > [ 1780.122837] perf: interrupt took too long (6979 > 6371), lowering
> > kernel.perf_event_max_sample_rate to 28500
> > [ 2347.465072] b43-phy0: Controller RESET (Out of order TX) ...
> > [ 2347.705572] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 2354.735641] b43-phy0: Controller restarted
> > [ 2388.784785] wlan0: deauthenticated from 98:de:d0:4b:e6:f6 (Reason:
> > 6=CLASS2_FRAME_FROM_NONAUTH_STA)
> > [ 2388.901388] wlan0: authenticate with 98:de:d0:4b:e6:f6
> > [ 2388.918575] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 2388.920893] wlan0: authenticated
> > [ 2388.921243] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 2388.924310] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> > status=0 aid=2)
> > [ 2388.925336] wlan0: associated
> > [ 2973.297286] b43-phy0: Controller RESET (Out of order TX) ...
> > [ 2973.532792] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 2980.496495] b43-phy0: Controller restarted
> > [ 5306.648339] wlan0: deauthenticating from 98:de:d0:4b:e6:f6 by local
> > choice (Reason: 3=DEAUTH_LEAVING)
> > [ 5306.909377] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 5313.899248] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
> > [ 5320.225907] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
> > [ 5327.189103] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
> > [ 5328.567334] wlan0: authenticate with 98:de:d0:4b:e6:f6
> > [ 5328.599382] wlan0: send auth to 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 5328.601751] wlan0: authenticated
> > [ 5328.602238] wlan0: associate with 98:de:d0:4b:e6:f6 (try 1/3)
> > [ 5328.605468] wlan0: RX AssocResp from 98:de:d0:4b:e6:f6 (capab=0x431
> > status=0 aid=2)
> > [ 5328.606369] wlan0: associated
> > [ 5328.615757] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
> > [ 5348.732714] b43-phy0: Controller RESET (Out of order TX) ...
> >
> > The following commits introduce this regression in 4.18
> > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=66cffd6daab76caebab26eb803b92182414fc182
> >
> > I verified that in two ways:
> > 1. Downgrade the kernel to 4.17.14 - Fixes the Issue
> > 2. Revert that commit in 4.18.4 - Fixes the Issue
>
> Prabhu,
>
> Thanks for your diagnosis of the problem.
>
> Unfortunately, I was not able to reproduce your problem with my BCM4312 using
> kernel 4.18. The only difference  I could see is that I am using firmware
> version 784.2 rather than 666.2, which you are using. I do not think there was
> any difference for LP cores, thus I doubt that the differing versions makes any
> difference, but I would like you to see if you can update the firmware. If your
> distro does not support newer firmware, let me know and I can send you a couple
> of files needed to do an update.
>
> If updating the firmware does not help, then please try the attached patch for
> mainline 4.18. It uses the controller reset from the offending patch, but limits
> the resets to once every 40 out-of-order reports.
>
> Larry
>

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-23 18:11 ` Michael Büsch
@ 2018-08-24  8:23   ` Kalle Valo
  2018-08-24 16:15     ` Larry Finger
  0 siblings, 1 reply; 12+ messages in thread
From: Kalle Valo @ 2018-08-24  8:23 UTC (permalink / raw)
  To: Michael Büsch; +Cc: prabhu, linux-wireless, b43-dev

Michael B=C3=BCsch <m@bues.ch> writes:

> On Thu, 23 Aug 2018 23:00:53 +0530
> prabhu <d.praabhu@gmail.com> wrote:
>
>> The following commits introduce this regression in 4.18
>> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commi=
t/?id=3D66cffd6daab76caebab26eb803b92182414fc182
>
> Ok. Kalle, can you please revert the commit
> 66cffd6daab76caebab26eb803b92182414fc182
> ?

Please submit a proper patch with an explanation why it needs to be
reverted.

--=20
Kalle Valo

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-24  8:23   ` Kalle Valo
@ 2018-08-24 16:15     ` Larry Finger
  2018-08-26  7:23       ` prabhu
  0 siblings, 1 reply; 12+ messages in thread
From: Larry Finger @ 2018-08-24 16:15 UTC (permalink / raw)
  To: Kalle Valo, Michael Büsch; +Cc: prabhu, linux-wireless, b43-dev

On 08/24/2018 03:23 AM, Kalle Valo wrote:
> Michael Büsch <m@bues.ch> writes:
> 
>> On Thu, 23 Aug 2018 23:00:53 +0530
>> prabhu <d.praabhu@gmail.com> wrote:
>>
>>> The following commits introduce this regression in 4.18
>>> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=66cffd6daab76caebab26eb803b92182414fc182
>>
>> Ok. Kalle, can you please revert the commit
>> 66cffd6daab76caebab26eb803b92182414fc182
>> ?
> 
> Please submit a proper patch with an explanation why it needs to be
> reverted.

Before doing a revert, let's see if we can keep the fix for open firmware, the 
situation for which commit 66cffd6daab7 was "needed". I think the following 
should do:

diff --git a/drivers/net/wireless/broadcom/b43/dma.c 
b/drivers/net/wireless/broadcom/b43/dma.c
index 6b0e1ec346cb..2c37366b3592 100644
--- a/drivers/net/wireless/broadcom/b43/dma.c
+++ b/drivers/net/wireless/broadcom/b43/dma.c
@@ -1519,12 +1519,14 @@ void b43_dma_handle_txstatus(struct b43_wldev *dev,
                 } else {
                         /* More than a single header/data pair were missed.
                          * Report this error, and reset the controller to
-                        * revive operation.
+                        * revive operation. If running the open-source
+                        * firmware, then do a restart.
                          */
                         b43dbg(dev->wl,
                                "Out of order TX status report on DMA ring %d. 
Expected %d, but got %d\n",
                                ring->index, firstused, slot);
-                       b43_controller_restart(dev, "Out of order TX");
+                       if (dev->fw.opensource)
+                               b43_controller_restart(dev, "Out of order TX");
                         return;
                 }
         }

At the moment, I am working with prabhu to see if upgrading his firmware will 
help his problem with no change in the driver. If not, then I will have him test 
this patch.

Larry

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-24 16:15     ` Larry Finger
@ 2018-08-26  7:23       ` prabhu
  2018-08-26 16:14         ` Larry Finger
  0 siblings, 1 reply; 12+ messages in thread
From: prabhu @ 2018-08-26  7:23 UTC (permalink / raw)
  To: Larry.Finger; +Cc: kvalo, m, linux-wireless, b43-dev

Larry,

Upgrading the firmware didn't fix the issue.

The patch fixes it. My system has been running without any issues
since yesterday.
On Fri, Aug 24, 2018 at 9:45 PM Larry Finger <Larry.Finger@lwfinger.net> wr=
ote:
>
> On 08/24/2018 03:23 AM, Kalle Valo wrote:
> > Michael B=C3=BCsch <m@bues.ch> writes:
> >
> >> On Thu, 23 Aug 2018 23:00:53 +0530
> >> prabhu <d.praabhu@gmail.com> wrote:
> >>
> >>> The following commits introduce this regression in 4.18
> >>> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/co=
mmit/?id=3D66cffd6daab76caebab26eb803b92182414fc182
> >>
> >> Ok. Kalle, can you please revert the commit
> >> 66cffd6daab76caebab26eb803b92182414fc182
> >> ?
> >
> > Please submit a proper patch with an explanation why it needs to be
> > reverted.
>
> Before doing a revert, let's see if we can keep the fix for open firmware=
, the
> situation for which commit 66cffd6daab7 was "needed". I think the followi=
ng
> should do:
>
> diff --git a/drivers/net/wireless/broadcom/b43/dma.c
> b/drivers/net/wireless/broadcom/b43/dma.c
> index 6b0e1ec346cb..2c37366b3592 100644
> --- a/drivers/net/wireless/broadcom/b43/dma.c
> +++ b/drivers/net/wireless/broadcom/b43/dma.c
> @@ -1519,12 +1519,14 @@ void b43_dma_handle_txstatus(struct b43_wldev *de=
v,
>                  } else {
>                          /* More than a single header/data pair were miss=
ed.
>                           * Report this error, and reset the controller t=
o
> -                        * revive operation.
> +                        * revive operation. If running the open-source
> +                        * firmware, then do a restart.
>                           */
>                          b43dbg(dev->wl,
>                                 "Out of order TX status report on DMA rin=
g %d.
> Expected %d, but got %d\n",
>                                 ring->index, firstused, slot);
> -                       b43_controller_restart(dev, "Out of order TX");
> +                       if (dev->fw.opensource)
> +                               b43_controller_restart(dev, "Out of order=
 TX");
>                          return;
>                  }
>          }
>
> At the moment, I am working with prabhu to see if upgrading his firmware =
will
> help his problem with no change in the driver. If not, then I will have h=
im test
> this patch.
>
> Larry

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-26  7:23       ` prabhu
@ 2018-08-26 16:14         ` Larry Finger
  2018-08-27 11:30           ` prabhu
  2018-08-28 12:41           ` Taketo Kabe
  0 siblings, 2 replies; 12+ messages in thread
From: Larry Finger @ 2018-08-26 16:14 UTC (permalink / raw)
  To: prabhu, Taketo Kabe; +Cc: kvalo, m, linux-wireless, b43-dev

[-- Attachment #1: Type: text/plain, Size: 533 bytes --]

On 08/26/2018 02:23 AM, prabhu wrote:
> Larry,
> 
> Upgrading the firmware didn't fix the issue.
> 
> The patch fixes it. My system has been running without any issues
> since yesterday.

I did not think the new firmware would help, but it had to be tried. Thanks for 
the testing.

@Pradhu & @Taketo: Attached is a new (improved?) patch for you to try. You need 
to start from an unmodified 4.18 source. This patch should allow both of your 
systems to work and avoid needing to revert Taketo's fix for his setup.

Thanks,

Larry



[-- Attachment #2: 0001-b43-Fix-regression-in-kernel-4.18.patch --]
[-- Type: text/x-patch, Size: 2123 bytes --]

>From 4805a08715de42d49587975979425031307218b6 Mon Sep 17 00:00:00 2001
From: Larry Finger <Larry.Finger@lwfinger.net>
Date: Sun, 26 Aug 2018 10:47:52 -0500
Subject: [PATCH] b43: Fix regression in kernel 4.18
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org

In commit 66cffd6daab7 ("b43: fix transmit failure when VT is switched"),
a condition is noted where the network controller needs to be reset. Note
that this situation happens when running the open-source firmware
(http://netweb.ing.unibs.it/~openfwwf/), plus a number of other special
conditions.

for a different card model, it is reported that this change breaks
operation running the proprietary firmware
(https://marc.info/?l=linux-wireless&m=153504546924558&w=2). Rather
than reverting the previous patch, the code is tweaked to avoid the
reset unless the open-source firmware is being used.

Fixes: 66cffd6daab7 ("b43: fix transmit failure when VT is switched")
Cc: Stable <stable@vger.kernel.org> # 4.18+
Cc: Taketo Kabe <kabe@sra-tohoku.co.jp>
Cc: D. Prabhu <d.praabhu@gmail.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
---
 drivers/net/wireless/broadcom/b43/dma.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/broadcom/b43/dma.c b/drivers/net/wireless/broadcom/b43/dma.c
index 6b0e1ec346cb..d46d57b989ae 100644
--- a/drivers/net/wireless/broadcom/b43/dma.c
+++ b/drivers/net/wireless/broadcom/b43/dma.c
@@ -1518,13 +1518,15 @@ void b43_dma_handle_txstatus(struct b43_wldev *dev,
 			}
 		} else {
 			/* More than a single header/data pair were missed.
-			 * Report this error, and reset the controller to
+			 * Report this error. If running with open-source
+			 * firmware, then reset the controller to
 			 * revive operation.
 			 */
 			b43dbg(dev->wl,
 			       "Out of order TX status report on DMA ring %d. Expected %d, but got %d\n",
 			       ring->index, firstused, slot);
-			b43_controller_restart(dev, "Out of order TX");
+			if (dev->fw.opensource)
+				b43_controller_restart(dev, "Out of order TX");
 			return;
 		}
 	}
-- 
2.18.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-26 16:14         ` Larry Finger
@ 2018-08-27 11:30           ` prabhu
  2018-08-27 15:28             ` Larry Finger
  2018-08-28 12:41           ` Taketo Kabe
  1 sibling, 1 reply; 12+ messages in thread
From: prabhu @ 2018-08-27 11:30 UTC (permalink / raw)
  To: Larry.Finger; +Cc: kabe, kvalo, m, linux-wireless, b43-dev

Larry,

Applied on a clean 4.18.4 source and tested.
It works for me.
On Sun, Aug 26, 2018 at 9:44 PM Larry Finger <Larry.Finger@lwfinger.net> wrote:
>
> On 08/26/2018 02:23 AM, prabhu wrote:
> > Larry,
> >
> > Upgrading the firmware didn't fix the issue.
> >
> > The patch fixes it. My system has been running without any issues
> > since yesterday.
>
> I did not think the new firmware would help, but it had to be tried. Thanks for
> the testing.
>
> @Pradhu & @Taketo: Attached is a new (improved?) patch for you to try. You need
> to start from an unmodified 4.18 source. This patch should allow both of your
> systems to work and avoid needing to revert Taketo's fix for his setup.
>
> Thanks,
>
> Larry
>
>

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-27 11:30           ` prabhu
@ 2018-08-27 15:28             ` Larry Finger
       [not found]               ` <CAHnrWRpPzV5BK3BoMrQ1vH=nxu70dVONLdhCnHh0SpBEa2v5LQ@mail.gmail.com>
  0 siblings, 1 reply; 12+ messages in thread
From: Larry Finger @ 2018-08-27 15:28 UTC (permalink / raw)
  To: prabhu; +Cc: kabe, kvalo, m, linux-wireless, b43-dev

On 08/27/2018 06:30 AM, prabhu wrote:
> Larry,
> 
> Applied on a clean 4.18.4 source and tested.
> It works for me.

Thanks for testing. I will push the patch upstream.

Larry

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
  2018-08-26 16:14         ` Larry Finger
  2018-08-27 11:30           ` prabhu
@ 2018-08-28 12:41           ` Taketo Kabe
  1 sibling, 0 replies; 12+ messages in thread
From: Taketo Kabe @ 2018-08-28 12:41 UTC (permalink / raw)
  To: Larry Finger; +Cc: prabhu, kvalo, m, linux-wireless, b43-dev, kabe

> @Pradhu & @Taketo: Attached is a new (improved?) patch for you to try. You need 
> to start from an unmodified 4.18 source. This patch should allow both of your 
> systems to work and avoid needing to revert Taketo's fix for his setup.
> 
> Thanks,
> Larry

Sorry for tha late reply.
Tested out the patch on clean 4.18.5 kernel source; it works as expected.

I also tried out proprietary firmware, but I couldn't reproduce a problem
mentioned in https://marc.info/?l=linux-wireless&m=153504546924558&w=2 .
The proprietary firmware works very sluggishly on my card (BCM4306)
and doesn't stand for practical use for unknown reason.
-- 
kabe

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Regression]BCM4312 is broken in kernel 4.18[Root cause found]
       [not found]               ` <CAHnrWRpPzV5BK3BoMrQ1vH=nxu70dVONLdhCnHh0SpBEa2v5LQ@mail.gmail.com>
@ 2018-09-04 15:15                 ` Larry Finger
  0 siblings, 0 replies; 12+ messages in thread
From: Larry Finger @ 2018-09-04 15:15 UTC (permalink / raw)
  To: prabhu, linux-wireless

On 09/04/2018 09:21 AM, prabhu wrote:
> Larry,
> 
> I didn't find this patch in 4.18.6 stable review mail.
> forgot to push or any other reason?

The patch is listed as "Under review".

Larry

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-09-04 19:41 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-23 17:30 [Regression]BCM4312 is broken in kernel 4.18[Root cause found] prabhu
2018-08-23 18:11 ` Michael Büsch
2018-08-24  8:23   ` Kalle Valo
2018-08-24 16:15     ` Larry Finger
2018-08-26  7:23       ` prabhu
2018-08-26 16:14         ` Larry Finger
2018-08-27 11:30           ` prabhu
2018-08-27 15:28             ` Larry Finger
     [not found]               ` <CAHnrWRpPzV5BK3BoMrQ1vH=nxu70dVONLdhCnHh0SpBEa2v5LQ@mail.gmail.com>
2018-09-04 15:15                 ` Larry Finger
2018-08-28 12:41           ` Taketo Kabe
2018-08-23 19:20 ` Larry Finger
2018-08-24  7:54   ` prabhu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.