Bug 197807 - iwlwifi: 8260: BT can't connect if the -31.ucode WiFi firmware is used - WIFILNX-1690
Summary: iwlwifi: 8260: BT can't connect if the -31.ucode WiFi firmware is used - WIFI...
Status: CLOSED CODE_FIX
Alias: None
Product: Drivers
Classification: Unclassified
Component: network-wireless (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: DO NOT USE - assign "network-wireless-intel" component instead
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-11-07 20:45 UTC by Yaroslav Isakov
Modified: 2017-11-28 21:58 UTC (History)
1 user (show)

See Also:
Kernel Version: 4.13.7
Subsystem:
Regression: No
Bisected commit-id:


Attachments
Encrypted dmesg part (2.38 KB, application/pgp-encrypted)
2017-11-07 22:10 UTC, Yaroslav Isakov
Details
Encrypted FW dump (980.53 KB, application/pgp-encrypted)
2017-11-07 22:11 UTC, Yaroslav Isakov
Details
Encrypted dmesg (2.37 KB, application/pgp-encrypted)
2017-11-07 22:57 UTC, Yaroslav Isakov
Details
Encrypted FW dump (357.04 KB, application/pgp-encrypted)
2017-11-07 22:57 UTC, Yaroslav Isakov
Details
Core31 firmware with debug enabled (2.34 MB, application/octet-stream)
2017-11-14 06:48 UTC, Emmanuel Grumbach
Details
Fix candidate (2.21 MB, application/octet-stream)
2017-11-14 12:10 UTC, Emmanuel Grumbach
Details
Encrypted FW dump (330.86 KB, application/pgp-encrypted)
2017-11-14 18:02 UTC, Yaroslav Isakov
Details
Encrypted dmesg (2.37 KB, application/pgp-encrypted)
2017-11-14 18:02 UTC, Yaroslav Isakov
Details
Fix candidate with debug logs (2.21 MB, application/octet-stream)
2017-11-14 18:24 UTC, Emmanuel Grumbach
Details
Encrypted dmesg (31) (2.42 KB, application/pgp-encrypted)
2017-11-14 18:46 UTC, Yaroslav Isakov
Details
Encrypted FW dump (31) (363.25 KB, application/pgp-encrypted)
2017-11-14 18:46 UTC, Yaroslav Isakov
Details
New BT firmware (783.05 KB, application/gzip)
2017-11-27 10:59 UTC, Emmanuel Grumbach
Details

Description Yaroslav Isakov 2017-11-07 20:45:33 UTC
Hello! I'm using Intel AC 8260 for wifi and BT, and I've found after upgrade to 4.13, that all of my BT devices stopped working - they cannot find the laptop. I've bisected this problem to commit b7e94bab81dc9cba5269542b2da524fc749078af (iwlwifi: bump max FW API to 31), deleted /lib/firmware/iwlwifi-8000C-31.ucode, rebooted and bingo - problem solved. I've installed 4.14-rc8 to test iwlwifi-8000C-34.ucode and updated iwlwifi-8000C-31.ucode from iwlwifi repo - same problem.
Comment 1 Emmanuel Grumbach 2017-11-07 21:02:06 UTC
thanks.

please look at 197147 and try to provide the data as required there.
Please note the privacy notice.

Thanks.
Comment 2 Yaroslav Isakov 2017-11-07 22:10:28 UTC
Created attachment 260551 [details]
Encrypted dmesg part
Comment 3 Yaroslav Isakov 2017-11-07 22:11:10 UTC
Created attachment 260553 [details]
Encrypted FW dump
Comment 4 Yaroslav Isakov 2017-11-07 22:15:18 UTC
Thank you, Emmanuel. I've dumped FW and provided relevant part of dmesg. I've created them in such way:
1) stopped wifi, rmmod all modules
2) modprobe iwlwifi
3) connected to WiFi
4) tried to connect both BT devices
5) dumped both FW and dmesg
Should I provide FW dump from FW 27?
Comment 5 Emmanuel Grumbach 2017-11-07 22:47:42 UTC
the dump should be automatic and that is much better because we can be sure that the right events have been caught in the buffer.
In the firmware from the other bug, I added a trigger to dump the data automatically upon WiFi connection.

