* /proc/acpi/alarm -- does it work or not?
@ 2005-12-26 20:43 Pavel Machek
[not found] ` <20051226204305.GA2028-I/5MKhXcvmPrBKCeMvbIDA@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Pavel Machek @ 2005-12-26 20:43 UTC (permalink / raw)
To: shaohua.li-ral2JQCrhuEAvxtiuMwx3w,
ronald.mythtv-Re5JQEeQqe8AvxtiuMwx3w,
acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
Hi!
I wanted to write some documentation about /proc/acpi/alarm, but
failed to make it work. I was putting machine to suspend-to-ram and
enabled everything in /proc/acpi/wakeup, still it would not do
anything. I even went to bios (thinkpad x32), set "RTC alarm" to
enabled and set time there. Nothing interesting
happened. /proc/acpi/alarm could not see most of my changes done in
BIOS, it only cleared century or something like that.
I checked that RTC readout in BIOS shows same thing as system timer.
Here are my attempts: [Commands were typed one-after-another where it
makes sense, and I left machine suspended for long enough -- timer
should have expired]
root@amd:/proc/acpi# cat alarm
2005-12-00 01:03:24
root@amd:/proc/acpi# echo '0-0-0 22:35:00' > alarm
root@amd:/proc/acpi# cat alarm
0005-12-00 22:35:00
root@amd:/proc/acpi# s2ram
Freezing cpus ...
Stopping tasks: ====================================|
ACPI: PCI interrupt for device 0000:02:01.0 disabled
ACPI: PCI interrupt for device 0000:02:00.1 disabled
ACPI: PCI interrupt for device 0000:02:00.0 disabled
radeonfb (0000:01:00.0): suspending to state: 2...
radeonfb (0000:01:00.0): resuming from state: 2...to 64er 10 Dec 2004
Restarting tasks... done
Thawing cpus ...
root@amd:/proc/acpi# date
Sun Dec 25 22:36:46 CET 2005
root@amd:/proc/acpi# cat alarm
0005-12-00 22:35:00
root@amd:/proc/acpi#
root@amd:/proc/acpi# cat alarm
0005-12-00 22:35:00
root@amd:/proc/acpi# echo '*-*-* 22:40:00' > alarm
root@amd:/proc/acpi# cat alarm
0005-12-00 22:35:00
root@amd:/proc/acpi# echo '2005-12-25 22:40:00' > alarm
root@amd:/proc/acpi# cat alarm
2005-12-25 22:40:00
root@amd:/proc/acpi# date
Sun Dec 25 22:37:53 CET 2005
root@amd:/proc/acpi# s2ram
Freezing cpus ...
Stopping tasks: =====================================|
ACPI: PCI interrupt for device 0000:02:01.0 disabled
ACPI: PCI interrupt for device 0000:02:00.1 disabled
ACPI: PCI interrupt for device 0000:02:00.0 disabled
radeonfb (0000:01:00.0): suspending to state: 2...
radeonfb (0000:01:00.0): resuming from state: 2...to 64er 10 Dec 2004
Restarting tasks... done
Thawing cpus ...
root@amd:/proc/acpi# date
Sun Dec 25 22:41:14 CET 2005
root@amd:/proc/acpi#
...so... what am I doing wrong? Is thinkpad x32 machine where it does
not work?
Pavel
--
Thanks, Sharp!
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread[parent not found: <59D45D057E9702469E5775CBB56411F1013CF084@pdsmsx406>]
* Re: /proc/acpi/alarm -- does it work or not?
[not found] <59D45D057E9702469E5775CBB56411F1013CF084@pdsmsx406>
@ 2006-01-09 15:44 ` Pavel Machek
2006-01-10 3:20 ` Shaohua Li
0 siblings, 1 reply; 5+ messages in thread
From: Pavel Machek @ 2006-01-09 15:44 UTC (permalink / raw)
To: Li, Shaohua; +Cc: ronald.mythtv, kernel list
Hi!
> >I wanted to write some documentation about /proc/acpi/alarm, but
> >failed to make it work. I was putting machine to suspend-to-ram and
> >enabled everything in /proc/acpi/wakeup, still it would not do
> >anything. I even went to bios (thinkpad x32), set "RTC alarm" to
> >enabled and set time there. Nothing interesting
> >happened. /proc/acpi/alarm could not see most of my changes done in
> >BIOS, it only cleared century or something like that.
> >
> >I checked that RTC readout in BIOS shows same thing as system timer.
> >
> >Here are my attempts: [Commands were typed one-after-another where it
> >makes sense, and I left machine suspended for long enough -- timer
> >should have expired]
> It appears we need enable rtc driver to make alarm work.
I enabled CONFIG_RTC:
pavel@amd:/data/l/linux$ grep CONFIG_RTC .config
CONFIG_RTC=y
# CONFIG_RTC_X1205_I2C is not set
pavel@amd:/data/l/linux$
...but /proc/acpi/alarm still behaves very strangely:
2006-01-00 12:42:00
root@amd:/proc/acpi# echo '2006-01-01 12:34:56' > alarm
root@amd:/proc/acpi# cat alarm
2006-01-01 12:34:56
root@amd:/proc/acpi# echo '2006-09-01 12:34:56' > alarm
root@amd:/proc/acpi# cat alarm
2006-01-01 12:34:56
root@amd:/proc/acpi# echo '2006-01-09 12:34:56' > alarm
root@amd:/proc/acpi# cat alarm
2006-01-09 12:34:56
root@amd:/proc/acpi# echo '2006-02-09 12:34:56' > alarm
root@amd:/proc/acpi# cat alarm
2006-01-09 12:34:56
root@amd:/proc/acpi#
...why does it hate february and september?
Pavel
--
Thanks, Sharp!
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: /proc/acpi/alarm -- does it work or not?
2006-01-09 15:44 ` Pavel Machek
@ 2006-01-10 3:20 ` Shaohua Li
2006-01-15 15:13 ` Pavel Machek
0 siblings, 1 reply; 5+ messages in thread
From: Shaohua Li @ 2006-01-10 3:20 UTC (permalink / raw)
To: Pavel Machek; +Cc: ronald.mythtv, kernel list
On Mon, 2006-01-09 at 16:44 +0100, Pavel Machek wrote:
> Hi!
>
> > >I wanted to write some documentation about /proc/acpi/alarm, but
> > >failed to make it work. I was putting machine to suspend-to-ram and
> > >enabled everything in /proc/acpi/wakeup, still it would not do
> > >anything. I even went to bios (thinkpad x32), set "RTC alarm" to
> > >enabled and set time there. Nothing interesting
> > >happened. /proc/acpi/alarm could not see most of my changes done in
> > >BIOS, it only cleared century or something like that.
> > >
> > >I checked that RTC readout in BIOS shows same thing as system timer.
> > >
> > >Here are my attempts: [Commands were typed one-after-another where it
> > >makes sense, and I left machine suspended for long enough -- timer
> > >should have expired]
> > It appears we need enable rtc driver to make alarm work.
>
> I enabled CONFIG_RTC:
>
> pavel@amd:/data/l/linux$ grep CONFIG_RTC .config
> CONFIG_RTC=y
> # CONFIG_RTC_X1205_I2C is not set
It appears CONFIG_RTC isn't related with the issue. In my test system,
if I didn't CONFIG_RTC, `date` shows wrong time, that's why I need RTC.
> pavel@amd:/data/l/linux$
>
> ...but /proc/acpi/alarm still behaves very strangely:
>
> 2006-01-00 12:42:00
> root@amd:/proc/acpi# echo '2006-01-01 12:34:56' > alarm
> root@amd:/proc/acpi# cat alarm
> 2006-01-01 12:34:56
> root@amd:/proc/acpi# echo '2006-09-01 12:34:56' > alarm
> root@amd:/proc/acpi# cat alarm
> 2006-01-01 12:34:56
> root@amd:/proc/acpi# echo '2006-01-09 12:34:56' > alarm
> root@amd:/proc/acpi# cat alarm
> 2006-01-09 12:34:56
> root@amd:/proc/acpi# echo '2006-02-09 12:34:56' > alarm
> root@amd:/proc/acpi# cat alarm
> 2006-01-09 12:34:56
> root@amd:/proc/acpi#
>
> ...why does it hate february and september?
No. Setting day, month, century for alarm is optional. This means your
system doesn't support setting month and century. But maybe we should
print some infos here ...
Thanks,
Shaohua
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /proc/acpi/alarm -- does it work or not?
2006-01-10 3:20 ` Shaohua Li
@ 2006-01-15 15:13 ` Pavel Machek
0 siblings, 0 replies; 5+ messages in thread
From: Pavel Machek @ 2006-01-15 15:13 UTC (permalink / raw)
To: Shaohua Li; +Cc: ronald.mythtv, kernel list
Hi!
> > pavel@amd:/data/l/linux$
> >
> > ...but /proc/acpi/alarm still behaves very strangely:
> >
> > 2006-01-00 12:42:00
> > root@amd:/proc/acpi# echo '2006-01-01 12:34:56' > alarm
> > root@amd:/proc/acpi# cat alarm
> > 2006-01-01 12:34:56
> > root@amd:/proc/acpi# echo '2006-09-01 12:34:56' > alarm
> > root@amd:/proc/acpi# cat alarm
> > 2006-01-01 12:34:56
> > root@amd:/proc/acpi# echo '2006-01-09 12:34:56' > alarm
> > root@amd:/proc/acpi# cat alarm
> > 2006-01-09 12:34:56
> > root@amd:/proc/acpi# echo '2006-02-09 12:34:56' > alarm
> > root@amd:/proc/acpi# cat alarm
> > 2006-01-09 12:34:56
> > root@amd:/proc/acpi#
> >
> > ...why does it hate february and september?
> No. Setting day, month, century for alarm is optional. This means your
> system doesn't support setting month and century. But maybe we should
> print some infos here ...
Yes, more info would be nice. What is "correct" way to test
if systen supports day/month/year/century in alarm?
Pavel
--
Thanks, Sharp!
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2006-01-18 14:16 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-12-26 20:43 /proc/acpi/alarm -- does it work or not? Pavel Machek
[not found] ` <20051226204305.GA2028-I/5MKhXcvmPrBKCeMvbIDA@public.gmane.org>
2005-12-28 18:24 ` Karol Kozimor
[not found] <59D45D057E9702469E5775CBB56411F1013CF084@pdsmsx406>
2006-01-09 15:44 ` Pavel Machek
2006-01-10 3:20 ` Shaohua Li
2006-01-15 15:13 ` Pavel Machek
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.