pinctrl: abx500: suppress unused mutex
PATCH 1/1 pinctrl: abx500: suppress unused mutex
From: Patrice Chotard <[email protected]>
Suppress a mutex which was initialized on probe
and destroyed on remove but never used.
Signed-off-by Patrice Chotard <[email protected]>
--- drivers/pinctrl/pinctrl-abx500.c | 9 --------- 1 file changed, 9 deletions(-)
drivers/pinctrl/pinctrl-abx500.c +0 -9
@@ -99,7 +99,6 @@ struct abx500_pinctrl {struct abx500_pinctrl_soc_data *soc;struct gpio_chip chip;struct ab8500 *parent; -struct mutex lock;struct abx500_gpio_irq_cluster *irq_cluster;int irq_cluster_size; };
@@ -882,8 +881,6 @@ static int abx500_gpio_probe(struct platform_device *pdev) pct->chip.dev = &pdev->dev; pct->chip.base = (np) ?-1 : pdata->gpio_base; -/* initialize the lock */ -mutex_init (&pct->lock);/* Poke in other ASIC variants here */ switch (id) {
@@ -902,13 +899,11 @@ static int abx500_gpio_probe(struct platform_device *pdev)default :dev_err (&pdev->dev,"Unsupported pinctrl sub driver (%d)\n" , (int ) platid->driver_data); -mutex_destroy (&pct->lock);return -EINVAL ; }if (!pct->soc) {dev_err (&pdev->dev,"Invalid SOC data\n" ); -mutex_destroy (&pct->lock);return -EINVAL ; }
@@ -919,7 +914,6 @@ static int abx500_gpio_probe(struct platform_device *pdev) ret =gpiochip_add (&pct->chip);if (ret) {dev_err (&pdev->dev,"unable to add gpiochip: %d\n" , ret); -mutex_destroy (&pct->lock);return ret; }dev_info (&pdev->dev,"added gpiochip\n" );
@@ -956,7 +950,6 @@ out_rem_chip:if (err)dev_info (&pdev->dev,"failed to remove gpiochip\n" ); -mutex_destroy (&pct->lock);return ret; }
@@ -976,8 +969,6 @@ static int abx500_gpio_remove(struct platform_device *pdev)return ret; } -mutex_destroy (&pct->lock); -return 0 ; }
Signature · 1 line
1.7.10
Quoted 9 lines · On Thu, 23 May 2013, [email protected] wrote:
From: Patrice Chotard <[email protected]>
Suppress a mutex which was initialized on probe
and destroyed on remove but never used.Signed-off-by Patrice Chotard <[email protected]>--- drivers/pinctrl/pinctrl-abx500.c | 9 --------- 1 file changed, 9 deletions(-)
Acked-by Lee Jones <[email protected]>
Signature · 4 lines
Lee Jones Linaro ST-Ericsson Landing Team Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog