* wrong system time after wakeup
@ 2005-01-10 19:39 Peter Münster
[not found] ` <Pine.LNX.4.58.0501102008270.22897-iBKnCo7tEuSksujEA26zIQ@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Peter Münster @ 2005-01-10 19:39 UTC (permalink / raw)
To: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
Hello,
when resuming from S1, the system-time is completely wrong: about 22h
instead of 11h.
The system goes to sleep the day before at about 22h30 with the following
commands:
modprobe genrtc
sleep 5
echo 2005-01-11 11:10:00 >/proc/acpi/alarm
sleep 5
echo 1 >/proc/acpi/sleep
What could be wrong?
I'm using Linux-2.6.10 and ASUS A7N8X-X ACPI BIOS Rev 1006.
Thanks in advance for any help! Please tell me, if you need more information.
Kind regards, Peter
--
http://pmrb.free.fr/contact/
------------------------------------
Film Search site: http://f-s.sf.net/
-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: wrong system time after wakeup
[not found] ` <Pine.LNX.4.58.0501102008270.22897-iBKnCo7tEuSksujEA26zIQ@public.gmane.org>
@ 2005-01-10 20:44 ` Nigel Cunningham
0 siblings, 0 replies; 2+ messages in thread
From: Nigel Cunningham @ 2005-01-10 20:44 UTC (permalink / raw)
To: Peter Münster; +Cc: ACPI List
Hi Peter.
That attached little patch will fix your issue.
Regards,
Nigel
diff -ruNp 910-original-time-patch-old/arch/i386/kernel/time.c 910-original-time-patch-new/arch/i386/kernel/time.c
--- 910-original-time-patch-old/arch/i386/kernel/time.c 2004-12-27 10:03:24.000000000 +1100
+++ 910-original-time-patch-new/arch/i386/kernel/time.c 2005-01-08 10:23:28.335811408 +1100
@@ -343,12 +343,13 @@ static int timer_resume(struct sys_devic
hpet_reenable();
#endif
sec = get_cmos_time() + clock_cmos_diff;
- sleep_length = get_cmos_time() - sleep_start;
+ sleep_length = (get_cmos_time() - sleep_start) * HZ;
write_seqlock_irqsave(&xtime_lock, flags);
xtime.tv_sec = sec;
xtime.tv_nsec = 0;
write_sequnlock_irqrestore(&xtime_lock, flags);
- jiffies += sleep_length * HZ;
+ jiffies += sleep_length;
+ wall_jiffies += sleep_length;
return 0;
}
On Tue, 2005-01-11 at 06:39, Peter Münster wrote:
> Hello,
> when resuming from S1, the system-time is completely wrong: about 22h
> instead of 11h.
> The system goes to sleep the day before at about 22h30 with the following
> commands:
> modprobe genrtc
> sleep 5
> echo 2005-01-11 11:10:00 >/proc/acpi/alarm
> sleep 5
> echo 1 >/proc/acpi/sleep
>
> What could be wrong?
> I'm using Linux-2.6.10 and ASUS A7N8X-X ACPI BIOS Rev 1006.
>
> Thanks in advance for any help! Please tell me, if you need more information.
> Kind regards, Peter
--
Nigel Cunningham
Software Engineer, Canberra, Australia
http://www.cyclades.com
Ph: +61 (2) 6292 8028 Mob: +61 (417) 100 574
-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-01-10 20:44 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-01-10 19:39 wrong system time after wakeup Peter Münster
[not found] ` <Pine.LNX.4.58.0501102008270.22897-iBKnCo7tEuSksujEA26zIQ@public.gmane.org>
2005-01-10 20:44 ` Nigel Cunningham
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox