* [PATCH] gpio: samsung: fixes build warning with s3c2410_defconfig
@ 2013-02-13 5:05 Kukjin Kim
2013-02-13 8:27 ` Heiko Stübner
0 siblings, 1 reply; 2+ messages in thread
From: Kukjin Kim @ 2013-02-13 5:05 UTC (permalink / raw)
To: linux-samsung-soc; +Cc: Kukjin Kim, Heiko Stuebner
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>
---
drivers/gpio/gpio-samsung.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpio/gpio-samsung.c b/drivers/gpio/gpio-samsung.c
index df096dc..a811d0f 100644
--- a/drivers/gpio/gpio-samsung.c
+++ b/drivers/gpio/gpio-samsung.c
@@ -1123,11 +1123,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;
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] gpio: samsung: fixes build warning with s3c2410_defconfig
2013-02-13 5:05 [PATCH] gpio: samsung: fixes build warning with s3c2410_defconfig Kukjin Kim
@ 2013-02-13 8:27 ` Heiko Stübner
0 siblings, 0 replies; 2+ messages in thread
From: Heiko Stübner @ 2013-02-13 8:27 UTC (permalink / raw)
To: Kukjin Kim; +Cc: linux-samsung-soc
Am Mittwoch, 13. Februar 2013, 06:05:36 schrieb Kukjin Kim:
> 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>
right ... this way it's definitly better
Acked-by: Heiko Stuebner <heiko@sntech.de>
> ---
> drivers/gpio/gpio-samsung.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpio/gpio-samsung.c b/drivers/gpio/gpio-samsung.c
> index df096dc..a811d0f 100644
> --- a/drivers/gpio/gpio-samsung.c
> +++ b/drivers/gpio/gpio-samsung.c
> @@ -1123,11 +1123,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;
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-02-13 8:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-13 5:05 [PATCH] gpio: samsung: fixes build warning with s3c2410_defconfig Kukjin Kim
2013-02-13 8:27 ` Heiko Stübner
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.