* [PATCH] rtc-twl: Switch to using threaded irq
@ 2011-03-16 16:07 Ilkka Koskinen
2011-04-13 7:41 ` Krishnamoorthy, Balaji T
0 siblings, 1 reply; 8+ messages in thread
From: Ilkka Koskinen @ 2011-03-16 16:07 UTC (permalink / raw)
To: a.zummo, tony; +Cc: rtc-linux, balajitk, linux-omap
The driver is accessing to i2c bus in interrupt handler.
Therefore, it should use threaded irq.
Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
---
drivers/rtc/rtc-twl.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
index ed1b868..2715b96 100644
--- a/drivers/rtc/rtc-twl.c
+++ b/drivers/rtc/rtc-twl.c
@@ -475,7 +475,7 @@ static int __devinit twl_rtc_probe(struct platform_device *pdev)
if (ret < 0)
goto out1;
- ret = request_irq(irq, twl_rtc_interrupt,
+ ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
IRQF_TRIGGER_RISING,
dev_name(&rtc->dev), rtc);
if (ret < 0) {
--
1.7.0.4
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] rtc-twl: Switch to using threaded irq
2011-03-16 16:07 [PATCH] rtc-twl: Switch to using threaded irq Ilkka Koskinen
@ 2011-04-13 7:41 ` Krishnamoorthy, Balaji T
2011-05-05 7:51 ` ilkka.koskinen
0 siblings, 1 reply; 8+ messages in thread
From: Krishnamoorthy, Balaji T @ 2011-04-13 7:41 UTC (permalink / raw)
To: Ilkka Koskinen; +Cc: a.zummo, tony, rtc-linux, linux-omap
On Wed, Mar 16, 2011 at 9:37 PM, Ilkka Koskinen
<ilkka.koskinen@nokia.com> wrote:
>
> The driver is accessing to i2c bus in interrupt handler.
> Therefore, it should use threaded irq.
Acked-by: Balaji T K <balajitk@ti.com>
>
> Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
> ---
> drivers/rtc/rtc-twl.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
> index ed1b868..2715b96 100644
> --- a/drivers/rtc/rtc-twl.c
> +++ b/drivers/rtc/rtc-twl.c
> @@ -475,7 +475,7 @@ static int __devinit twl_rtc_probe(struct platform_device *pdev)
> if (ret < 0)
> goto out1;
>
> - ret = request_irq(irq, twl_rtc_interrupt,
> + ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
> IRQF_TRIGGER_RISING,
> dev_name(&rtc->dev), rtc);
> if (ret < 0) {
> --
> 1.7.0.4
>
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: [PATCH] rtc-twl: Switch to using threaded irq
2011-04-13 7:41 ` Krishnamoorthy, Balaji T
@ 2011-05-05 7:51 ` ilkka.koskinen
2011-05-12 23:24 ` John Stultz
0 siblings, 1 reply; 8+ messages in thread
From: ilkka.koskinen @ 2011-05-05 7:51 UTC (permalink / raw)
To: tony, john.stultz; +Cc: a.zummo, rtc-linux, linux-omap, balajitk, ilkkakos
Hi,
Tony and John: What would be the appropriate path for this patch?
Cheers, Ilkka
On Apr 13, 2011 Krishnamoorthy, Balaji T wrote:
>On Wed, Mar 16, 2011 at 9:37 PM, Ilkka Koskinen
<ilkka.koskinen@nokia.com> wrote:
>>
>> The driver is accessing to i2c bus in interrupt handler.
>> Therefore, it should use threaded irq.
>Acked-by: Balaji T K <balajitk@ti.com>
>>
>> Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
>> ---
>> drivers/rtc/rtc-twl.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
>> index ed1b868..2715b96 100644
>> --- a/drivers/rtc/rtc-twl.c
>> +++ b/drivers/rtc/rtc-twl.c
>> @@ -475,7 +475,7 @@ static int __devinit twl_rtc_probe(struct platform_device *pdev)
>> if (ret < 0)
>> goto out1;
>>
>> - ret = request_irq(irq, twl_rtc_interrupt,
>> + ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
>> IRQF_TRIGGER_RISING,
>> dev_name(&rtc->dev), rtc);
>> if (ret < 0) {
>> --
>> 1.7.0.4
>>
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: [PATCH] rtc-twl: Switch to using threaded irq
2011-05-05 7:51 ` ilkka.koskinen
@ 2011-05-12 23:24 ` John Stultz
2011-05-18 19:20 ` Ilkka Koskinen
0 siblings, 1 reply; 8+ messages in thread
From: John Stultz @ 2011-05-12 23:24 UTC (permalink / raw)
To: ilkka.koskinen; +Cc: tony, a.zummo, rtc-linux, linux-omap, balajitk, ilkkakos
On Thu, 2011-05-05 at 07:51 +0000, ilkka.koskinen@nokia.com wrote:
> Hi,
>
> Tony and John: What would be the appropriate path for this patch?
I'd probably push it through omap maintainer path, as its hardware
specific and can be better tested there.
thanks
-john
> On Apr 13, 2011 Krishnamoorthy, Balaji T wrote:
> >On Wed, Mar 16, 2011 at 9:37 PM, Ilkka Koskinen
> <ilkka.koskinen@nokia.com> wrote:
> >>
> >> The driver is accessing to i2c bus in interrupt handler.
> >> Therefore, it should use threaded irq.
>
> >Acked-by: Balaji T K <balajitk@ti.com>
>
> >>
> >> Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
> >> ---
> >> drivers/rtc/rtc-twl.c | 2 +-
> >> 1 files changed, 1 insertions(+), 1 deletions(-)
> >>
> >> diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
> >> index ed1b868..2715b96 100644
> >> --- a/drivers/rtc/rtc-twl.c
> >> +++ b/drivers/rtc/rtc-twl.c
> >> @@ -475,7 +475,7 @@ static int __devinit twl_rtc_probe(struct platform_device *pdev)
> >> if (ret < 0)
> >> goto out1;
> >>
> >> - ret = request_irq(irq, twl_rtc_interrupt,
> >> + ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
> >> IRQF_TRIGGER_RISING,
> >> dev_name(&rtc->dev), rtc);
> >> if (ret < 0) {
> >> --
> >> 1.7.0.4
> >>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] rtc-twl: Switch to using threaded irq
2011-05-12 23:24 ` John Stultz
@ 2011-05-18 19:20 ` Ilkka Koskinen
2011-05-31 8:51 ` Sebastian Reichel
0 siblings, 1 reply; 8+ messages in thread
From: Ilkka Koskinen @ 2011-05-18 19:20 UTC (permalink / raw)
To: tony; +Cc: John Stultz, a.zummo, rtc-linux, linux-omap, balajitk
Hi,
Tony, would you mind taking the patch in your tree?
Btw, the nokia address doesn't work anymore, but
should probably still remain in s-o-b...
Cheers, Ilkka
13.5.2011 2:24, John Stultz kirjoitti:
> On Thu, 2011-05-05 at 07:51 +0000, ilkka.koskinen@nokia.com wrote:
>> Hi,
>>
>> Tony and John: What would be the appropriate path for this patch?
>
> I'd probably push it through omap maintainer path, as its hardware
> specific and can be better tested there.
>
> thanks
> -john
>
>
>> On Apr 13, 2011 Krishnamoorthy, Balaji T wrote:
>>> On Wed, Mar 16, 2011 at 9:37 PM, Ilkka Koskinen
>> <ilkka.koskinen@nokia.com> wrote:
>>>>
>>>> The driver is accessing to i2c bus in interrupt handler.
>>>> Therefore, it should use threaded irq.
>>
>>> Acked-by: Balaji T K <balajitk@ti.com>
>>
>>>>
>>>> Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
>>>> ---
>>>> drivers/rtc/rtc-twl.c | 2 +-
>>>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>>>
>>>> diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
>>>> index ed1b868..2715b96 100644
>>>> --- a/drivers/rtc/rtc-twl.c
>>>> +++ b/drivers/rtc/rtc-twl.c
>>>> @@ -475,7 +475,7 @@ static int __devinit twl_rtc_probe(struct platform_device *pdev)
>>>> if (ret < 0)
>>>> goto out1;
>>>>
>>>> - ret = request_irq(irq, twl_rtc_interrupt,
>>>> + ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
>>>> IRQF_TRIGGER_RISING,
>>>> dev_name(&rtc->dev), rtc);
>>>> if (ret < 0) {
>>>> --
>>>> 1.7.0.4
>>>>
>
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] rtc-twl: Switch to using threaded irq
2011-05-18 19:20 ` Ilkka Koskinen
@ 2011-05-31 8:51 ` Sebastian Reichel
2011-06-27 16:45 ` Sebastian Reichel
0 siblings, 1 reply; 8+ messages in thread
From: Sebastian Reichel @ 2011-05-31 8:51 UTC (permalink / raw)
To: linux-omap
Cc: tony, John Stultz, a.zummo, rtc-linux, balajitk, Ilkka Koskinen
[-- Attachment #1.1: Type: text/plain, Size: 1375 bytes --]
Hi,
I think the patch should also remove the local_irq_enable() call in
twl_rtc_interrupt, since it's no longer needed with threaded irq. At
least on the Pandaboard the RTC is still working with the appended
patch.
-- Sebastian
> >> On Apr 13, 2011 Krishnamoorthy, Balaji T wrote:
> >>> On Wed, Mar 16, 2011 at 9:37 PM, Ilkka Koskinen
> >> <ilkka.koskinen@nokia.com> wrote:
> >>>>
> >>>> The driver is accessing to i2c bus in interrupt handler.
> >>>> Therefore, it should use threaded irq.
> >>
> >>> Acked-by: Balaji T K <balajitk@ti.com>
> >>
> >>>>
> >>>> Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
> >>>> ---
> >>>> drivers/rtc/rtc-twl.c | 2 +-
> >>>> 1 files changed, 1 insertions(+), 1 deletions(-)
> >>>>
> >>>> diff --git a/drivers/rtc/rtc-twl.c b/drivers/rtc/rtc-twl.c
> >>>> index ed1b868..2715b96 100644
> >>>> --- a/drivers/rtc/rtc-twl.c
> >>>> +++ b/drivers/rtc/rtc-twl.c
> >>>> @@ -475,7 +475,7 @@ static int __devinit twl_rtc_probe(struct platform_device *pdev)
> >>>> if (ret < 0)
> >>>> goto out1;
> >>>>
> >>>> - ret = request_irq(irq, twl_rtc_interrupt,
> >>>> + ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
> >>>> IRQF_TRIGGER_RISING,
> >>>> dev_name(&rtc->dev), rtc);
> >>>> if (ret < 0) {
> >>>> --
> >>>> 1.7.0.4
[-- Attachment #1.2: fix-twl-rtc.patch --]
[-- Type: text/x-diff, Size: 908 bytes --]
--- a/drivers/rtc/rtc-twl.c 2011-05-19 06:06:34.000000000 +0200
+++ b/drivers/rtc/rtc-twl.c 2011-05-26 20:34:03.000000000 +0200
@@ -362,14 +362,6 @@
int res;
u8 rd_reg;
-#ifdef CONFIG_LOCKDEP
- /* WORKAROUND for lockdep forcing IRQF_DISABLED on us, which
- * we don't want and can't tolerate. Although it might be
- * friendlier not to borrow this thread context...
- */
- local_irq_enable();
-#endif
-
res = twl_rtc_read_u8(&rd_reg, REG_RTC_STATUS_REG);
if (res)
goto out;
@@ -462,7 +454,7 @@
if (ret < 0)
goto out1;
- ret = request_irq(irq, twl_rtc_interrupt,
+ ret = request_threaded_irq(irq, NULL, twl_rtc_interrupt,
IRQF_TRIGGER_RISING,
dev_name(&rtc->dev), rtc);
if (ret < 0) {
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] rtc-twl: Switch to using threaded irq
2011-05-31 8:51 ` Sebastian Reichel
@ 2011-06-27 16:45 ` Sebastian Reichel
2011-08-10 22:44 ` John Stultz
0 siblings, 1 reply; 8+ messages in thread
From: Sebastian Reichel @ 2011-06-27 16:45 UTC (permalink / raw)
To: linux-omap
Cc: tony, John Stultz, a.zummo, rtc-linux, balajitk, Ilkka Koskinen
[-- Attachment #1: Type: text/plain, Size: 531 bytes --]
On Tue, May 31, 2011 at 10:51:39AM +0200, Sebastian Reichel wrote:
> > The driver is accessing to i2c bus in interrupt handler.
> > Therefore, it should use threaded irq.
> I think the patch should also remove the local_irq_enable() call in
> twl_rtc_interrupt, since it's no longer needed with threaded irq. At
> least on the Pandaboard the RTC is still working with the appended
> patch.
ping.
Currently the kernel prints a stacktrace for each rtc-twl interrupt,
because its interrupt handler enables interrupts.
-- Sebastian
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] rtc-twl: Switch to using threaded irq
2011-06-27 16:45 ` Sebastian Reichel
@ 2011-08-10 22:44 ` John Stultz
0 siblings, 0 replies; 8+ messages in thread
From: John Stultz @ 2011-08-10 22:44 UTC (permalink / raw)
To: Sebastian Reichel
Cc: linux-omap, tony, a.zummo, rtc-linux, balajitk, Ilkka Koskinen
On Mon, 2011-06-27 at 18:45 +0200, Sebastian Reichel wrote:
> On Tue, May 31, 2011 at 10:51:39AM +0200, Sebastian Reichel wrote:
> > > The driver is accessing to i2c bus in interrupt handler.
> > > Therefore, it should use threaded irq.
> > I think the patch should also remove the local_irq_enable() call in
> > twl_rtc_interrupt, since it's no longer needed with threaded irq. At
> > least on the Pandaboard the RTC is still working with the appended
> > patch.
>
> ping.
>
> Currently the kernel prints a stacktrace for each rtc-twl interrupt,
> because its interrupt handler enables interrupts.
I've queued both changes. Thanks for the reminder.
thanks
-john
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2011-08-10 22:44 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-16 16:07 [PATCH] rtc-twl: Switch to using threaded irq Ilkka Koskinen
2011-04-13 7:41 ` Krishnamoorthy, Balaji T
2011-05-05 7:51 ` ilkka.koskinen
2011-05-12 23:24 ` John Stultz
2011-05-18 19:20 ` Ilkka Koskinen
2011-05-31 8:51 ` Sebastian Reichel
2011-06-27 16:45 ` Sebastian Reichel
2011-08-10 22:44 ` John Stultz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).