Re: [PATCH] MIPS: AR7: Fix GCC 4.6.0 build error.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 13, 2011 at 04:50:30PM +0100, Alexander Clouter wrote:

> > >+	struct ar7_gpio_chip *gpch = (!ar7_is_titan())
> > 
> >    Parens around (!x) are not really necessary. Perhaps Ralf could
> > remove them while applying...
> > 
> I'm happy to resubmit if that is preferred.

Florian who is experiencing email problems submitted an alternative patch
to me which I'm appending below and which I've just applied.

Thanks folks!

  Ralf

From: Florian Fainelli <florian@xxxxxxxxxxx>
Date: Fri, 13 May 2011 17:41:21 +0200
Subject: [PATCH] MIPS: AR7: Fix GPIO register size for Titan variant.

The 'size' variable contains the correct register size for both AR7
and Titan, but we never used it to ioremap the correct register size.
This problem only shows up on Titan.

Reported-by: Alexander Clouter <alex@xxxxxxxxxxxxx>
Signed-off-by: Florian Fainelli <florian@xxxxxxxxxxx>
Signed-off-by: Ralf Baechle <ralf@xxxxxxxxxxxxxx>
---
 arch/mips/ar7/gpio.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/mips/ar7/gpio.c b/arch/mips/ar7/gpio.c
index 425dfa5..a8aa1b4 100644
--- a/arch/mips/ar7/gpio.c
+++ b/arch/mips/ar7/gpio.c
@@ -326,7 +326,7 @@ int __init ar7_gpio_init(void)
 	}
 
 	gpch->regs = ioremap_nocache(AR7_REGS_GPIO,
-					AR7_REGS_GPIO + 0x10);
+					AR7_REGS_GPIO + size);
 
 	if (!gpch->regs) {
 		printk(KERN_ERR "%s: failed to ioremap regs\n",



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux