Commit f12fb284 authored by Lubomir Rintel's avatar Lubomir Rintel Committed by Mauro Carvalho Chehab

media: marvell-ccic/mmp: enable clock before accessing registers

The access to REG_CLKCTRL or REG_CTRL1 without the clock enabled hangs
the machine. Enable the clock first.
Signed-off-by: default avatarLubomir Rintel <lkundrak@v3.sk>
Acked-by: default avatarPavel Machek <pavel@ucw.cz>
Signed-off-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+samsung@kernel.org>
parent fa49e1d3
...@@ -142,6 +142,7 @@ static int mmpcam_power_up(struct mcam_camera *mcam) ...@@ -142,6 +142,7 @@ static int mmpcam_power_up(struct mcam_camera *mcam)
* Turn on power and clocks to the controller. * Turn on power and clocks to the controller.
*/ */
mmpcam_power_up_ctlr(cam); mmpcam_power_up_ctlr(cam);
mcam_clk_enable(mcam);
/* /*
* Provide power to the sensor. * Provide power to the sensor.
*/ */
...@@ -155,8 +156,6 @@ static int mmpcam_power_up(struct mcam_camera *mcam) ...@@ -155,8 +156,6 @@ static int mmpcam_power_up(struct mcam_camera *mcam)
gpio_set_value(pdata->sensor_reset_gpio, 1); /* reset is active low */ gpio_set_value(pdata->sensor_reset_gpio, 1); /* reset is active low */
mdelay(5); mdelay(5);
mcam_clk_enable(mcam);
return 0; return 0;
} }
......
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