Commit 66c7b303 authored by Hans de Goede's avatar Hans de Goede Committed by Mauro Carvalho Chehab

media: atomisp: ov2680: Add dev local variable to probe()

Add a dev local variable to probe(), to allow shortening
&client->dev in various places, including further patches
in this series.
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@kernel.org>
parent e25a2589
......@@ -781,6 +781,7 @@ static void ov2680_remove(struct i2c_client *client)
static int ov2680_probe(struct i2c_client *client)
{
struct device *dev = &client->dev;
struct ov2680_device *sensor;
int ret;
void *pdata;
......@@ -802,10 +803,10 @@ static int ov2680_probe(struct i2c_client *client)
goto out_free;
}
pm_runtime_set_suspended(&client->dev);
pm_runtime_enable(&client->dev);
pm_runtime_set_autosuspend_delay(&client->dev, 1000);
pm_runtime_use_autosuspend(&client->dev);
pm_runtime_set_suspended(dev);
pm_runtime_enable(dev);
pm_runtime_set_autosuspend_delay(dev, 1000);
pm_runtime_use_autosuspend(dev);
ret = ov2680_s_config(&sensor->sd, client->irq, pdata);
if (ret)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment