[v2] drm/i915: Increase LSPCON timeout

Submitted by =?UTF-8?q?Fredrik=20Sch=C3=B6n?= on Aug. 17, 2018, 8:07 p.m.

Details

Message ID 20180817200728.8154-1-fredrik.schon@gmail.com
State Accepted
Commit 59f1c8ab30d6f9042562949f42cbd3f3cf69de94
Headers show
Series "drm/i915: Increase LSPCON timeout" ( rev: 1 ) in Intel GFX

Not browsing as part of any series.

Commit Message

=?UTF-8?q?Fredrik=20Sch=C3=B6n?= Aug. 17, 2018, 8:07 p.m.
100 ms is not enough time for the LSPCON adapter on Intel NUC devices to
settle. This causes dropped display modes at boot or screen reconfiguration.
Empirical testing can reproduce the error up to a timeout of 190 ms. Basic
boot and stress testing at 200 ms has not (yet) failed.

Increase timeout to 400 ms to get some margin of error.

Changes from v1:
The initial suggestion of 1000 ms was lowered due to concerns about delaying
valid timeout cases.
Update patch metadata.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107503
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1570392
Fixes: 357c0ae9198a ("drm/i915/lspcon: Wait for expected LSPCON mode to settle")
Cc: Shashank Sharma <shashank.sharma@intel.com>
Cc: Imre Deak <imre.deak@intel.com>
Cc: Jani Nikula <jani.nikula@intel.com>
Cc: <stable@vger.kernel.org> # v4.11+
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Fredrik Schön <fredrik.schon@gmail.com>
---
 drivers/gpu/drm/i915/intel_lspcon.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/i915/intel_lspcon.c b/drivers/gpu/drm/i915/intel_lspcon.c
index 8ae8f42f430a..6b6758419fb3 100644
--- a/drivers/gpu/drm/i915/intel_lspcon.c
+++ b/drivers/gpu/drm/i915/intel_lspcon.c
@@ -74,7 +74,7 @@  static enum drm_lspcon_mode lspcon_wait_mode(struct intel_lspcon *lspcon,
 	DRM_DEBUG_KMS("Waiting for LSPCON mode %s to settle\n",
 		      lspcon_mode_name(mode));
 
-	wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 100);
+	wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 400);
 	if (current_mode != mode)
 		DRM_ERROR("LSPCON mode hasn't settled\n");
 

Comments

On 8/18/2018 1:37 AM, Fredrik Schön wrote:

> 100 ms is not enough time for the LSPCON adapter on Intel NUC devices to
> settle. This causes dropped display modes at boot or screen reconfiguration.
> Empirical testing can reproduce the error up to a timeout of 190 ms. Basic
> boot and stress testing at 200 ms has not (yet) failed.
>
> Increase timeout to 400 ms to get some margin of error.
>
> Changes from v1:
> The initial suggestion of 1000 ms was lowered due to concerns about delaying
> valid timeout cases.
> Update patch metadata.
>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107503
> Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1570392
> Fixes: 357c0ae9198a ("drm/i915/lspcon: Wait for expected LSPCON mode to settle")
> Cc: Shashank Sharma <shashank.sharma@intel.com>
> Cc: Imre Deak <imre.deak@intel.com>
> Cc: Jani Nikula <jani.nikula@intel.com>
> Cc: <stable@vger.kernel.org> # v4.11+
> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
> Signed-off-by: Fredrik Schön <fredrik.schon@gmail.com>
> ---
>   drivers/gpu/drm/i915/intel_lspcon.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_lspcon.c b/drivers/gpu/drm/i915/intel_lspcon.c
> index 8ae8f42f430a..6b6758419fb3 100644
> --- a/drivers/gpu/drm/i915/intel_lspcon.c
> +++ b/drivers/gpu/drm/i915/intel_lspcon.c
> @@ -74,7 +74,7 @@ static enum drm_lspcon_mode lspcon_wait_mode(struct intel_lspcon *lspcon,
>   	DRM_DEBUG_KMS("Waiting for LSPCON mode %s to settle\n",
>   		      lspcon_mode_name(mode));
>   
> -	wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 100);
> +	wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 400);
>   	if (current_mode != mode)
>   		DRM_ERROR("LSPCON mode hasn't settled\n");
>   
Looks good to me
Reviewed-by: Shashank Sharma <shashank.sharma@intel.com>

- Shashank
On Mon, 20 Aug 2018, "Sharma, Shashank" <shashank.sharma@intel.com> wrote:
> On 8/18/2018 1:37 AM, Fredrik Schön wrote:
>
>> 100 ms is not enough time for the LSPCON adapter on Intel NUC devices to
>> settle. This causes dropped display modes at boot or screen reconfiguration.
>> Empirical testing can reproduce the error up to a timeout of 190 ms. Basic
>> boot and stress testing at 200 ms has not (yet) failed.
>>
>> Increase timeout to 400 ms to get some margin of error.
>>
>> Changes from v1:
>> The initial suggestion of 1000 ms was lowered due to concerns about delaying
>> valid timeout cases.
>> Update patch metadata.
>>
>> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107503
>> Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1570392
>> Fixes: 357c0ae9198a ("drm/i915/lspcon: Wait for expected LSPCON mode to settle")
>> Cc: Shashank Sharma <shashank.sharma@intel.com>
>> Cc: Imre Deak <imre.deak@intel.com>
>> Cc: Jani Nikula <jani.nikula@intel.com>
>> Cc: <stable@vger.kernel.org> # v4.11+
>> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
>> Signed-off-by: Fredrik Schön <fredrik.schon@gmail.com>
>> ---
>>   drivers/gpu/drm/i915/intel_lspcon.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/i915/intel_lspcon.c b/drivers/gpu/drm/i915/intel_lspcon.c
>> index 8ae8f42f430a..6b6758419fb3 100644
>> --- a/drivers/gpu/drm/i915/intel_lspcon.c
>> +++ b/drivers/gpu/drm/i915/intel_lspcon.c
>> @@ -74,7 +74,7 @@ static enum drm_lspcon_mode lspcon_wait_mode(struct intel_lspcon *lspcon,
>>   	DRM_DEBUG_KMS("Waiting for LSPCON mode %s to settle\n",
>>   		      lspcon_mode_name(mode));
>>   
>> -	wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 100);
>> +	wait_for((current_mode = lspcon_get_current_mode(lspcon)) == mode, 400);
>>   	if (current_mode != mode)
>>   		DRM_ERROR("LSPCON mode hasn't settled\n");
>>   
> Looks good to me
> Reviewed-by: Shashank Sharma <shashank.sharma@intel.com>

Pushed to drm-intel-next-queued, thanks for the patch and review.

BR,
Jani.