summaryrefslogtreecommitdiffstats
path: root/drivers/media/i2c/noon010pc30.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2013-05-02 16:11:50 +0200
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-05-21 12:50:56 +0200
commit95323361e5313733a54771c5059f5b352adbf32c (patch)
tree9731320d716278f03171002ee6c98d6d2948af6e /drivers/media/i2c/noon010pc30.c
parent[media] tvp514x: Fix double free (diff)
downloadlinux-95323361e5313733a54771c5059f5b352adbf32c.tar.xz
linux-95323361e5313733a54771c5059f5b352adbf32c.zip
[media] media: i2c: Convert to gpio_request_one()
Replace gpio_request() with gpio_request_one() and remove the associated gpio_direction_output() calls. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/i2c/noon010pc30.c')
-rw-r--r--drivers/media/i2c/noon010pc30.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/i2c/noon010pc30.c b/drivers/media/i2c/noon010pc30.c
index 8554b47f993a..a115842ab996 100644
--- a/drivers/media/i2c/noon010pc30.c
+++ b/drivers/media/i2c/noon010pc30.c
@@ -746,24 +746,24 @@ static int noon010_probe(struct i2c_client *client,
info->curr_win = &noon010_sizes[0];
if (gpio_is_valid(pdata->gpio_nreset)) {
- ret = gpio_request(pdata->gpio_nreset, "NOON010PC30 NRST");
+ ret = gpio_request_one(pdata->gpio_nreset, GPIOF_OUT_INIT_LOW,
+ "NOON010PC30 NRST");
if (ret) {
dev_err(&client->dev, "GPIO request error: %d\n", ret);
goto np_err;
}
info->gpio_nreset = pdata->gpio_nreset;
- gpio_direction_output(info->gpio_nreset, 0);
gpio_export(info->gpio_nreset, 0);
}
if (gpio_is_valid(pdata->gpio_nstby)) {
- ret = gpio_request(pdata->gpio_nstby, "NOON010PC30 NSTBY");
+ ret = gpio_request_one(pdata->gpio_nstby, GPIOF_OUT_INIT_LOW,
+ "NOON010PC30 NSTBY");
if (ret) {
dev_err(&client->dev, "GPIO request error: %d\n", ret);
goto np_gpio_err;
}
info->gpio_nstby = pdata->gpio_nstby;
- gpio_direction_output(info->gpio_nstby, 0);
gpio_export(info->gpio_nstby, 0);
}