[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200904231245.33435.david-b@pacbell.net>
Date: Thu, 23 Apr 2009 12:45:32 -0700
From: David Brownell <david-b@...bell.net>
To: Alessandro Zummo <alessandro.zummo@...ertech.it>
Cc: rtc-linux@...glegroups.com, Atsushi Nemoto <anemo@....ocn.ne.jp>,
akpm@...ux-foundation.org, linux-kernel@...r.kernel.org,
hcegtvedt@...el.com, vapier@...too.org, rongkai.zhan@...driver.com,
balajirrao@...nmoko.org, broonie@...nsource.wolfsonmicro.com
Subject: Re: [rtc-linux] Re: [PATCH] rtc: Make rtc_update_irq callable with irqs enabled
On Thursday 23 April 2009, Alessandro Zummo wrote:
>
> > If you're talking about a different patch, please forward...
>
> no patch, just theory.
>
> the question is, do we need IRQs disabled when
> calling rtc_update_irq?
If the spinlock is *ever* acquired with IRQs disabled,
it must *always* be acquired that way.
The typical use is ... from IRQ context, which will in
some cases mean IRQs disabled. QED.
> and if yes, why? to prevent what?
Consider: one context grabs spinlock with IRQs enabled.
IRQ arrives. That context tries to grab that same lock,
from the same CPU. ==> Self-deadlock.
--
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