Skip to content

Commit

Permalink
drivers/rtc/rtc-twl.c: simplify RTC interrupt clearing
Browse files Browse the repository at this point in the history
For clearing RTC interrupt, programming ALARM bit only is sufficient, as
all other bits are any way not affected by writing 0 to them.

Hence removed unwanted OR operation.

Signed-off-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Venu Byravarasu authored and Linus Torvalds committed Mar 23, 2012
1 parent f7439bc commit 94a339d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/rtc/rtc-twl.c
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@ static irqreturn_t twl_rtc_interrupt(int irq, void *rtc)
else
events |= RTC_IRQF | RTC_UF;

res = twl_rtc_write_u8(rd_reg | BIT_RTC_STATUS_REG_ALARM_M,
res = twl_rtc_write_u8(BIT_RTC_STATUS_REG_ALARM_M,
REG_RTC_STATUS_REG);
if (res)
goto out;
Expand Down

0 comments on commit 94a339d

Please sign in to comment.