[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1217140707-21263-6-git-send-email-cooloney@kernel.org>
Date: Sun, 27 Jul 2008 14:38:24 +0800
From: Bryan Wu <cooloney@...nel.org>
To: a.zummo@...ertech.it, rtc-linux@...glegroups.com
Cc: akpm@...ux-foundation.org, linux-kernel@...r.kernel.org,
Mike Frysinger <vapier.adi@...il.com>,
Bryan Wu <cooloney@...nel.org>
Subject: [PATCH 5/8] Blackfin RTC Driver: disable the write complete irq upon close
From: Mike Frysinger <vapier.adi@...il.com>
Signed-off-by: Mike Frysinger <vapier.adi@...il.com>
Signed-off-by: Bryan Wu <cooloney@...nel.org>
---
drivers/rtc/rtc-bfin.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/rtc/rtc-bfin.c b/drivers/rtc/rtc-bfin.c
index 56656dd..d53772f 100644
--- a/drivers/rtc/rtc-bfin.c
+++ b/drivers/rtc/rtc-bfin.c
@@ -144,13 +144,13 @@ static void bfin_rtc_sync_pending(struct device *dev)
* Initialize the RTC. Enable pre-scaler to scale RTC clock
* to 1Hz and clear interrupt/status registers.
*/
-static void bfin_rtc_reset(struct device *dev)
+static void bfin_rtc_reset(struct device *dev, u16 rtc_ictl)
{
struct bfin_rtc *rtc = dev_get_drvdata(dev);
dev_dbg_stamp(dev);
bfin_rtc_sync_pending(dev);
bfin_write_RTC_PREN(0x1);
- bfin_write_RTC_ICTL(RTC_ISTAT_WRITE_COMPLETE);
+ bfin_write_RTC_ICTL(rtc_ictl);
bfin_write_RTC_SWCNT(0);
bfin_write_RTC_ALARM(0);
bfin_write_RTC_ISTAT(0xFFFF);
@@ -226,7 +226,7 @@ static int bfin_rtc_open(struct device *dev)
ret = request_irq(IRQ_RTC, bfin_rtc_interrupt, IRQF_SHARED, to_platform_device(dev)->name, dev);
if (!ret)
- bfin_rtc_reset(dev);
+ bfin_rtc_reset(dev, RTC_ISTAT_WRITE_COMPLETE);
return ret;
}
@@ -234,7 +234,7 @@ static int bfin_rtc_open(struct device *dev)
static void bfin_rtc_release(struct device *dev)
{
dev_dbg_stamp(dev);
- bfin_rtc_reset(dev);
+ bfin_rtc_reset(dev, 0);
free_irq(IRQ_RTC, dev);
}
--
1.5.6
--
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