Bug 1021036
Summary: | ideapad_laptop loads on yoga 2 pro and breaks wireless | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Kevin Fenzi <kevin> | ||||||||
Component: | kernel | Assignee: | Hans de Goede <hdegoede> | ||||||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||||
Severity: | unspecified | Docs Contact: | |||||||||
Priority: | unspecified | ||||||||||
Version: | rawhide | CC: | brsmith, decathorpe, dwmw2, gansalmon, hdegoede, hugh, itamar, jonathan, kernel-maint, kevin, kxra, madhu.chinakonda, marcelo.barbosa, mjg59, nmvega, pfpschneider, rbarry, soeren.grunewald, valent.turkovic, wengxt, zerothindex | ||||||||
Target Milestone: | --- | ||||||||||
Target Release: | --- | ||||||||||
Hardware: | Unspecified | ||||||||||
OS: | Unspecified | ||||||||||
Whiteboard: | |||||||||||
Fixed In Version: | kernel-3.14.13-100.fc19 | Doc Type: | Bug Fix | ||||||||
Doc Text: | Story Points: | --- | |||||||||
Clone Of: | Environment: | ||||||||||
Last Closed: | 2014-07-08 00:59:03 UTC | Type: | Bug | ||||||||
Regression: | --- | Mount Type: | --- | ||||||||
Documentation: | --- | CRM: | |||||||||
Verified Versions: | Category: | --- | |||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||
Embargoed: | |||||||||||
Attachments: |
|
Description
Kevin Fenzi
2013-10-18 20:02:42 UTC
I confirm that wireless adapter disappears on the system when loading the ideapad_laptop module. I couldn't figure out either any advantage of the module and blacklisted it so the module will not be loaded during startup. Adding the author listed in modinfo here for comment. ;) David: Any ideas here? Can we have it not bind on these laptops? Or adjust it so it doesn't bork the wireless? The ideapad_laptop module *does* do something (else) related to rfkill. It causes the Airplane key (F7) to emit the scan codes e0 73, which are recognized as <XF86WLAN>. However, this key isn't hooked up to anything useful - it does toggle the soft block on ideapad_wlan though. Anyway, it sure would be nice to have a useful module for Yogas. Is anyone working on the problem? I certainly can provide information and test out results, although I only have Fedora installed on my Yoga 2 Pro. Is there a bug filed upstream for this? Ripping out the rfkill code from ideapad_laptop.c results in a module that can be loaded, but it appears that they only thing that it does is handle a couple of keys. Nonetheless, it would be nice to get this to work. Does anyone know a good way to check for Yogas and not do the rfkill stuff? Even better, does anyone know how to get information out of Lenovo on the Yogas so that a better module can be built? Right now there are about six keys or buttons on the Yoga that either don't work right or work but don't produce any events that can be customized. Here is a patch to ideapad_laptop.c that has an explicit DMI test for the Yoga 2 Pro and then doesn't set up the rfkill switches. A simple change to the test should also work for other Yogas, but I don't have any hardware to test that out, and I am reluctant to over-generalize. Is there anyone who can do that test? The module isn't very useful for Yogas, but it does enable the Airplane Mode and Novo keys. The Novo key appears to work slightly differently on Yogas as opposed to other ideapads. How should I submit this upstream? Created attachment 871738 [details]
patch to ideapad_laptop.c
Patch to disable rfkill hardware switch code for Yoga 2 Pro, as the Yoga 2 Pro doesn't have a hardware kill switch and the original code was disabling the wlan device.
(In reply to Peter F. Patel-Schneider from comment #5) > Here is a patch to ideapad_laptop.c that has an explicit DMI test for the > Yoga 2 Pro and then doesn't set up the rfkill switches. A simple change to > the test should also work for other Yogas, but I don't have any hardware to > test that out, and I am reluctant to over-generalize. Is there anyone who > can do that test? > > The module isn't very useful for Yogas, but it does enable the Airplane Mode > and Novo keys. The Novo key appears to work slightly differently on Yogas > as opposed to other ideapads. > > How should I submit this upstream? I suggest writing a descriptive changelog of what the patch does and emailing it to the following people and lists: Ike Panhc <ike.pan> (maintainer:IDEAPAD LAPTOP EX...) Matthew Garrett <matthew.garrett> (maintainer:X86 PLATFORM DRIVERS) platform-driver-x86.org (open list:IDEAPAD LAPTOP EX...) linux-kernel.org (open list) (that's the output of scripts/get_maintainer.pl -f drivers/platform/x86/ideapad-laptop.c) They'll be able to review it properly and provide feedback. Thanks. I've sent of a message. We'll see what happens. Nothing appears to have happened in response to my message http://marc.info/?l=linux-kernel&m=139421657413234&w=2 Any other suggestions? Since this affects yoga 2 pro users, I was wondering if anyone else experienced another issue with the most recent 3.16 kernel: https://bugzilla.redhat.com/show_bug.cgi?id=1110529 If I do another kernel update, 3.15 will be gone and I'll be without a bootable machine kxra, you are running on rawhide, right? On rawhide, breakage can be expected. I saw some quirk[1] has been added for Yoga 2 11, any update for this model? [1] https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/drivers/platform/x86/ideapad-laptop.c?id=85093f79f586176f8bbf90e56e22a3dfa526e334 HI, (In reply to Weng Xuetian from comment #12) > I saw some quirk[1] has been added for Yoga 2 11, any update for this model? > > [1] > https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/ > drivers/platform/x86/ideapad-laptop. > c?id=85093f79f586176f8bbf90e56e22a3dfa526e334 Yes that was done by me, I was not aware of this bug otherwise I would have added a quirk for the yoga 2 pro at the same time. Looking some more into this I've also found this bug report for the non pro 13" version: https://forums.lenovo.com/t5/Linux-Discussion/Yoga-2-13-not-Pro-Linux-Warning/m-p/1517612#M5933 Which suggests that the rkill functionality does work (in this case it was successful blocking stuff), but there just is no hardware switch, and the bit in the EC corresponding to the hwswitch reads 0 by default, causing ideapad_laptop to report everything as blocked wrongly. I'm going to write up a new patch for this, Created attachment 910736 [details]
[PATCH] ideapad-laptop: Change Lenovo Yoga 2 series rfkill handling
Here is a patch fixing this in what I believe is the proper way to fix this. I'm preparing a Fedora kernel scratch-build with this patch for you to test.
Here is the scratch build: http://koji.fedoraproject.org/koji/taskinfo?taskID=7061269 Note this is still building atm. When it is finished, please download the kernel...rpm file for your architecture, and then install it with: sudo rpm -ivh kernel...rpm Then boot into the new kernel, and once booted do: rfkill list Please write down the output of the rfkill list command. Now disable wifi in your network control panel applet, and run "rfkill list" again, again please write down (copy paste) the output. Now re-enable wifi in your network control panel applet, and run "rfkill list" again, again please write down (copy paste) the output. Check that your wifi still works as expected. Please let me know if this works for you, and what the output of the 3 "rfkill list" commands is. Thanks & Regards, Hans I assume you wanted me to unblacklist the module too? ;) 1: 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: ideapad_wlan: Wireless LAN Soft blocked: no Hard blocked: no 2: ideapad_bluetooth: Bluetooth Soft blocked: yes Hard blocked: no 3: phy0: Wireless LAN Soft blocked: no Hard blocked: no 2: 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: ideapad_wlan: Wireless LAN Soft blocked: no Hard blocked: no 2: ideapad_bluetooth: Bluetooth Soft blocked: yes Hard blocked: no 3: phy0: Wireless LAN Soft blocked: no Hard blocked: no 3: 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: ideapad_wlan: Wireless LAN Soft blocked: no Hard blocked: no 2: ideapad_bluetooth: Bluetooth Soft blocked: yes Hard blocked: no 3: phy0: Wireless LAN Soft blocked: no Hard blocked: no Wireless seemed to work fine. Do you really need to use this kernel to test things out? If you point me to a patched version of ideapad_laptop.c I can easily compile it against current Fedora 20 and check whether it works on my Yoga 2 Pro. Hi, (In reply to Peter F. Patel-Schneider from comment #17) > Do you really need to use this kernel to test things out? No, that is not necessary, I just thought that it would be easiest for Fedora users. I've a standalone version of the driver here (with an updated patch, which is not in the kernel build I did, to fix the wireless being stuck in off on the yoga 2 13) here: http://people.fedoraproject.org/~jwrdegoede/ideapad-laptop/ Just download the .c and Makefile, and then do make; sudo rmmod ideapad-laptop; sudo insmod ideapad-laptop.ko Regards, Hans I'm getting the following. After boot: idefix ~> rfkill list 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: phy0: Wireless LAN Soft blocked: no Hard blocked: no Wireless off: idefix ~> rfkill list 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: phy0: Wireless LAN Soft blocked: yes Hard blocked: no Wireless on: idefix ~> rfkill list 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: phy0: Wireless LAN Soft blocked: no Hard blocked: no And the wireless works as expected. However, the first time I put the new module in I got the four devices like Kevin did. I like the two device situation better, but I wonder why I got four devices the first time. (In reply to Peter F. Patel-Schneider from comment #19) > However, the first time I put the new module in I got the four devices like > Kevin did. I like the two device situation better, but I wonder why I got > four devices the first time. That is intentional sometimes not registering rfkill is not enough, if the frimware rfkill bits are in a blocked state (which is persisten over reboots) you need those extra entries to be able to unblock things. Since you did not install a new kernel but build a module locally, the changes will be gone after a reboot, to permanently get the new module you need to do: cp ideapad-laptop.ko /lib/modules/$(uname -r)/kernel/drivers/platform/x86/ Can you please try with the new module (in which case you should have 4 entries not 2. I already have confirmation that the new module works on the yoga 2 11 and yoga 2 13, now all I need is confirmation that it works on the yoga 2 pro and then I can send it upstream. Created attachment 911300 [details] [PATCH v2] ideapad-laptop: Change Lenovo Yoga 2 series rfkill handling Here is the version of the patch present in the standalone ideapad-laptop.c found at: http://people.fedoraproject.org/~jwrdegoede/ideapad-laptop/ This version contains some changes needed to also make the wireless of the yoga 2 13 (the non pro 13" version) work. For people preferring a kernel build to test I've started a scratch build with this patch, which you can find here: http://koji.fedoraproject.org/koji/taskinfo?taskID=7066918 (note still building atm). Once this is finished please give it a test, I already have confirmation this works on the yoga 2 11 and yoga 2 13, as soon as I've confirmation the changes for the yoga 2 13 don't cause issues on the pro I'll send this version of the patch upstream. (In reply to comment #20.) I had thought that I had copied the driver into the right place, but I guess not. Anyway, I did and things appear to be working fine. Wireless works, and there two WiFi entries are changing in parallel. I'm still confused as to why there needs to be the four entries. I've been getting along with only the two for months now. Maybe there are some situations that I haven't encountered yet that require them. Anyway, consider this a "go-ahead" from a Yoga 2 Pro user. Here are the rfkill states on boot, after turning off wireless, and after turning it on again. idefix ~> rfkill list 0: ideapad_wlan: Wireless LAN Soft blocked: no Hard blocked: no 1: ideapad_bluetooth: Bluetooth Soft blocked: yes Hard blocked: no 2: hci0: Bluetooth Soft blocked: yes Hard blocked: no 3: phy0: Wireless LAN Soft blocked: no Hard blocked: no idefix ~> rfkill list 0: ideapad_wlan: Wireless LAN Soft blocked: yes Hard blocked: no 1: ideapad_bluetooth: Bluetooth Soft blocked: yes Hard blocked: no 2: hci0: Bluetooth Soft blocked: yes Hard blocked: no 3: phy0: Wireless LAN Soft blocked: yes Hard blocked: no idefix ~> rfkill list 0: ideapad_wlan: Wireless LAN Soft blocked: no Hard blocked: no 1: ideapad_bluetooth: Bluetooth Soft blocked: yes Hard blocked: no 2: hci0: Bluetooth Soft blocked: yes Hard blocked: no 3: phy0: Wireless LAN Soft blocked: no Hard blocked: no idefix ~> This also works for me (though I don't use fedora so I compiled my own kernel with patch). Though I need to unblock it when I first use it, after that it works fine. Thanks for the testing! I've added these patches to fedpkg f19, f20, stabilization (the upcoming 3.15 update for f19 / f20) and master, so the next kernel update should fix this in the official Fedora packages. Just updated F21 and didn't have to #rmmod ideapad_laptop for the first time! Thanks! (In reply to kxra from comment #25) > Just updated F21 and didn't have to #rmmod ideapad_laptop for the first > time! Thanks! Note for people who prefer official F20 builds, the first F20 build with the fixes in has just been done: http://koji.fedoraproject.org/koji/buildinfo?buildID=540999 kernel-3.15.3-200.fc20 has been submitted as an update for Fedora 20. https://admin.fedoraproject.org/updates/kernel-3.15.3-200.fc20 Package kernel-3.15.3-200.fc20: * should fix your issue, * was pushed to the Fedora 20 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing kernel-3.15.3-200.fc20' as soon as you are able to, then reboot. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2014-8017/kernel-3.15.3-200.fc20 then log in and leave karma (feedback). Thank you guys. I've been watching this thread (I have this laptop, too - same issue) and will try that kernel once it hits my repositories (not there yet) and report back my reults (and give karma feedback). Thanks again! =:) Confirming kernel-3.15.3-200.fc20 with patched module ideapad_laptop reverses previously blocked hardware Wifi kill switch on Lenovo Yoga2 13. # dmidecode 2.12 # SMBIOS entry point at 0x9cebef98 SMBIOS 2.7 present. 65 structures occupying 2777 bytes. Table at 0x9CEBC000. Handle 0x0000, DMI type 0, 24 bytes BIOS Information Vendor: LENOVO Version: 96CN19WW(V1.05) ... # lspci -vvv ... 01:00.0 Network controller: Intel Corporation Wireless 7260 (rev 6b) Subsystem: Intel Corporation Wireless-N 7260 Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+ Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx- Latency: 0, Cache Line Size: 64 bytes Interrupt: pin A routed to IRQ 61 Region 0: Memory at b0400000 (64-bit, non-prefetchable) [size=8K] Capabilities: [c8] Power Management version 3 Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA PME(D0+,D1-,D2-,D3hot+,D3cold+) Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME- Capabilities: [d0] MSI: Enable+ Count=1/1 Maskable- 64bit+ Address: 00000000fee0100c Data: 41d1 Capabilities: [40] Express (v2) Endpoint, MSI 00 DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <512ns, L1 unlimited ExtTag- AttnBtn- AttnInd- PwrInd- RBE+ FLReset+ DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported- RlxdOrd+ ExtTag- PhantFunc- AuxPwr+ NoSnoop+ FLReset- MaxPayload 128 bytes, MaxReadReq 128 bytes DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend- LnkCap: Port #0, Speed 2.5GT/s, Width x1, ASPM L0s L1, Exit Latency L0s <4us, L1 <32us ClockPM+ Surprise- LLActRep- BwNot- LnkCtl: ASPM Disabled; RCB 64 bytes Disabled- CommClk+ ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt- LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive- BWMgmt- ABWMgmt- DevCap2: Completion Timeout: Range B, TimeoutDis+, LTR+, OBFF Via WAKE# DevCtl2: Completion Timeout: 16ms to 55ms, TimeoutDis-, LTR+, OBFF Disabled LnkCtl2: Target Link Speed: 2.5GT/s, EnterCompliance- SpeedDis- Transmit Margin: Normal Operating Range, EnterModifiedCompliance- ComplianceSOS- Compliance De-emphasis: -6dB LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete-, EqualizationPhase1- EqualizationPhase2-, EqualizationPhase3-, LinkEqualizationRequest- Capabilities: [100 v1] Advanced Error Reporting UESta: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF- MalfTLP- ECRC- UnsupReq- ACSViol- UEMsk: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF- MalfTLP- ECRC- UnsupReq- ACSViol- UESvrt: DLP+ SDES+ TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+ MalfTLP+ ECRC- UnsupReq- ACSViol- CESta: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr- CEMsk: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+ AERCap: First Error Pointer: 00, GenCap- CGenEn- ChkCap- ChkEn- Capabilities: [140 v1] Device Serial Number 7c-7a-91-ff-ff-40-7b-b2 Capabilities: [14c v1] Latency Tolerance Reporting Max snoop latency: 3145728ns Max no snoop latency: 3145728ns Capabilities: [154 v1] Vendor Specific Information: ID=cafe Rev=1 Len=014 <?> Kernel driver in use: iwlwifi Kernel modules: iwlwifi kernel-3.14.11-100.fc19 has been submitted as an update for Fedora 19. https://admin.fedoraproject.org/updates/kernel-3.14.11-100.fc19 kernel-3.15.3-200.fc20 has been pushed to the Fedora 20 stable repository. If problems still persist, please make note of it in this bug report. kernel-3.14.13-100.fc19 has been submitted as an update for Fedora 19. https://admin.fedoraproject.org/updates/kernel-3.14.13-100.fc19 kernel-3.14.13-100.fc19 has been pushed to the Fedora 19 stable repository. If problems still persist, please make note of it in this bug report. Has there been a regression with this issue? Because I'm still having issues with ideapad-laptop disabling wireless on Lenovo Yoga 3 running Fedora 22 with latest patches. Here is my bug report: https://bugzilla.redhat.com/show_bug.cgi?id=1239050 and also similar report for Fedora 21: https://bugzilla.redhat.com/show_bug.cgi?id=1021036 Sorry for wrong link, here is correct link: https://bugzilla.redhat.com/show_bug.cgi?id=1192270 Links with same issues: http://www.scrye.com/wordpress/nirik/2013/10/18/lenovo-yoga-2-pro-and-fedora-review/ https://ask.fedoraproject.org/en/question/59063/yoga-3-pro-wifi-problems-on-21-beta/?answer=71408#post-id-71408 and possible manual workaround without removing driver from Arch Wiki: https://wiki.archlinux.org/index.php/Lenovo_Ideapad_Yoga_2_Pro It may be that the Yoga 3 is not handled correctly by ideadpad-laptop. Had it been working before? The module has a description of the laptops that need to be handled specially. It is somewhat conservative, and rightly so I think. I've replied to the more specific bug with more information. Lets deal with this further in bug 1239050, clearing needinfo. |