diff options
author | Lubomir Rintel <lkundrak@v3.sk> | 2019-05-28 05:07:27 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2019-06-24 11:23:34 -0400 |
commit | f12fb2849b11b4c571a32d31ec51eabd70ab8193 (patch) | |
tree | 4b0137aa11176cf3b60582725ccb4912ea2d24a4 /drivers/media | |
parent | fa49e1d37bbd6d25a11379891ece1e4d5d313036 (diff) | |
download | linux-stable-f12fb2849b11b4c571a32d31ec51eabd70ab8193.tar.gz linux-stable-f12fb2849b11b4c571a32d31ec51eabd70ab8193.tar.bz2 linux-stable-f12fb2849b11b4c571a32d31ec51eabd70ab8193.zip |
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: Lubomir Rintel <lkundrak@v3.sk>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/platform/marvell-ccic/mmp-driver.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/platform/marvell-ccic/mmp-driver.c b/drivers/media/platform/marvell-ccic/mmp-driver.c index 25a4e2b580f4..bd2934a4d7ce 100644 --- a/drivers/media/platform/marvell-ccic/mmp-driver.c +++ b/drivers/media/platform/marvell-ccic/mmp-driver.c @@ -142,6 +142,7 @@ static int mmpcam_power_up(struct mcam_camera *mcam) * Turn on power and clocks to the controller. */ mmpcam_power_up_ctlr(cam); + mcam_clk_enable(mcam); /* * Provide power to the sensor. */ @@ -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 */ mdelay(5); - mcam_clk_enable(mcam); - return 0; } |