LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Laptop and Netbook (https://www.linuxquestions.org/questions/linux-laptop-and-netbook-25/)
-   -   Update to kernel 3.13 removed ability to set powersave on AR9462 (ath9k) (https://www.linuxquestions.org/questions/linux-laptop-and-netbook-25/update-to-kernel-3-13-removed-ability-to-set-powersave-on-ar9462-ath9k-4175499101/)

TheCobra 03-22-2014 11:18 AM

Update to kernel 3.13 removed ability to set powersave on AR9462 (ath9k)
 
Using iw and powertop and laptop-mode-tools to turn on powersave mode for wlan chip in my laptop (which is an AR9462) fails. In powertop nothing happens, but if I run the --calibrate script the program segfaults when testing the wlan chip. As for iw it returns:
Code:

command failed: Operation not supported (-95)
And laptop-mode returns:
Code:

Error for wireless request "Set Power Management" (8B2C) :
    SET failed on device wlan0 ; Operation not supported.

All these things started to fail after I updated my kernel to 3.13, the most recent kernel in Debian testing (I use #! and pull in a few packages from testing). After doing some snooping I came across this in the kernel changelog:
Code:

Author: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Date:  Tue Feb 4 08:37:53 2014 +0530

    ath9k: Do not support PowerSave by default
   
    commit 8298383c2cd5a6d0639f1bb1781fba181bd20154 upstream.
   
    Even though we make sure PowerSave is not enabled by default
    by disabling the flag, WIPHY_FLAG_PS_ON_BY_DEFAULT on init,
    PS could be enabled by userspace based on various factors
    like battery usage etc. Since PS in ath9k is just broken
    and has been untested for years, remove support for it, but
    allow a user to explicitly enable it using a module parameter.
   
    Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
    Signed-off-by: John W. Linville <linville@tuxdriver.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

Could this potentially be the problem? And if so how do I enable the powersave module parameter, as the powersave feature still worked for me in kernel 3.12. It does make a difference, as I get about 1-2 hours of more battery life with this option enabled.

Here is my lspci dump for the device.
Code:

03:00.0 Network controller: Atheros Communications Inc. AAR9462 Wireless Network Adapter (rev 01)
    Subsystem: Foxconn International, Inc. Device e052
    Kernel driver in use: ath9k


blip 03-29-2014 09:04 PM

List the possible parameters with
Code:

/sbin/modinfo ath9k
then
Code:

modprobe -r ath9k
followed by
Code:

modprobe ath9k ps_enable=1
(A quick look at recent drivers/net/wireless/ath/ath9k/init.c indicates that should be the right name -- I'm running an older kernel.)

Keep in mind any wifi issues you may experience could be caused by forcing this setting. You can make this change permanent by creating /etc/modprobe.d/ath9kps.conf containing
Code:

options ath9k ps_enable=1
If the option is removed or renamed, your wifi will stop working and you will need to remove that file.

syg00 03-29-2014 11:04 PM

That must be a real recent update. That parm doesn't show in this Fedora 3.13.6 kernel, but does in the update I just downloaded from the repos.
And @blip was correct, it is called ps_enable.

TheCobra 04-02-2014 09:26 AM

Thank you blip. Setting the module parameter allowed me to set turn on power save mode using the programs I mentioned. I am also happy to mention in works in the 3.14 kernel.

And @syg00, yes the kernel revision I am using is 3.13.7. But, according to the kernel mailing lists, the change occured in the 3.13.5 kernel. It's odd it didn't appear to you at first.


All times are GMT -5. The time now is 02:51 AM.