filling in ACPI files in sysfs
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): 20040408151905.22469.qmail-BgaQW1HgEmiA/[email protected]
Hi Alex,
I found this
echo 0 > _DCK
echo 1 > _EJ0
for undock and
echo 1 > _DCK
for dock, just a couple of hours ago by reading the ACPI 2.0c spec. Yes, you are right, is is more complete, like shutting off the LED, but still does not electromechanicaly eject the button. But this is something else, and I think it has to do with _Q50 on my system. When I press the eject button, acpi executes _Q50, and electromechaniclay ejects the eject button.
Quoted 8 lines · --- Alex Williamson
Subject: Re: [ACPI] [RFC] filling in ACPI files in
sysfs
From: Alex Williamson <[email protected]>
To: Paul Ionescu <i_p_a_u_l-/[email protected]>
CC: [email protected]
Date: Thu, 08 Apr 2004 08:36:59 -0600On Thu, 2004-04-08 at 02:14, Paul Ionescu wrote:
Quoted 13 lines
Quoted 4 lines
Hi Alex,
I attached a file containing what I have in
/sys/firmware/acpiwith your second patch.Thanks, looks like your namespace is more
complete than on my old
omnibook.Quoted 3 lines
I also tried the docking station with:
echo 1 >
/sys/firmware/acpi/namespace/ACPI/_SB/PCI0/PCI1/DOCK/_DCK
Quoted 6 lines
Quoted 5 lines
and
echo 0 >
/sys/firmware/acpi/namespace/ACPI/_SB/PCI0/PCI1/DOCK/_DCK
Quoted 58 lines
Quoted 4 lines
with this commands I semi turned on/off the doking station. I say semi because is not fully on/off. When I turn it on (echo 1 >
_DCK), the dockingstation
Quoted 4 lines
fan starts, and the LED indicating the usage of docking station turns on, but I dont see the new devices from the docking station (2 new usb, 2 new cardbus, 1 new ide, 1 new pci etc). I suspect this
is
Quoted 1 line
not your patch fault, but the way ACPI handles
this
Quoted 2 lines
event. It should add the new description tables of ACPI devices on the fly not only at boot time.
When it
Quoted 1 line
boots without docking station ACPI has no way to
know
Quoted 1 line
what will be in my docking station, so it has to
add
Quoted 2 lines
new devices after inserting and activating the docking.
Yes, as far as I'm aware, we don't try to
re-parse acpi namespace
after such events. I'm not trying to solve that problem though. This
is also just a raw interface to the acpi methods, so undocking w/o
handling the things that will get removed may be unsafe. I envision it
being an interface by which hotplug could evaluate, via the_EJD
methods, what devices will go away and do smart things prior to the
actual eject. On my docking station, there's no obvious effect of
calling the_DCKmethod, but calling_EJ0pops it out. Also, I see all
3 possible batteries under/proc/acpi/battery(even though only 1 is
plugged in), so I doubt this patch is changing that behavior at all.Quoted 1 line
Now, when I turn it off (with echo 0 >
_DCK), thefan
Quoted 4 lines
stops, but the ACTIVE led is still on, and the electromechanical eject was not activated.
Is this the way I was supposed to test docking ?
Try the
_EJ0method. Assuming all device that
you'll lose are
quiesced and removed (probably everything that lists _SB.PCI0.PCI1.DOCK
in their_EJDmethod), I believe you need to do the following sequence:
Quoted 12 lines
echo 0 >
_DCK
echo 1 >_EJ0And after you re-dock, you should probably echo 1 >
_DCK. Thanks,Alex
Signature · 2 lines
Alex Williamson HP Linux & Open Source Lab
__________________________________
Do you Yahoo!?
Yahoo! Small Business $15K Web Design Giveaway
http://promotions.yahoo.com/design_giveaway/
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click