public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic
@ 2009-04-02 14:20 Roger Quadros
  2009-04-02 16:25 ` Tony Lindgren
  2009-04-03 23:49 ` [APPLIED] > " Tony Lindgren
  0 siblings, 2 replies; 4+ messages in thread
From: Roger Quadros @ 2009-04-02 14:20 UTC (permalink / raw)
  To: tony; +Cc: linux-omap, Artem Bityutskiy

From: Roger Quadros <ext-roger.quadros@nokia.com>
Date: Thu, 2 Apr 2009 16:41:00 +0300
Subject: [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic

SPURIOUSIRQ is contained in bits 31:7 of INTC_SIR, so
INTC_SIR must be right shifted by 7, not 6.

No change in logic, only changes for better readability.
Refer to register definition of INTCPS_SIR_IRQ in OMAP3 Manual.

Signed-off-by: Roger Quadros <ext-roger.quadros@nokia.com>
---
 arch/arm/mach-omap2/irq.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
index 2842fe8..296ab86 100644
--- a/arch/arm/mach-omap2/irq.c
+++ b/arch/arm/mach-omap2/irq.c
@@ -73,9 +73,9 @@ static int omap_check_spurious(unsigned int irq)
 	u32 sir, spurious;
 
 	sir = intc_bank_read_reg(&irq_banks[0], INTC_SIR);
-	spurious = sir >> 6;
+	spurious = sir >> 7;
 
-	if (spurious > 1) {
+	if (spurious) {
 		printk(KERN_WARNING "Spurious irq %i: 0x%08x, please flush "
 					"posted write for irq %i\n",
 					irq, sir, previous_irq);
-- 
1.5.6.5



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic
  2009-04-02 14:20 [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic Roger Quadros
@ 2009-04-02 16:25 ` Tony Lindgren
  2009-04-03  6:18   ` Roger Quadros
  2009-04-03 23:49 ` [APPLIED] > " Tony Lindgren
  1 sibling, 1 reply; 4+ messages in thread
From: Tony Lindgren @ 2009-04-02 16:25 UTC (permalink / raw)
  To: Roger Quadros; +Cc: linux-omap, Artem Bityutskiy

* Roger Quadros <ext-roger.quadros@nokia.com> [090402 07:21]:
> From: Roger Quadros <ext-roger.quadros@nokia.com>
> Date: Thu, 2 Apr 2009 16:41:00 +0300
> Subject: [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic
>
> SPURIOUSIRQ is contained in bits 31:7 of INTC_SIR, so
> INTC_SIR must be right shifted by 7, not 6.
>
> No change in logic, only changes for better readability.
> Refer to register definition of INTCPS_SIR_IRQ in OMAP3 Manual.

Argh, that bug explains why I could not figure out the meaning
of the first spurious bit.. :)

I guess the spurious bit value is still on or off instead of
actually telling the previous spurious irq number though.

Tony

> Signed-off-by: Roger Quadros <ext-roger.quadros@nokia.com>
> ---
> arch/arm/mach-omap2/irq.c |    4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
> index 2842fe8..296ab86 100644
> --- a/arch/arm/mach-omap2/irq.c
> +++ b/arch/arm/mach-omap2/irq.c
> @@ -73,9 +73,9 @@ static int omap_check_spurious(unsigned int irq)
> 	u32 sir, spurious;
>
> 	sir = intc_bank_read_reg(&irq_banks[0], INTC_SIR);
> -	spurious = sir >> 6;
> +	spurious = sir >> 7;
>
> -	if (spurious > 1) {
> +	if (spurious) {
> 		printk(KERN_WARNING "Spurious irq %i: 0x%08x, please flush "
> 					"posted write for irq %i\n",
> 					irq, sir, previous_irq);
> -- 
> 1.5.6.5
>
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic
  2009-04-02 16:25 ` Tony Lindgren
@ 2009-04-03  6:18   ` Roger Quadros
  0 siblings, 0 replies; 4+ messages in thread
From: Roger Quadros @ 2009-04-03  6:18 UTC (permalink / raw)
  To: ext Tony Lindgren; +Cc: linux-omap, Artem Bityutskiy

ext Tony Lindgren wrote:
> * Roger Quadros <ext-roger.quadros@nokia.com> [090402 07:21]:
>   
>> From: Roger Quadros <ext-roger.quadros@nokia.com>
>> Date: Thu, 2 Apr 2009 16:41:00 +0300
>> Subject: [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic
>>
>> SPURIOUSIRQ is contained in bits 31:7 of INTC_SIR, so
>> INTC_SIR must be right shifted by 7, not 6.
>>
>> No change in logic, only changes for better readability.
>> Refer to register definition of INTCPS_SIR_IRQ in OMAP3 Manual.
>>     
>
> Argh, that bug explains why I could not figure out the meaning
> of the first spurious bit.. :)
>
> I guess the spurious bit value is still on or off instead of
> actually telling the previous spurious irq number though.
>
> Tony
>
>   
Yes Tony you are right.

-roger

>> Signed-off-by: Roger Quadros <ext-roger.quadros@nokia.com>
>> ---
>> arch/arm/mach-omap2/irq.c |    4 ++--
>> 1 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
>> index 2842fe8..296ab86 100644
>> --- a/arch/arm/mach-omap2/irq.c
>> +++ b/arch/arm/mach-omap2/irq.c
>> @@ -73,9 +73,9 @@ static int omap_check_spurious(unsigned int irq)
>> 	u32 sir, spurious;
>>
>> 	sir = intc_bank_read_reg(&irq_banks[0], INTC_SIR);
>> -	spurious = sir >> 6;
>> +	spurious = sir >> 7;
>>
>> -	if (spurious > 1) {
>> +	if (spurious) {
>> 		printk(KERN_WARNING "Spurious irq %i: 0x%08x, please flush "
>> 					"posted write for irq %i\n",
>> 					irq, sir, previous_irq);
>> -- 
>> 1.5.6.5
>>
>>
>>     
>
>   


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [APPLIED] > [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic
  2009-04-02 14:20 [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic Roger Quadros
  2009-04-02 16:25 ` Tony Lindgren
@ 2009-04-03 23:49 ` Tony Lindgren
  1 sibling, 0 replies; 4+ messages in thread
From: Tony Lindgren @ 2009-04-03 23:49 UTC (permalink / raw)
  To: linux-omap

This patch has been applied to the linux-omap
by youw fwiendly patch wobot.

Commit: 7d7137897a95e8bf74f54c0df672ad481b216097

PatchWorks
http://patchwork.kernel.org/patch/15920/

Git
http://git.kernel.org/?p=linux/kernel/git/tmlind/linux-omap-2.6.git;a=commit;h=7d7137897a95e8bf74f54c0df672ad481b216097



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-04-03 23:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-02 14:20 [PATCH] ARM: OMAP3: Clean up spurious interrupt check logic Roger Quadros
2009-04-02 16:25 ` Tony Lindgren
2009-04-03  6:18   ` Roger Quadros
2009-04-03 23:49 ` [APPLIED] > " Tony Lindgren

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox