media: atomisp: keep the ISP powered on when setting it
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 19 May 2020 07:15:41 +0000 (09:15 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Wed, 20 May 2020 12:51:29 +0000 (14:51 +0200)
The current code causes ISP2401 to power down and never return
back to live, causing the driver to crash.

Fix it by commenting out the bad code. It should be noticed that
the Yocto Aero code has something similar to it.

Maybe the issue is related to an ISP bug (or maybe PM is
controlled on a different way for this hardware).

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/staging/media/atomisp/pci/atomisp_v4l2.c

index 8c7b422..4395ca0 100644 (file)
@@ -824,13 +824,17 @@ static int atomisp_mrfld_power(struct atomisp_device *isp, bool enable)
 /* Workaround for pmu_nc_set_power_state not ready in MRFLD */
 int atomisp_mrfld_power_down(struct atomisp_device *isp)
 {
-       return atomisp_mrfld_power(isp, false);
+       return 0;
+// FIXME: at least with ISP2401, the code below causes the driver to break
+//     return atomisp_mrfld_power(isp, false);
 }
 
 /* Workaround for pmu_nc_set_power_state not ready in MRFLD */
 int atomisp_mrfld_power_up(struct atomisp_device *isp)
 {
-       return atomisp_mrfld_power(isp, true);
+       return 0;
+// FIXME: at least with ISP2401, the code below causes the driver to break
+//     return atomisp_mrfld_power(isp, true);
 }
 
 int atomisp_runtime_suspend(struct device *dev)