Browse Source

gpio: samsung: fixes build warning with s3c2410_defconfig

commit 7b45ed96 ("ARM: S3C24XX: handle s3c2412 eints using new
infrastructure") introduced build warning and this patch fixes
that:

drivers/gpio/gpio-samsung.c: In function 's3c24xx_gpiolib_fbank_to_irq':
drivers/gpio/gpio-samsung.c:1126:5: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Cc: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Kukjin Kim 12 years ago
parent
commit
d97fedef91
1 changed files with 2 additions and 1 deletions
  1. 2 1
      drivers/gpio/gpio-samsung.c

+ 2 - 1
drivers/gpio/gpio-samsung.c

@@ -1122,11 +1122,12 @@ int samsung_gpiolib_to_irq(struct gpio_chip *chip, unsigned int offset)
 #ifdef CONFIG_PLAT_S3C24XX
 static int s3c24xx_gpiolib_fbank_to_irq(struct gpio_chip *chip, unsigned offset)
 {
-	if (offset < 4)
+	if (offset < 4) {
 		if (soc_is_s3c2412())
 			return IRQ_EINT0_2412 + offset;
 		else
 			return IRQ_EINT0 + offset;
+	}
 
 	if (offset < 8)
 		return IRQ_EINT4 + offset - 4;