please make sure you run with the firmware attached in https://bugzilla.kernel.org/show_bug.cgi?id=197147#c15
Comment 6 Yaroslav Isakov 2017-11-07 22:56:43 UTC
I'm attaching new dump and dmesg. I'm not sure if FW dump could help, as dumping is happening before BT connection, but here it is :)
Comment 7 Yaroslav Isakov 2017-11-07 22:57:21 UTC
Created attachment 260555 [details]
Encrypted dmesg
Comment 8 Yaroslav Isakov 2017-11-07 22:57:55 UTC
Created attachment 260557 [details]
Encrypted FW dump
Comment 9 Yaroslav Isakov 2017-11-07 22:59:29 UTC
Oh, and this dump have been created using FW from https://bugzilla.kernel.org/show_bug.cgi?id=197147#c15
Comment 10 Emmanuel Grumbach 2017-11-07 23:01:37 UTC
Can you connect BT if WiFi is not connected yet?
Comment 11 Yaroslav Isakov 2017-11-07 23:03:41 UTC
tried this few times, but no luck with FW 31. Maybe I should rfkill this interface...
Comment 12 Emmanuel Grumbach 2017-11-07 23:05:31 UTC
Ok - if so, I'll forward your latest dump to the Coex experts.

thanks.
Comment 13 Yaroslav Isakov 2017-11-07 23:06:46 UTC
I've unloaded iwlwifi/iwlmvm/btusb/btintel, then reloaded btusb - and my mouse connects!
Comment 14 Yaroslav Isakov 2017-11-07 23:08:13 UTC
after I've loaded iwlwifi again - mouse stopped working. So, for me wifi wins over BT every time
Comment 15 Emmanuel Grumbach 2017-11-07 23:09:38 UTC
Ok. I'll let you know if we can need more data.

Thanks.
Comment 16 Yaroslav Isakov 2017-11-07 23:10:24 UTC
OK, thank you!
Comment 17 Emmanuel Grumbach 2017-11-12 18:18:21 UTC
Can you please try the -34.ucode?
We've published it recently.

Thanks.
Comment 18 Emmanuel Grumbach 2017-11-12 18:19:02 UTC
(Forgot to say: you'd better use our backport driver or 4.14-rc8 + the fix included in https://bugzilla.kernel.org/show_bug.cgi?id=197591)
Comment 19 Yaroslav Isakov 2017-11-13 18:03:08 UTC
Nope, don't work with FW version 34.0.1 and patch applied on 4.14.0
Comment 20 Yaroslav Isakov 2017-11-13 18:06:13 UTC
Gnome Bluetooth even cannot start scan mode, and in dmesg there are such messages:
bluetoothd[980]: Failed to set mode: Busy (0x0a)
Comment 21 Yaroslav Isakov 2017-11-13 18:07:33 UTC
There were such messages on 31 as well, it looks like.
Comment 22 Emmanuel Grumbach 2017-11-14 06:48:31 UTC
Created attachment 260645 [details]
Core31 firmware with debug enabled

Hi,

Can you please try the following flow:

1) connect BT
2) connect WiFi

At this point, the firmware will automatically create a dump. This is the dump we need.

Please take the time to read the privacy notice:
https://wireless.wiki.kernel.org/en/users/drivers/iwlwifi/debugging#privacy_aspects

Thank you.
Comment 23 Emmanuel Grumbach 2017-11-14 12:10:16 UTC
Created attachment 260649 [details]
Fix candidate

Hi,

our firmware team has found a problem and here is a fix candidate.
Please try.

