aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpio/gpio-sch311x.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpio/gpio-sch311x.c')
-rw-r--r--drivers/gpio/gpio-sch311x.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpio/gpio-sch311x.c b/drivers/gpio/gpio-sch311x.c
index f942b80ee403..0cb11413e814 100644
--- a/drivers/gpio/gpio-sch311x.c
+++ b/drivers/gpio/gpio-sch311x.c
@@ -291,14 +291,12 @@ static int sch311x_gpio_remove(struct platform_device *pdev)
291{ 291{
292 struct sch311x_pdev_data *pdata = pdev->dev.platform_data; 292 struct sch311x_pdev_data *pdata = pdev->dev.platform_data;
293 struct sch311x_gpio_priv *priv = platform_get_drvdata(pdev); 293 struct sch311x_gpio_priv *priv = platform_get_drvdata(pdev);
294 int err, i; 294 int i;
295 295
296 release_region(pdata->runtime_reg + GP1, 6); 296 release_region(pdata->runtime_reg + GP1, 6);
297 297
298 for (i = 0; i < ARRAY_SIZE(priv->blocks); i++) { 298 for (i = 0; i < ARRAY_SIZE(priv->blocks); i++) {
299 err = gpiochip_remove(&priv->blocks[i].chip); 299 gpiochip_remove(&priv->blocks[i].chip);
300 if (err)
301 return err;
302 dev_info(&pdev->dev, 300 dev_info(&pdev->dev,
303 "SMSC SCH311x GPIO block %d unregistered.\n", i); 301 "SMSC SCH311x GPIO block %d unregistered.\n", i);
304 } 302 }