Re: [Bugme-new] [Bug 8995] New: /proc/acpi/alarm worked; update to 2.6.22.2 and /sys/class/rtc/rtc0/wakealarm don't

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Re http://bugzilla.kernel.org/show_bug.cgi?id=8995 ...

On Sunday 09 September 2007, Rafael J. Wysocki wrote:
> I think the suspend/hibernation code ordering changes after
> 2.6.20 are to blame here.

So what's the status of this now ... are we back to having
the /sys/class/rtc/rtc0/wakealarm work with ACPI again, with
/sys/power/state written as "standby", "mem", or "disk"

(At least on the systems where it used to work.  I've had
bad luck with ACPI wake on most systems.  So while it'd be
great to see it working everywhere, I'm just asking about
the regression here.)

- Dave

p.s. some folk may need the appended patch.

=====	CUT HERE
From: Mark Lord <lkml@xxxxxx>

This patch fixes rtc-cmos to ignore the two upper bits when reading
the BCD mday (day of month) register from CMOS.  Some systems (eg. mine)
seem to have the top bit set to "1" for some reason.

Signed-off-by: Mark Lord <mlord@xxxxxxxxx>
Acked-by: David Brownell <dbrownell@xxxxxxxxxxxxxxxxxxxxx>
Cc: Alessandro Zummo <a.zummo@xxxxxxxxxxxx>

--- a/drivers/rtc/rtc-cmos.c	2007-11-03 16:24:09.000000000 -0400
+++ b/drivers/rtc/rtc-cmos.c	2007-11-03 16:26:51.000000000 -0400
@@ -120,7 +120,8 @@
 	t->time.tm_hour = CMOS_READ(RTC_HOURS_ALARM);
 
 	if (cmos->day_alrm) {
-		t->time.tm_mday = CMOS_READ(cmos->day_alrm);
+		/* ignore upper bits on readback per ACPI spec */
+		t->time.tm_mday = CMOS_READ(cmos->day_alrm) & 0x3f;
 		if (!t->time.tm_mday)
 			t->time.tm_mday = -1;
 

_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm

[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux