Skip to content

Commit

Permalink
leds: leds-gpio: Let device core handle pinctrl
Browse files Browse the repository at this point in the history
Since commit ab78029 (drivers/pinctrl: grab default handles from device core)
we can rely on device core for handling pinctrl, so remove
devm_pinctrl_get_select_default() from the driver.

Reported-by: Stephen Warren <warren@wwwdotorg.org>
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Bryan Wu <cooloney@gmail.com>
  • Loading branch information
Fabio Estevam authored and Bryan Wu committed Jun 20, 2013
1 parent 28720cf commit bfa855b
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions drivers/leds/leds-gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include <linux/slab.h>
#include <linux/workqueue.h>
#include <linux/module.h>
#include <linux/pinctrl/consumer.h>
#include <linux/err.h>

struct gpio_led_data {
Expand Down Expand Up @@ -236,13 +235,8 @@ static int gpio_led_probe(struct platform_device *pdev)
{
struct gpio_led_platform_data *pdata = pdev->dev.platform_data;
struct gpio_leds_priv *priv;
struct pinctrl *pinctrl;
int i, ret = 0;

pinctrl = devm_pinctrl_get_select_default(&pdev->dev);
if (IS_ERR(pinctrl))
dev_warn(&pdev->dev,
"pins are not configured from the driver\n");

if (pdata && pdata->num_leds) {
priv = devm_kzalloc(&pdev->dev,
Expand Down

0 comments on commit bfa855b

Please sign in to comment.