Skip to contentSkip to conversation

[2.6.10][Suspend] - Time problems

DISCUSSION Shawn Starr 5 participants 8 messages Jan 11, 2005 – Mar 31, 2005

lore
Share & tools
lore
#0 lore raw

When resuming from suspend, I noticed the clock is waay off (its 10:16pm, it shows 2:34AM EST time). This is even after a reboot the bios now shows wrong time?

Anyone else notice this recently?

Shawn.

#1 lore raw

Hi!

Quoted 3 lines

When resuming from suspend, I noticed the clock is waay off (its 10:16pm, it shows 2:34AM EST time). This is even after a reboot the bios now shows wrong time?

Yes, see for example thread "2.6.10-mm2: swsusp regression [update]". Nigel has some patch that should fix it...

Pavel

Signature · 2 lines
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
#2 lore raw
Quoted 3 lines · Pavel Machek

Hi!

Quoted 1 line

When resuming from suspend, I noticed the clock is waay off (its 10:16pm,

it

Quoted 1 line
Quoted 1 line

shows 2:34AM EST time). This is even after a reboot the bios now shows

wrong

Quoted 4 lines
Quoted 1 line

time?

Yes, see for example thread "2.6.10-mm2: swsusp regression [update]". Nigel has some patch that should fix it...

Do you mean patches in the "[RFC] Patches to reduce delay in arch/kernel/time.c" thread?

RJW

Signature · 3 lines
- Would you tell me, please, which way I ought to go from here?
- That depends a good deal on where you want to get to.
		-- Lewis Carroll "Alice's Adventures in Wonderland"
#3 lore raw

Hi!

Quoted 11 lines
Quoted 1 line
Quoted 1 line

When resuming from suspend, I noticed the clock is waay off (its 10:16pm,

it

Quoted 1 line
Quoted 1 line

shows 2:34AM EST time). This is even after a reboot the bios now shows

wrong

Quoted 4 lines
Quoted 1 line

time?

Yes, see for example thread "2.6.10-mm2: swsusp regression [update]". Nigel has some patch that should fix it...

Do you mean patches in the "[RFC] Patches to reduce delay in arch/kernel/time.c" thread?

I meant this one... (cut&pasted, apply by hand). But it seems to be included in 2.6.11-rc1. I'm now confused.
Pavel

diff -ruNp 910-original-time-patch-old/arch/i386/kernel/time.c 910-original-time-patch-new/arch/i386/kernel/time.c

arch/i386/kernel/time.c 2005-01-08 renamed from arch/i386/kernel/time.c 2004-12-27 +3 -2
@@ -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;
 }
 
Signature · 2 lines
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
#4 lore raw

I'll just bump to 2.6.11-rc1, Rafael, not that one

In either case, it won't be a problem in a few moments. :)

Shawn.

Quoted 43 lines · Pavel Machek

Hi!

Quoted 10 lines
Quoted 2 lines
Quoted 2 lines

When resuming from suspend, I noticed the clock is waay off (its 10:16pm,

it

Quoted 2 lines
Quoted 2 lines

shows 2:34AM EST time). This is even after a reboot the bios now shows

wrong

Quoted 7 lines
Quoted 4 lines
Quoted 1 line

time?

Yes, see for example thread "2.6.10-mm2: swsusp regression [update]". Nigel has some patch that should fix it...

Do you mean patches in the "[RFC] Patches to reduce delay in arch/kernel/time.c" thread?

I meant this one... (cut&pasted, apply by hand). But it seems to be included in 2.6.11-rc1. I'm now confused.
Pavel

diff -ruNp 910-original-time-patch-old/arch/i386/kernel/time.c 910-original-time-patch-new/arch/i386/kernel/time.c

arch/i386/kernel/time.c 2005-01-08 renamed from arch/i386/kernel/time.c 2004-12-27 +3 -2
@@ -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;
 }
#5 lore raw

[2.6.12-rc1] suspend to Disk success - T42 laptop

Hello Pavel, I can now suspend to disk on the laptop with 2.6.12-rc1. There is no failures anymore. It resumes perfectly.

Thank you.

Shawn.

#6 lore raw

Re: [2.6.12-rc1] suspend to Disk success - T42 laptop

Hi!

Quoted 2 lines

Hello Pavel, I can now suspend to disk on the laptop with 2.6.12-rc1. There is no failures anymore. It resumes perfectly.

No video hacks needed? Good.
Pavel

Signature · 2 lines
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
#7 lore raw

Re: [2.6.12-rc1] suspend to Disk success - T42 laptop

Quoted 6 lines · Pavel Machek

Hi!

Quoted 2 lines

Hello Pavel, I can now suspend to disk on the laptop with 2.6.12-rc1. There is no failures anymore. It resumes perfectly.

No video hacks needed? Good.

suspend to disk. !(suspend to RAM).

:-)

Stefan