Thank you.
Comment 24 Yaroslav Isakov 2017-11-14 17:42:26 UTC
Emmanuel, no, unfortunately, it doesn't fix my problem. FW is:
iwlwifi 0000:04:00.0: loaded firmware version 31.622545.1 op_mode iwlmvm
md5 is 5aa8ea53b6807b4f366507fbf3204f9f (just to be sure that I'm using right FW)
Tested on 4.14.0

Should I perform steps from #22?
Comment 25 Yaroslav Isakov 2017-11-14 17:45:27 UTC
Oh, and I've tried two cases - reboot my laptop (it is connecting to WiFi automatically), try to connect my BT LE mouse. Second try, I've unloaded iwlwifi/iwlmvm/btusb/btintel, loaded iwlwifi, waited connection to Internet, and tried to connect my mouse. Both tries - mouse cannot connect to laptop.
Comment 26 Yaroslav Isakov 2017-11-14 18:00:50 UTC
Attaching both dmesg and FW dump
Comment 27 Yaroslav Isakov 2017-11-14 18:02:17 UTC
Created attachment 260659 [details]
Encrypted FW dump
Comment 28 Yaroslav Isakov 2017-11-14 18:02:47 UTC
Created attachment 260661 [details]
Encrypted dmesg
Comment 29 Emmanuel Grumbach 2017-11-14 18:02:58 UTC
FW dump is useless here since I haven't configured the FW to send the right data.
Will do in a bit.

BTW - you have triggered the dumps manually, right?
The firwmare shouldn't have dumped data automatically.
Comment 30 Emmanuel Grumbach 2017-11-14 18:04:26 UTC
Oh - I can see that the dump was automatic...
Seems like you haven't used the right firmware. You were using 34.ucode instead of 31.ucode.
At least for the repro you sent to me in comments 27/28
Comment 31 Emmanuel Grumbach 2017-11-14 18:06:20 UTC
31.622545.1 seems right though.
Comment 32 Yaroslav Isakov 2017-11-14 18:08:01 UTC
Attachment 260645 [details] from #22 is 34.0.1 - it's called iwlwifi-8000C-34.ucode, md5sum  1b900b688de269c6156d3e8986744ffd - this is automatic dump is for
Comment 33 Yaroslav Isakov 2017-11-14 18:13:59 UTC
Tried 31.622545.1 the same way - mouse worked even with module loaded from the boot, but stopped working after connecting to WiFi. No debug logs for it...
Comment 34 Emmanuel Grumbach 2017-11-14 18:24:10 UTC
Created attachment 260663 [details]
Fix candidate with debug logs

Great. Here is the same fix candidate with debug configured.
Please use that one.
It'll trigger a dump one second after you connect and hopefully this will bring data that the firmware team will be able to analyze.

Thanks!
Comment 35 Yaroslav Isakov 2017-11-14 18:46:00 UTC
Created attachment 260667 [details]
Encrypted dmesg (31)
Comment 36 Yaroslav Isakov 2017-11-14 18:46:34 UTC
Created attachment 260669 [details]
Encrypted FW dump (31)
Comment 37 Yaroslav Isakov 2017-11-14 18:47:21 UTC
Hope this helps! Same behavior as on 34
Comment 38 Emmanuel Grumbach 2017-11-14 19:06:55 UTC
Data sent to the firmware team.

Thanks.
Comment 39 Emmanuel Grumbach 2017-11-27 10:59:20 UTC
Created attachment 260893 [details]
New BT firmware

Here is a pre-release of the new firmware for BT.
Please copy the files to /lib/firmware/intel/

You'll need a hard power off / on cycle.

After boot,  run btmon in 1 terminal and in the other terminal give the command hcitool cmd 3f 05 in root permission.
After giving the hcitool cmd 3f 05 the btmon log will show the version information.

Please provide the btmon log.

Let us know if things feel better.

Note: this includes BT firmware for 8260 and 8265.
Comment 40 Yaroslav Isakov 2017-11-27 22:14:15 UTC
Emmanuel,
Thank you a lot! This new firmware is definitely makes difference - at least my mouse is now working. Here is a output of hcitool:
 HCI Command: Intel Read Version (0x3f|0x0005) plen 0     #67 [hci0] 41.308459
> HCI Event: Command Complete (0x0e) plen 13               #68 [hci0] 41.405398
      Intel Read Version (0x3f|0x0005) ncmd 1
        Status: Success (0x00)
        Hardware platform: 0x37
        Hardware variant: 0x0b
        Hardware revision: 1.2
        Firmware variant: 0x23
        Firmware revision: 0.0
        Firmware build: 176-45.2017
        Firmware patch: 0

My iwlwifi firmware now is 31.622545.1
Comment 41 Yaroslav Isakov 2017-11-27 22:17:01 UTC
Checked with 34.0.1 as well - and it works!
Comment 42 Yaroslav Isakov 2017-11-27 22:18:01 UTC
Will check another device tomorrow. Thanks a lot!
Comment 43 Emmanuel Grumbach 2017-11-28 21:58:38 UTC
Closing for now. Please reopen if needed.

Note You need to log in before you can comment on or make changes to this bug.