Author |
Message |
heilig
|
Posted: Sat Jul 19, 2008 2:49 pm |
|
Joined: Sat May 12, 2007 2:41 am
Posts: 51
Location:
Southern Germany
|
While in R5F27 using /proc/acpi/alarm mythwelcome worked perfectly for me, I can't get it to work in R5.5.
mytwelcome-test-wakeup.sh tries to set the time, but the machine never wakes up. After a manual reboot, this is in /tmp/alarm.log:
Code: Shutdown: Sat Jul 19 07:15:35 UTC 2008 Alarm Set: 1216453140 /proc/driver/rtc: rtc_time : 07:15:35 rtc_date : 2008-07-19 alrm_time : 07:39:00 alrm_date : ****-**-** alarm_IRQ : yes alrm_pending : no 24hr : yes periodic_IRQ : no update_IRQ : no DST_enable : no periodic_freq : 1024 batt_status : okay enabled 2051618836
Note the difference between the times in line 2 and the last line. My BIOS does not allow to set a wakeup date, only day of month. It seems that /sys/class/rtc/rtc0/wakealarm does not deal correctly with this. The time difference is not always the same. I tried a few times, and this is what I get: Code: time set cat wakealarm difference /proc/driver/rtc intended alarm time alarm time from `cat wakealarm`
1216340403 2051592499 835252096 00:20:03 Fri, 18 Jul 2008 00:20:03 Fri, 05 Jan 2035 06:48:19 1216325260 2051663756 835338496 don't know Thu, 17 Jul 2008 20:07:40 Sat, 06 Jan 2035 02:35:56 1216332953 2051671449 835338496 22:15:53 Thu, 17 Jul 2008 22:15:53 Sat, 06 Jan 2035 04:44:09 1216333228 2051671724 835338496 22:20:28 Thu, 17 Jul 2008 22:20:28 Sat, 06 Jan 2035 04:48:44 1216342004 2051594100 835252096 00:46:44 Fri, 18 Jul 2008 00:46:44 Fri, 05 Jan 2035 07:15:00 1216342133 2051594229 835252096 00:48:53 Fri, 18 Jul 2008 00:48:53 Fri, 05 Jan 2035 07:17:09 1216453140 2051618836 835165696 07:39:00 Sat, 19 Jul 2008 07:39:00 Fri, 05 Jan 2035 14:07:16
I'm stuck here. Apart from that, the upgrade to 5.5 went smooth, only this is seriously degrading WAF.
I tried both RTC wakeup enabled and disabled in BIOS, but that did not have any effect.
Any hints? What could be going wrong here? And how can I fix it apart from going back to Kernel 2.6.18?
Thanks!
Jens
|
|
Top |
|
|
graysky
|
Posted: Sat Jul 19, 2008 3:32 pm |
|
Joined: Wed Dec 10, 2003 8:31 pm
Posts: 1996
Location:
/dev/null
|
Did you mod your /etc/init.d/hwclock.sh as per this wiki post?
_________________ Retired KM user (R4 - R6.04); friend to LH users.
|
|
Top |
|
|
alien
|
Posted: Sun Jul 20, 2008 4:47 am |
|
Joined: Mon Jun 21, 2004 5:28 am
Posts: 700
Location:
Germany
|
In R5.5, hwclock is already modified.
The stars in the date are normal if you're MB doesn't support a date. However, it is strange that the test wakeup set the time 20 minutes in the future instead of 4.
The last thing you might try is to have the computer wakeup by manually putting a time in the BIOS menus. Shutdown and let it wakeup. Then disable the BIOS setup. My MB sometimes requires this for some reason.
That being said, the new ACPI interface is somewhat disappointing. The old one worked fine for me, but the new one occasionally just didn't wake up. I ended up going back to the nvram-wakeup method. This only requires two small changes (see http://www.knoppmythwiki.org/index.php?page=MythWelcome)
_________________ ASUS AT3N7A-I (Atom 330) TBS 8922 PCI (DVB-S2)
|
|
Top |
|
|
graysky
|
Posted: Sun Jul 20, 2008 3:52 pm |
|
Joined: Wed Dec 10, 2003 8:31 pm
Posts: 1996
Location:
/dev/null
|
Did you see cesman's post in the R5.5 hints and tips thread?
Code: update-rc.d acpid start 12 2 3 4 5 . stop 88 0 1 6 .
I did it on my box, and followed the steps to manually set the wakeup alarm for 5 min and it worked!
Steps listed here. Now I just have to get through resetting mythwelcome
_________________ Retired KM user (R4 - R6.04); friend to LH users.
|
|
Top |
|
|
heilig
|
Posted: Mon Jul 21, 2008 2:52 pm |
|
Joined: Sat May 12, 2007 2:41 am
Posts: 51
Location:
Southern Germany
|
Thanks for the hints. Tried that, but it still doesn't wake up (at least it does not wake up at the right time)
What I did:
* Set a wakeup time in BIOS ==> works. Machine wakes up at the time specified. (besides, it always worked with /proc/acpi/alarm in the past)
* Made acpid start up automatically as per cecil's hint.
* Modified hwclock.sh, to reflect the fact that my machine sets the date incorrectly. In the table above, I notice the time difference between the time the machine is supposed to wake up, and the time that is returned by 'cat wakealarm' is always 06:28:16 (ignoring the date difference). I then wrote "intended wakeup time + 24hours - 06:28:16 hours" to /tmp/alarm before shutting down. The result is that 'cat wakealarm' returns a bogus date (still sometime in 2035), but at least the time part is correct.
But the machine still does not wake up
The real problem I think is that setting the time in /etc/wakeuptime results in bogus data. This looks like a problem in my linux kernel, or in /sys/class/rtc, don't you think?
I have more numbers meanwhile, but they all show that wakealarm contains a bogus date. This is probably due to the fact that my BIOS does not allow to set a *date*, only day of month for wakeup. But somehow linux does not cope with that.
*Any* ideas, how I can fix that?
(Here's more data of wakeup times set and what is the in /sys/class/rts/rtc0/wakealarm)
Code: time set cat wakealarm difference /proc/driver/rtc intended alarm time alarm time from `cat wakealarm` time difference 1216340403 2051592499 835252096 00:20:03 Fri, 18 Jul 2008 00:20:03 Fri, 05 Jan 2035 06:48:19 06:28:16 1216325260 2051663756 835338496 don't know Thu, 17 Jul 2008 20:07:40 Sat, 06 Jan 2035 02:35:56 06:28:16 1216332953 2051671449 835338496 22:15:53 Thu, 17 Jul 2008 22:15:53 Sat, 06 Jan 2035 04:44:09 06:28:16 1216333228 2051671724 835338496 22:20:28 Thu, 17 Jul 2008 22:20:28 Sat, 06 Jan 2035 04:48:44 06:28:16 1216342004 2051594100 835252096 00:46:44 Fri, 18 Jul 2008 00:46:44 Fri, 05 Jan 2035 07:15:00 06:28:16 1216342133 2051594229 835252096 00:48:53 Fri, 18 Jul 2008 00:48:53 Fri, 05 Jan 2035 07:17:09 06:28:16 1216453140 2051618836 835165696 07:39:00 Sat, 19 Jul 2008 07:39:00 Fri, 05 Jan 2035 14:07:16 06:28:16 1216699740 2051606236 834906496 04:09:00 Tue, 22 Jul 2008 04:09:00 Fri, 05 Jan 2035 10:37:16 06:28:16 1216735067 2051641563 834906496 13:57:47 Tue, 22 Jul 2008 13:57:47 Fri, 05 Jan 2035 20:26:03 06:26:16
Thanks for your help!
jens
|
|
Top |
|
|
alien
|
Posted: Tue Jul 22, 2008 2:14 am |
|
Joined: Mon Jun 21, 2004 5:28 am
Posts: 700
Location:
Germany
|
|
Top |
|
|
heilig
|
Posted: Tue Jul 22, 2008 2:38 pm |
|
Joined: Sat May 12, 2007 2:41 am
Posts: 51
Location:
Southern Germany
|
Hi Alien,
good hint, but:
Code: $ sudo nvram-wakeup nvram-wakeup: Your mainboard is currently not supported. nvram-wakeup: Please try determining the addresses and sending the following nvram-wakeup: information back to the maintainers: nvram-wakeup: - The addresses you found out (read README.mb) nvram-wakeup: - Mainboard vendor: ASUSTeK Computer Inc. nvram-wakeup: - Mainboard type: P4P800 nvram-wakeup: - Mainboard revision: Rev 1.xx nvram-wakeup: - BIOS vendor: American Megatrends Inc. nvram-wakeup: - BIOS version: 1021.006 nvram-wakeup: - BIOS release: 08/15/2005
is a little discouraging
I'd really think I need to get ACPI wakeup working. There is a thread on a kernel mailing list which discusses the problem: http://lkml.org/lkml/2007/9/22/13
But either they did not resolve the problem, or I did not understand it. Besides, this might require a newer kernel.
jens
|
|
Top |
|
|
alien
|
Posted: Wed Jul 23, 2008 1:45 am |
|
Joined: Mon Jun 21, 2004 5:28 am
Posts: 700
Location:
Germany
|
You 2005 FW is too "new":
Code: alien$ fgrep P4P800 nvram-wakeup-mb.c { asus_p4p800, "asus_p4p800", "ASUSTeK Computer Inc.", "P4P800", "Rev 1.xx", "American Megatrends Inc.", "080009", "11/06/2003" }, { asus_p4p800, "asus_p4p800", "ASUSTeK Computer Inc.", "P4P800", "Rev 1.xx", "American Megatrends Inc.", "080009", "12/12/2003" }, { asus_p4p800_vm, "asus_p4p800_vm", "ASUSTeK Computer INC.", "P4P800-VM", "Rev 1.xx", "American Megatrends Inc.", "1007.001", "07/01/2003" }, { asus_p4p800_vm_2, "asus_p4p800_vm_2", "ASUSTeK Computer INC.", "P4P800-VM", "Rev 1.xx", "American Megatrends Inc.", "1008.008", "10/31/2003" }, { asus_p4p800_vm_2, "asus_p4p800_vm_2", "ASUSTeK Computer INC.", "P4P800-VM", "Rev 1.xx", "American Megatrends Inc.", "1012.002", "03/22/2004" }, alien$ There is a tool called guess-helper that will help you build a config file for an unrecognised board. See /usr/share/doc/nvram-wakeup/README.mb.gz for more information.
Alternatively, you can try "nvram-wakeup -I asus_p4p800". It will probably work, but there is a small chance of corrupting something if the FW has changed significantly. I don't recommend this (even though it is what I did before my MB FW was supported a couple of years ago).
_________________ ASUS AT3N7A-I (Atom 330) TBS 8922 PCI (DVB-S2)
|
|
Top |
|
|
marc.aronson
|
Posted: Sat Jul 26, 2008 9:52 pm |
|
Joined: Tue Jan 18, 2005 2:07 am
Posts: 1532
Location:
California
|
heilig, I am having the same problem you are having. My mobo is an asus p5p800-SE. This is turning into a show-stopper for my upgrade, as the ACPI wakeup under R5F27 reduced my power consumption by over 67%.
Have you had any luck in moving this forward?
Marc
|
|
Top |
|
|
heilig
|
Posted: Sun Jul 27, 2008 1:06 pm |
|
Joined: Sat May 12, 2007 2:41 am
Posts: 51
Location:
Southern Germany
|
Hi Marc,
marc.aronson wrote: Have you had any luck in moving this forward? Marc
No, not yet. I will do what alien proposed: Use nvram-wakeup. Unfortunately, my motherboard is not directly supported, so this will take some time to understand and get working...
I'm probably missing something trivial, since few people report issues with /sys/class/rtc wakeup (at least I did not find many through google). But I can't find what it is
jens
|
|
Top |
|
|
marc.aronson
|
Posted: Sun Jul 27, 2008 5:11 pm |
|
Joined: Tue Jan 18, 2005 2:07 am
Posts: 1532
Location:
California
|
heilig wrote: I'm probably missing something trivial, since few people report issues with /sys/class/rtc wakeup (at least I did not find many through google). But I can't find what it is : jens
If it's any consolation I've found a few posts out there where others are having the problem, but no definitive fixes. I've included a few links below in case you're interested.
One thought that comes to mind is that my mobo has a "fussy bios" that required me to to use the work around where you write the wakeup time to /proc/acpi/alarm twice before shutting down. With the new interface, you have to write a "0" to "/sys/class/rtc/rtc0/wakealarm" before you can write out the target time. I've tried executing this sequence twice i a row, but that didn't help. The question that comes to my mind is if the act of writing "0" to wakealarm essentially breaks the "fussy bios" work around, because now the bios is not seeing the same value written out twice in a row...
Marc
http://linux.derkeiler.com/Mailing-List ... 02599.html
http://lists.linuxcoding.com/rhl/2007q3/msg07860.html
http://www.mail-archive.com/linux-acpi@ ... 08919.html
|
|
Top |
|
|
alien
|
Posted: Mon Jul 28, 2008 2:08 am |
|
Joined: Mon Jun 21, 2004 5:28 am
Posts: 700
Location:
Germany
|
Writing 0 into wakealarm is done by default in /etc/init.d/hwclock.sh. You can try commenting it out to see if it makes a difference with your MB.
If it works, let us know.
_________________ ASUS AT3N7A-I (Atom 330) TBS 8922 PCI (DVB-S2)
|
|
Top |
|
|
marc.aronson
|
Posted: Mon Jul 28, 2008 7:23 am |
|
Joined: Tue Jan 18, 2005 2:07 am
Posts: 1532
Location:
California
|
alien wrote: Writing 0 into wakealarm is done by default in /etc/init.d/hwclock.sh. You can try commenting it out to see if it makes a difference with your MB.
If it works, let us know.
Alien, thank you for the suggestion. Actually, I've already tried that and it didn't work. I then tried setting wakealarm from a command prompt without writing "0" before the second echo of the timestamp, but the second attempt always yields an error message to the effects that the file is not available, or some such thing. In reading various threads, it appears the kernel is written to reject an attempt to write to wakealarm if the alarm is already set to a non-zero value.
It's almost as if in designing the new interface, they inadvertently made it so that it can't work with a bios that requires that the time stamp be written twice in a row.
I've done a bunch of googe'ing, but I haven't found any ideas for fixing this. Any ideas would be appreciated. Is it possible to add back the "/proc/acpi/alarm" interface in the kernel built for knoppmyth?
Marc
|
|
Top |
|
|
marc.aronson
|
Posted: Tue Jul 29, 2008 8:56 am |
|
Joined: Tue Jan 18, 2005 2:07 am
Posts: 1532
Location:
California
|
I no longer have an accessible r5.5 system. If someone could check to see if r5.5 includes the "rtcwake" command, I would appreciate it. An easy way to check would be to login as root and enter the command "rtcwake --help", thanks.
Marc
|
|
Top |
|
|
heilig
|
Posted: Tue Jul 29, 2008 3:09 pm |
|
Joined: Sat May 12, 2007 2:41 am
Posts: 51
Location:
Southern Germany
|
Hi Marc,
my R5.5 does NOT include rtcwake (locate rtcwake does not find anything)
jens
|
|
Top |
|
|