ACPI Wakeup reset during reboot

Bug #403918 reported by voidAndAny on 2009-07-24
34
This bug affects 5 people
Affects Status Importance Assigned to Milestone
acpi (Ubuntu)
Undecided
Unassigned

Bug Description

My PC clock is set to local time and I use the folowing script to setup ACPI Wakeup :

#! /bin/bash
SECS=`date -u --date "$1" +%s`
echo 0 > /sys/class/rtc/rtc0/wakealarm
echo $SECS > /sys/class/rtc/rtc0/wakealarm
cat /proc/driver/rtc

When I use this script, shutdown my PC and wait for the wakeup everything works fine.

But If I manually re-start and stop my PC before date/time alarm my PC don't Wakeup.

alrm_time is not changed, alrm_date is changed to ****-**-** (it seems that my BIOS don't use date for wakeup) and alarm_IRQ is set to no

it's like something reset acpi wakeup at reboot.

For information everything was OK with /proc/acpi/alarm on Gutsy (my PC wakeup everynight at 01:00 without have to setup acpi wakeup date/time at shutdown - no date, only time in BIOS wakeup settings)

> sudo set_acpi.sh "2009-07-21 23:00:00"

rtc_time : 22:06:16
rtc_date : 2009-07-21
alrm_time : 23:00:00
alrm_date : 2009-07-21
alarm_IRQ : yes
alrm_pending : no
24hr : yes
periodic_IRQ : no
update_IRQ : no
HPET_emulated : no
DST_enable : no
periodic_freq : 1024
batt_status : okay

> sudo shutdown -r now

... PC restart .....

> cat /proc/driver/rtc

rtc_time : 22:08:46
rtc_date : 2009-07-21
alrm_time : 23:00:00
alrm_date : ****-**-**
alarm_IRQ : no
alrm_pending : no
24hr : yes
periodic_IRQ : no
update_IRQ : no
HPET_emulated : no
DST_enable : no
periodic_freq : 1024
batt_status : okay

> sudo shutdown -r now

... PC stop and nothing happened at 23:00....

Thanks
Yoann

MarcRandolph (mrand) wrote :

Multiple people continue having the same problem that was previously reported as resolved in Bug #139846 (which points to an upstream problem that may contain a work-around: http://bugzilla.kernel.org/show_bug.cgi?id=12013)

affects: ubuntu → acpi (Ubuntu)
tseller (tomseller) wrote :

Exactly the same for me using Mythbuntu 9.10. Setting RTC alarm works, PC wakes up at the specified time. But if i reboot manully before the wakeup should happen, alrm_date is set to ****-**-** and alarm_IRQ to no. So the planned wakeup set earlier doesn't happen anymore. If i don't reboot, only just shutdown -h now and wait until the specified time is reached, the PC wakes up normally.

- HWclock updates are disabled during shutdown (via HWCLOCKACCESS=no and an edited hwclock-save.conf)
- Wakeup by RTC Alarm in Bios is off
- Tried setting kernel param hpet=disable, but it doesn't solve the problem

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in acpi (Ubuntu):
status: New → Confirmed
Vlado Plaga (vlado-gmx) wrote :

Too bad bugzilla.kernel.org has now been down for so many weeks... so this issue can't be taken to where it probably should really be discussed.

Here is the workaround I'm now using:

I'm writing the desired wakeup time both to /sys/class/rtc/rtc0/wakealarm and to a file on the file system (/etc/wakeup_time) and in /etc/rc.local I included:

"cat /etc/wakeup_time > /sys/class/rtc/rtc0/wakealarm"

This seems to work reliably enough, but still it's just a workaround and people will loose time by stumbling upon this bug, as I did.

This problem seems to exist for years already, according to some reports. More than a year ago I set up a dual-boot PPC Mac mini to wake up on certain days to record certain radio shows, and I noticed I could not boot Linux anymore because that reset the programmed wakeup time. That system did not have ACPI of course, and I thought booting Mac OS was required to refresh the RTC on every reboot... but maybe it was just this issue.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Related questions

Remote bug watches

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