asus/wled wireless LED has incorrect status on startup

Bug #22795 reported by Vincent Untz
6
Affects Status Importance Assigned to Milestone
Ubuntu
Fix Released
Medium
Unassigned
acpi-support (Ubuntu)
Fix Released
Medium
Paul Sladen
Breezy
Invalid
Medium
Unassigned
Dapper
Invalid
Medium
Unassigned

Bug Description

My Asus M6Ne laptop has a nice LED status for the wireless card. However, it's
not initialized on startup. I'll attach a patch that fixes this (might not be
the best solution, though).

Revision history for this message
Vincent Untz (vuntz) wrote :

Created an attachment (id=4192)
Patch for /etc/init.d/acpi-support

The patch adds a quick check in the init.d script.

It might not be the best solution since a lot of various hardware might need
something similar and I'm not sure adding everything in the init.d script is
great...

Revision history for this message
sittisal (sittisal) wrote :

Also for me this led is not working immediately properly. I had to push "fn+f2" to switch wlan off (and the led stay off) and then already "fn+f2" (and the led now turn on). Is not urgent but it would be appreciated if in the next relase it's working out-of-box.
The same problem with most of asus notebook that had "/proc/acpi/asus/wled" working...

Thanks in advance :-)

sittisal

Revision history for this message
sittisal (sittisal) wrote :

I discovered the problems.
The change of status script is called only when asus-wireless.sh is called.
"asus-wireless.sh" is called only when the wireless on/off button (fn+f2) is pressed. Put asus-wireless.sh script in /etc/init.d/acpi-support did not resolve the problem. In fact asus-wireless.sh script call wireless.sh script wich alternatively switch on and off the wifi (to make the wireless on/off button works). So this cause wireless disactivation or activation during the boot process.
A workaround that i could suggest is not use the posted patch ("asus-led.diff") but to add this lines in /etc/init.d/acpi-support by patching it:
(1)
-----------------------copy from next line-----------------
22a23,36
> log_begin_msg "Checking wireless state..."
> for DEVICE in /sys/class/net/*; do
> if [ -d $DEVICE/wireless ]; then
> # $DEVICE is a wireless device. Check if it's powered on:
> if [ `cat $DEVICE/device/power/state` = 0 ]; then
> # It's powered on.
> echo -n 1 > /proc/acpi/asus/wled
> else
> # It's powered off.
> echo -n 0 > /proc/acpi/asus/wled
> fi
> fi
> done
> log_end_msg 0
24c38
< stop)
---
> stop)
------------------------since previous line--------------------
(2)
paste this to a file save it as patch.diff and run :
(3)
run in a terminal as root: "patch /etc/init.d/acpi-support patch.diff"
NOTE: the "acpi-support" file MUST be the original one!
Hope this bug will be resolved with next acpi-support version!

sittisal

Revision history for this message
sittisal (sittisal) wrote : Working patch for /etc/init.d/acpi-support

Just type:
"patch /etc/init.d/acpi-support /path/to/asuswledpatch.diff"
NOTE: Apply only on original "acpi-support" file

Revision history for this message
sittisal (sittisal) wrote : Re: Initializes the wireless LED status on startup

ok... one problem remains... resume from standby or suspend don't check the led and the wireless status
i think to remove it soon...

Revision history for this message
sittisal (sittisal) wrote : Definitive solution

Hope new version of acpi-support adopt this solution:
I've created a new file called asus-wireless-led.sh; this file should be:
1) resident in /etc/acpi
2) called from /etc/init.d/acpi-support
3) called from /etc/acpi/resume.sh AFTER the loading/unloading of the notebook extras modules (battery,button, fan), so i was thinking to put it in /etc/acpi/resume.d/ script folder but the contents of this folder is executed too early in resume phase.

Bye!

Changed in acpi-support:
status: Unconfirmed → Rejected
Revision history for this message
Nicolò Chieffo (yelo3) wrote : Re: Initializes the wireless LED status on startup

hi sittisal, I'm in your situation too! I'm using an Asus laptop :)
I think that another very important thing to add is to remember the wireless state, so if I disabled in the previous session, the script, after having read it anywhere, decides not to enable the wireless and the led!

Revision history for this message
Paul Sladen (sladen) wrote :

Just the source packages...

Revision history for this message
Paul Sladen (sladen) wrote :

Just one fix will do :)

Changed in acpi-support:
status: Unconfirmed → Rejected
status: Unconfirmed → Confirmed
Paul Sladen (sladen)
Changed in acpi-support:
assignee: mjg59 → sladen
status: Confirmed → In Progress
Revision history for this message
Nicolò Chieffo (yelo3) wrote :

please Paul while doing the fix, take care of this too!
https://launchpad.net/malone/bugs/37010

Revision history for this message
Paul Sladen (sladen) wrote :

 acpi-support (0.65) dapper; urgency=low
   * Synchronise the Asus Wireless LED on start and resume [Malone: #22795]

Changed in acpi-support:
status: In Progress → Fix Released
Revision history for this message
Nicolò Chieffo (yelo3) wrote : Re: [Bug 22795] asus/wled wireless LED has incorrect status on startup

another problem!
if I shitch off the card and then ibernate, when I resume the card is
off but the led is on :)

Changed in acpi-support:
status: Fix Released → Unconfirmed
Revision history for this message
Nicolò Chieffo (yelo3) wrote :

errata corrige: now led and wireless are on.
I think we can put to resolved.

Revision history for this message
Dennis Kaarsemaker (dennis) wrote : Re: [Bug 22795] Re: asus/wled wireless LED has incorrect status on startup

 status FixReleased

Revision history for this message
Paul Sladen (sladen) wrote :

Excellent news, thanks for the testing!

Changed in acpi-support:
status: Unconfirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.