You are not logged in.

#1 2013-03-19 18:34:30

LiamMcCalloway
Member
Registered: 2013-03-19
Posts: 21

[SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

Hi all,

Though wifi works out of the box,  powersaving doesn't on my MBA 5,2 (late 2012). The situation dates back to at least the 3.7.* kernels, and possibly before. Is this a known issue? Or perhaps is it solvable?

Many thanks!

# uname -a
Linux Arch 3.8.3-2-ARCH #1 SMP PREEMPT Sun Mar 17 13:04:22 CET 2013 x86_64 GNU/Linux
$ lspci | grep -i net
02:00.0 Network controller: Broadcom Corporation BCM43224 802.11a/b/g/n (rev 01)
# iwconfig                                                                                        
lo        no wireless extensions.
wlan0     IEEE 802.11abgn  ESSID:""  
          Mode:Managed  Frequency:2.462 GHz  Access Point:    
          Bit Rate=65 Mb/s   Tx-Power=19 dBm   
          Retry  long limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality=39/70  Signal level=-71 dBm  
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:3085  Invalid misc:5211   Missed beacon:0
# iw dev wlan0 set power_save on                                                                  
command failed: Operation not supported (-95)
# iw dev wlan0 get power_save                                                                     
Power save: off
# dmesg | grep -e bcma | less       
[    4.673207] bcma-pci-bridge 0000:02:00.0: enabling device (0000 -> 0002)
[    4.673364] bcma: bus0: Found chip with id 0xA8D8, rev 0x01 and package 0x08
[    4.673448] bcma: bus0: Core 0 found: ChipCommon (manuf 0x4BF, id 0x800, rev 0x22, class 0x0)
[    4.673529] bcma: bus0: Core 1 found: IEEE 802.11 (manuf 0x4BF, id 0x812, rev 0x17, class 0x0)
[    4.673586] bcma: bus0: Core 2 found: PCIe (manuf 0x4BF, id 0x820, rev 0x0F, class 0x0)
[    4.843255] bcma: bus0: Bus registered
[    5.790551] brcmsmac bcma0:0: mfg 4bf core 812 rev 23 class 0 irq 17
[    6.793389] brcmsmac bcma0:0: brcms_ops_bss_info_changed: qos enabled: false (implement)
[    6.793432] brcmsmac bcma0:0: brcms_ops_config: change power-save mode: false (implement)
[   18.217983] brcmsmac bcma0:0: brcms_ops_bss_info_changed: qos enabled: false (implement)
[   18.218094] brcmsmac bcma0:0: brcms_ops_config: change power-save mode: false (implement)
[   18.285286] brcmsmac bcma0:0: brcms_ops_bss_info_changed: qos enabled: false (implement)
[   18.285396] brcmsmac bcma0:0: brcms_ops_config: change power-save mode: false (implement)
[   24.240431] brcmsmac bcma0:0: brcmsmac: brcms_ops_bss_info_changed: associated
[   24.240524] brcmsmac bcma0:0: brcms_ops_bss_info_changed: arp filtering: enabled true, count 0 (implement)
[   24.240623] brcmsmac bcma0:0: brcms_ops_bss_info_changed: qos enabled: true (implement)
[   30.609801] brcmsmac bcma0:0: brcms_ops_bss_info_changed: arp filtering: enabled true, count 1 (implement)
[13331.883101] brcmsmac bcma0:0: START: tid 1 is not agg'able

Last edited by LiamMcCalloway (2013-03-24 23:44:52)

Offline

#2 2013-03-20 05:00:49

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

As a broadcom device, usually there is a free and non-free one.  I have very little experience with broadcom, but have seen a great number of times when it is suggested on these forums to use a different module.

As a side note, my current rtl8192ce (RTL8188CE) driven card is not able to have power saving toggled while the module is loaded.  You have to specifically tell it to modprobe it with firmware power saving or software power saving or something that is called "ips" which stands for i<something> power saving I presume.

Offline

#3 2013-03-21 11:28:51

LiamMcCalloway
Member
Registered: 2013-03-19
Posts: 21

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

Hey,
Thanks for your reply.

 # lsmod | grep -i ips

gives nothing.

There doesn't seem to be many MBA 5,2 users. Most guides stop at 5,1, at best.

Offline

#4 2013-03-21 15:31:06

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

That isn't going to give you any info about what the module is capable of.  You need to first determine the module that is being used.  Use lspci -v to see what modules are loaded for each peice of pci hardware.  Then use modinfo to determine the options available for that module.  Then figure out how to load it with those options on boot. Hint: Look into modprobe.

Gotta go to work though... no time to explain!

Offline

#5 2013-03-21 22:57:45

LiamMcCalloway
Member
Registered: 2013-03-19
Posts: 21

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

Thanks for your pointers!

lspci -v
[...]
02:00.0 Network controller: Broadcom Corporation BCM43224 802.11a/b/g/n (rev 01)
        Subsystem: Apple Inc. Device 00e9
        Flags: bus master, fast devsel, latency 0, IRQ 17
        Memory at a0400000 (64-bit, non-prefetchable) [size=16K]
        Capabilities: [40] Power Management version 3
        Capabilities: [58] Vendor Specific Information: Len=78 <?>
        Capabilities: [48] MSI: Enable- Count=1/1 Maskable- 64bit+
        Capabilities: [d0] Express Endpoint, MSI 00
        Capabilities: [100] Advanced Error Reporting
        Capabilities: [13c] Virtual Channel
        Capabilities: [160] Device Serial Number 
        Capabilities: [16c] Power Budgeting <?>
        Kernel driver in use: bcma-pci-bridge

bcma-pci-bridge seems to be a driver, not a module so modinfo does give anything.

bcma and brcmsmac are both loaded, as are the modules modinfo say they depend on (mac80211,bcma,brcmutil,cfg80211,cordic)

modinfo -p yields nothing for either bcma or brcmsmac, so there can be no parameters to pass on the kernel, I think.

I tried unloading and reloading the modules, to no avail....

Offline

#6 2013-03-22 04:28:13

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

Okay, did you read the Braodcom Wireless wiki page?  It would seem that your card should be able to use the b43 module as long as you have the b43-firmware package from teh AUR.

That is what the wiki is there for you know...

Offline

#7 2013-03-22 11:48:50

LiamMcCalloway
Member
Registered: 2013-03-19
Posts: 21

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

I did -- but since wifi worked out of the box through bcma/brcmsmac, I figured I should look for the solution within that setup. My card is in fact able to use either b43 or broadcom-wl. I just tried both, but neither enables power saving (iw dev wlan0 set power_save on).

Offline

#8 2013-03-22 15:58:17

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

As I said earlier in the post, I am not very familiar with broadcom wireless.  So if there is not power saving feature from either the point of module loading or by using the usual "iw dev wlan0 set power_save off" then I am fresh out of ideas.

Edit: from what I can see, b43 does indeed give you access to hardware power saving when you load the module.

Last edited by WonderWoofy (2013-03-22 16:00:48)

Offline

#9 2013-03-24 23:44:29

LiamMcCalloway
Member
Registered: 2013-03-19
Posts: 21

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

Hi WonderWoofy,
I think I only now understood what you suggested. Kernel modules can be parameters, and indeed:

Arch# modinfo -p b43
[..]
hwpctl:Enable hardware-side power control (default off) (int)

However b43 does not seem to recognize the card, or at least I couldn't get it to work upon closer inspection (earlier, bcma seems to have loaded brcmsmac automatically upon entering modprobe b43). broadcom-wl however seems to work.

Thanks for your pointers!

Offline

#10 2013-03-24 23:53:37

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

You need the b43-firmware package.  It is available in the AUR.  Now I am not sure if you then have to blacklist the brcmsmac module or not, but with the firmware it should be able to load the module with the udev detection.

https://aur.archlinux.org/packages/b43-firmware/ is what you should need.  Or have you installed this already?


Edit: As a side note, I just want to mention that the power saving features of every wireless card I have tried only causes problems for me.  Everything still works, but it always seems to work much better without it.  That said, I will reiterate that I have very little experience with broadcom, so I cannot tell you if this is the case with your given card.  I say, since we have come this far, try it. But don't be surprised when you think to yourself "Wow, this is not awesome..."

Last edited by WonderWoofy (2013-03-24 23:55:29)

Offline

#11 2013-03-27 00:08:42

LiamMcCalloway
Member
Registered: 2013-03-19
Posts: 21

Re: [SOLVED] MBA 5,2 (2012) wifi powersave doesn't work

So far, no issue with the broadcom-wl module with powersaving enabled. The powerdown package in the AUR triggers power management gracefully. As an aside, invocations of "powertop --time=120" give a battery discharge rate of 4,68W when doing nothing, display at the minimum settings.

Thanks again for the help.

Offline

Board footer

Powered by FluxBB