Linux MIPS Architecture development
 help / color / mirror / Atom feed
* [PATCH][MIPS] fix au1xxx_gpio_direction_* return value
@ 2007-08-02  3:48 Yoichi Yuasa
  2007-08-02  8:05 ` Florian Fainelli
  2007-08-02  9:21 ` Ralf Baechle
  0 siblings, 2 replies; 3+ messages in thread
From: Yoichi Yuasa @ 2007-08-02  3:48 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: yoichi_yuasa, linux-mips

Fix au1xxx_gpio_direction_* return value.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>

diff -pruN -X mips/Documentation/dontdiff mips-orig/arch/mips/au1000/common/gpio.c mips/arch/mips/au1000/common/gpio.c
--- mips-orig/arch/mips/au1000/common/gpio.c	2007-08-02 10:49:14.849705000 +0900
+++ mips/arch/mips/au1000/common/gpio.c	2007-08-02 10:49:35.158974250 +0900
@@ -131,12 +131,12 @@ int au1xxx_gpio_direction_input(unsigned
 {
 	if (gpio >= AU1XXX_GPIO_BASE)
 #if defined(CONFIG_SOC_AU1000)
-		;
+		return -ENODEV;
 #else
 		return au1xxx_gpio2_direction_input(gpio);
 #endif
-	else
-		return au1xxx_gpio1_direction_input(gpio);
+
+	return au1xxx_gpio1_direction_input(gpio);
 }
 
 EXPORT_SYMBOL(au1xxx_gpio_direction_input);
@@ -145,12 +145,12 @@ int au1xxx_gpio_direction_output(unsigne
 {
 	if (gpio >= AU1XXX_GPIO_BASE)
 #if defined(CONFIG_SOC_AU1000)
-		;
+		return -ENODEV;
 #else
 		return au1xxx_gpio2_direction_output(gpio, value);
 #endif
-	else
-		return au1xxx_gpio1_direction_output(gpio, value);
+
+	return au1xxx_gpio1_direction_output(gpio, value);
 }
 
 EXPORT_SYMBOL(au1xxx_gpio_direction_output);

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

end of thread, other threads:[~2007-08-02  9:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-02  3:48 [PATCH][MIPS] fix au1xxx_gpio_direction_* return value Yoichi Yuasa
2007-08-02  8:05 ` Florian Fainelli
2007-08-02  9:21 ` Ralf Baechle

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