[prev in list] [next in list] [prev in thread] [next in thread]
List: linuxbios
Subject: [coreboot] ACPI: S3 wakeup from USB keyboard
From: <aladyshev () nicevt ! ru>
Date: 2013-06-20 13:34:53
Message-ID: 40573019168648E5AA4BEBD5D41B492B () Aladyshev
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
I am trying to enable S3 wakeup from USB keyboard in Linux.
After boot, if i execute in terminal command <cat /proc/acpi/wakeup> i get:
Device S-state Status Sysfs node
PCI0 S5 disabled no-bus:pci0000:00
HDEF S4 disabled pci:0000:00:1b.0
RP01 S5 disabled pci:0000:00:1c.0
RP02 S5 disabled pci:0000:00:1c.1
RP03 S5 disabled pci:0000:00:1c.2
RP04 S5 disabled pci:0000:00:1c.3
RP05 S5 disabled pci:0000:00:1c.4
RP06 S5 disabled pci:0000:00:1c.5
USB1 S3 disabled pci:0000:00:1d.0
USB2 S3 disabled pci:0000:00:1d.1
USB3 S3 disabled pci:0000:00:1d.2
USB4 S3 disabled pci:0000:00:1d.3
EHC1 S3 disabled pci:0000:00:1d.7
MODM S4 disabled
COMA S3 disabled pnp:00:08
COMB S3 disabled pnp:00:09
At my guess, current devices are devices from DSDT table with _PRW method. But for \
some reason (why?) wakeup for them disabled by default. I can enable wakeup for \
keyboard (in my case it is USB1) with:
echo PCI0 > /proc/acpi/wakeup
echo USB1 > /proc/acpi/wakeup
Throught some experiments i figured out, that these commands says to OS, that it \
should enable appropriate bits in ACPI GPE0_EN register before going to S3 (what bits \
exactly is defined in PCI0._PRW and USB1._PRW)
But this is not the end. I think OS power off USB controller when it goes to S3. To \
fix this i found device USB number from dmesg:
[ 2.724374] input: LITEON Technology USB Multimedia Keyboard as \
/devices/pci0000:00/0000:00:1d.0/usb2/2-2/2-2:1.0/input/input6
And executed command <echo enabled > /sys/bus/usb/devices/2-2/power/wakeup>
And only now wakeup from USB fully works.
My question is, how i should change DSDT/BIOS, to avoid all of these commands?
I think main problem is a lack of something in DSDT.
Some fragments from current DSDT:
...
Device (USB1)
{
Name(_ADR, 0x001D0000)
Name(_PRW, Package(0x02){ 0x03, 0x03 })
Method(_S3D,0)
{
Return(2)
}
}
...
Scope (\_GPE)
{
..
// USB1
Method (_L03, 0)
{
Notify (\_SB.PCI0.USB1, 0x02)
}
..
}
[Attachment #5 (text/html)]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=koi8-r" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.23501">
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV>I am trying to enable S3 wakeup from USB keyboard in Linux.</DIV>
<DIV>After boot, if i execute in terminal command «cat /proc/acpi/wakeup» i
get:<BR><BR><BR>Device S-state Status Sysfs node<BR>PCI0 S5 disabled
no-bus:pci0000:00<BR>HDEF S4 disabled pci:0000:00:1b.0<BR>RP01 S5 disabled
pci:0000:00:1c.0<BR>RP02 S5 disabled pci:0000:00:1c.1<BR>RP03 S5 disabled
pci:0000:00:1c.2<BR>RP04 S5 disabled pci:0000:00:1c.3<BR>RP05 S5 disabled
pci:0000:00:1c.4<BR>RP06 S5 disabled pci:0000:00:1c.5<BR>USB1 S3 disabled
pci:0000:00:1d.0<BR>USB2 S3 disabled pci:0000:00:1d.1<BR>USB3 S3 disabled
pci:0000:00:1d.2<BR>USB4 S3 disabled pci:0000:00:1d.3<BR>EHC1 S3 disabled
pci:0000:00:1d.7<BR>MODM S4 disabled <BR>COMA S3 disabled pnp:00:08<BR>COMB S3
disabled pnp:00:09<BR><BR>At my guess, current devices are devices from DSDT
table with _PRW method. But for some reason (why?) wakeup for them disabled by
default.<BR>I can enable wakeup for keyboard (in my case it is USB1)
with:<BR><BR><BR>echo PCI0 > /proc/acpi/wakeup<BR><BR>echo USB1 >
/proc/acpi/wakeup<BR><BR><BR>Throught some experiments i figured out, that these
commands says to OS, that it should enable appropriate bits in ACPI GPE0_EN
register before going to S3 (what bits exactly is defined in PCI0._PRW and
USB1._PRW)<BR><BR>But this is not the end. I think OS power off USB controller
when it goes to S3. To fix this i found device USB number from dmesg:<BR><BR>[
2.724374] input: LITEON Technology USB Multimedia Keyboard as
/devices/pci0000:00/0000:00:1d.0/usb2/2-2/2-2:1.0/input/input6<BR><BR>And
executed command «echo enabled >
/sys/bus/usb/devices/2-2/power/wakeup»<BR><BR>And only now wakeup from USB fully
works.<BR><BR>My question is, how i should change DSDT/BIOS, to avoid all of
these commands? </DIV>
<DIV>I think main problem is a lack of something in DSDT. </DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>Some fragments from current DSDT:</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>....</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>Device (USB1)<BR>{<BR>
Name(_ADR, 0x001D0000)</FONT></DIV>
<DIV><FONT size=2 face=Arial> Name(_PRW,
Package(0x02){ 0x03, 0x03 })</FONT></DIV>
<DIV><FONT size=2 face=Arial>
Method(_S3D,0)</FONT></DIV>
<DIV><FONT size=2 face=Arial> {</FONT></DIV>
<DIV><FONT size=2 face=Arial>
Return(2)</FONT></DIV>
<DIV><FONT size=2 face=Arial> }<BR>}</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>....</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>Scope (\_GPE)<BR>{</FONT></DIV>
<DIV><FONT size=2 face=Arial>...</FONT></DIV>
<DIV><FONT size=2 face=Arial> // USB1<BR> Method (_L03, 0)<BR>
{<BR> Notify (\_SB.PCI0.USB1, 0x02)<BR>
}</FONT></DIV>
<DIV><FONT size=2 face=Arial>...</FONT></DIV>
<DIV><FONT size=2 face=Arial>}</FONT></DIV></BODY></HTML>
--
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic