Commit e0f2c271 authored by Hiroshi DOYU's avatar Hiroshi DOYU Committed by Tony Lindgren

ARM: OMAP: Fix inconsistency of completion in retu-rtc

There was the case that multiple users can wait for completion.
Signed-off-by: default avatarHiroshi DOYU <Hiroshi.DOYU@nokia.com>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent aac9300d
...@@ -328,7 +328,7 @@ DECLARE_WORK(retu_rtca_work, retu_rtca_expired); ...@@ -328,7 +328,7 @@ DECLARE_WORK(retu_rtca_work, retu_rtca_expired);
static void retu_rtcs_interrupt(unsigned long unused) static void retu_rtcs_interrupt(unsigned long unused)
{ {
retu_ack_irq(RETU_INT_RTCS); retu_ack_irq(RETU_INT_RTCS);
complete(&retu_rtc_sync); complete_all(&retu_rtc_sync);
} }
static void retu_rtca_interrupt(unsigned long unused) static void retu_rtca_interrupt(unsigned long unused)
...@@ -435,7 +435,7 @@ static struct platform_device retu_rtc_device = { ...@@ -435,7 +435,7 @@ static struct platform_device retu_rtc_device = {
/* This function provides syncronization with the RTCS interrupt handler */ /* This function provides syncronization with the RTCS interrupt handler */
static void retu_rtc_barrier(void) static void retu_rtc_barrier(void)
{ {
init_completion(&retu_rtc_sync); INIT_COMPLETION(retu_rtc_sync);
retu_ack_irq(RETU_INT_RTCS); retu_ack_irq(RETU_INT_RTCS);
retu_enable_irq(RETU_INT_RTCS); retu_enable_irq(RETU_INT_RTCS);
wait_for_completion(&retu_rtc_sync); wait_for_completion(&retu_rtc_sync);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment