[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1254875560.12975.5.camel@maxim-laptop>
Date: Wed, 07 Oct 2009 02:32:40 +0200
From: Maxim Levitsky <maximlevitsky@...il.com>
To: David Brownell <david-b@...bell.net>
Cc: linux-kernel <linux-kernel@...r.kernel.org>
Subject: [PATCH] rtc: disable hpet emulation on suspend
Hi,
I noticed that rtc wont generate interrupts after a resume from disk.
Here hpet rtc emulation is used.
Problem is that rtc hpet comparator, isn't reinitialized after resume.
Easiest way to solve this, is always mask all hpet interrupts on suspend
This is triggered, when suspending with alarm set.
----
>>From e0e249d298ab0e92d247fb20440f33adf5e0a923 Mon Sep 17 00:00:00 2001
From: Maxim Levitsky <maximlevitsky@...il.com>
Date: Wed, 7 Oct 2009 02:25:22 +0200
Subject: [PATCH] rtc: disable hpet emulation on suspend
Otherwise, hpet driver will think it doesn't need to reinitialize
the rtc comparator, thus rtc interrupts won't work.
This emulation isn't need for wakealarm.
Signed-off-by: Maxim Levitsky <maximlevitsky@...il.com>
---
drivers/rtc/rtc-cmos.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/rtc/rtc-cmos.c b/drivers/rtc/rtc-cmos.c
index f7a4701..876e3fc 100644
--- a/drivers/rtc/rtc-cmos.c
+++ b/drivers/rtc/rtc-cmos.c
@@ -871,8 +871,9 @@ static int cmos_suspend(struct device *dev, pm_message_t mesg)
mask = RTC_IRQMASK;
tmp &= ~mask;
CMOS_WRITE(tmp, RTC_CONTROL);
- hpet_mask_rtc_irq_bit(mask);
+ /* shut down hpet emulation - we don't need it for alarm */
+ hpet_mask_rtc_irq_bit(RTC_PIE|RTC_AIE|RTC_UIE);
cmos_checkintr(cmos, tmp);
}
spin_unlock_irq(&rtc_lock);
--
1.6.3.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists