diff mbox series

[07/57] media: atomisp: Remove useless msleep(10) before power-on on BYT

Message ID 20230123125205.622152-8-hdegoede@redhat.com (mailing list archive)
State New, archived
Headers show
Series media: atomisp: Big power-management changes + lots of fixes | expand

Commit Message

Hans de Goede Jan. 23, 2023, 12:51 p.m. UTC
On BYT on poweron/runtime-resume the code is doing:

1. Do nothing
2. msleep(10)
3. Start actual poweron sequence

Since the runtime resume can happen at any moment, waiting 10ms
after it does not really make any sense.

According to both the comment and to:
https://github.com/intel/ProductionKernelQuilts/blob/master/uefi/cht-m1stable/patches/cam-0341-atomisp-WA-sleep-10ms-when-power-up-ISP-on-byt.patch

Which is the patch which originally added this this was added
as a workaround for a single test failing on a single model
tablet/laptop. So lets just drop this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 drivers/staging/media/atomisp/pci/atomisp_v4l2.c | 8 --------
 1 file changed, 8 deletions(-)

Comments

Andy Shevchenko Jan. 23, 2023, 2:40 p.m. UTC | #1
On Mon, Jan 23, 2023 at 01:51:15PM +0100, Hans de Goede wrote:
> On BYT on poweron/runtime-resume the code is doing:
> 
> 1. Do nothing
> 2. msleep(10)
> 3. Start actual poweron sequence
> 
> Since the runtime resume can happen at any moment, waiting 10ms
> after it does not really make any sense.
> 
> According to both the comment and to:
> https://github.com/intel/ProductionKernelQuilts/blob/master/uefi/cht-m1stable/patches/cam-0341-atomisp-WA-sleep-10ms-when-power-up-ISP-on-byt.patch
> 
> Which is the patch which originally added this this was added
> as a workaround for a single test failing on a single model
> tablet/laptop. So lets just drop this.

Since it's for BYT platforms and you have plenty to test, I believe it's the
right thing to do.

Reviewed-by: Andy Shevchenko <andy@kernel.org>

> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>  drivers/staging/media/atomisp/pci/atomisp_v4l2.c | 8 --------
>  1 file changed, 8 deletions(-)
> 
> diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
> index 9eea8ffbc3d6..aa05c69a5c6b 100644
> --- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
> +++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
> @@ -665,14 +665,6 @@ static int atomisp_mrfld_power(struct atomisp_device *isp, bool enable)
>  		msleep(20);
>  	}
>  
> -	/*
> -	 * FIXME:WA for ECS28A, with this sleep, CTS
> -	 * android.hardware.camera2.cts.CameraDeviceTest#testCameraDeviceAbort
> -	 * PASS, no impact on other platforms
> -	 */
> -	if (IS_BYT && enable)
> -		msleep(10);
> -
>  	/* Write to ISPSSPM0 bit[1:0] to power on/off the IUNIT */
>  	iosf_mbi_modify(BT_MBI_UNIT_PMC, MBI_REG_READ, MRFLD_ISPSSPM0,
>  			val, MRFLD_ISPSSPM0_ISPSSC_MASK);
> -- 
> 2.39.0
>
diff mbox series

Patch

diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
index 9eea8ffbc3d6..aa05c69a5c6b 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
@@ -665,14 +665,6 @@  static int atomisp_mrfld_power(struct atomisp_device *isp, bool enable)
 		msleep(20);
 	}
 
-	/*
-	 * FIXME:WA for ECS28A, with this sleep, CTS
-	 * android.hardware.camera2.cts.CameraDeviceTest#testCameraDeviceAbort
-	 * PASS, no impact on other platforms
-	 */
-	if (IS_BYT && enable)
-		msleep(10);
-
 	/* Write to ISPSSPM0 bit[1:0] to power on/off the IUNIT */
 	iosf_mbi_modify(BT_MBI_UNIT_PMC, MBI_REG_READ, MRFLD_ISPSSPM0,
 			val, MRFLD_ISPSSPM0_ISPSSC_MASK);