From fbe92fcc7570eaba4bd5786cb1bbc5e693dba6bd Mon Sep 17 00:00:00 2001 From: Mark Brown Date: Tue, 18 Oct 2011 08:46:50 +0900 Subject: gpio/samsung: Complain loudly if we don't know the SoC If we don't know the SoC type then we won't add any chips which is rather unfortunate as neither GPIO nor pinmux APIs will work, breaking lots of different subsystems. Logging at least provides a hint to the user as to what's gone wrong. Signed-off-by: Mark Brown Signed-off-by: Kukjin Kim --- drivers/gpio/gpio-samsung.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers/gpio') diff --git a/drivers/gpio/gpio-samsung.c b/drivers/gpio/gpio-samsung.c index 479edc3b8ea3..866251852719 100644 --- a/drivers/gpio/gpio-samsung.c +++ b/drivers/gpio/gpio-samsung.c @@ -2486,6 +2486,9 @@ static __init int samsung_gpiolib_init(void) s5p_register_gpioint_bank(IRQ_GPIO_XA, 0, IRQ_GPIO1_NR_GROUPS); s5p_register_gpioint_bank(IRQ_GPIO_XB, IRQ_GPIO1_NR_GROUPS, IRQ_GPIO2_NR_GROUPS); #endif + } else { + WARN(1, "Unknown SoC in gpio-samsung, no GPIOs added\n"); + return -ENODEV; } return 0; -- cgit v1.2.1