Messages in this thread | | | Date | Wed, 20 May 2015 10:33:18 +0900 | From | Chanwoo Choi <> | Subject | Re: [PATCH v2] extcon: usb-gpio: use flags argument of devm_gpiod_get to set direction |
| |
Hi Uwe,
You must send the extcon patch to the linux-kernel@vger.kernel.org.
On 05/19/2015 09:18 PM, Uwe Kleine-König wrote: > Since 39b2bbe3d715 (gpio: add flags argument to gpiod_get*() functions) > which appeared in v3.17-rc1, the gpiod_get* functions take an additional > parameter that allows to specify direction and initial value for output. > > Without this patch there is no call to gpiod_direction_input but the > gpio is used for irq reporting and for that the line should be in input > mode. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> > --- > > Notes: > Changes since (implicit) v1, sent with > Message-Id: 1432020518-19389-1-git-send-email-u.kleine-koenig@pengutronix.de: > > - drop Fixes: > - make it actually compile > > drivers/extcon/extcon-usb-gpio.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/extcon/extcon-usb-gpio.c b/drivers/extcon/extcon-usb-gpio.c > index e45d1f13f445..df7f3f32e325 100644 > --- a/drivers/extcon/extcon-usb-gpio.c > +++ b/drivers/extcon/extcon-usb-gpio.c > @@ -113,7 +113,7 @@ static int usb_extcon_probe(struct platform_device *pdev) > return -ENOMEM; > > info->dev = dev; > - info->id_gpiod = devm_gpiod_get(&pdev->dev, "id"); > + info->id_gpiod = devm_gpiod_get(&pdev->dev, "id", GPIOD_IN); > if (IS_ERR(info->id_gpiod)) { > dev_err(dev, "failed to get ID GPIO\n"); > return PTR_ERR(info->id_gpiod); >
Applied it.
Thanks, Chanwoo Choi
| |