* [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
@ 2024-10-17 7:57 Giedrius Statkevičius
2024-11-04 12:09 ` Giedrius Statkevičius
0 siblings, 1 reply; 7+ messages in thread
From: Giedrius Statkevičius @ 2024-10-17 7:57 UTC (permalink / raw)
To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
Simona Vetter, Jani Nikula, Rodrigo Vivi, Joonas Lahtinen,
Tvrtko Ursulin
Cc: Giedrius Statkevičius, Ankit Nautiyal, dri-devel,
linux-kernel, intel-gfx, intel-xe
Avoid hardcoding the LSPCON settle timeout because it takes a longer
time on certain chips made by certain vendors. Use the function that
already exists to determine the timeout.
Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>
---
v2: add documentation about the parameter, apply 80 character line
length limit.
drivers/gpu/drm/display/drm_dp_dual_mode_helper.c | 4 ++--
drivers/gpu/drm/i915/display/intel_lspcon.c | 3 ++-
include/drm/display/drm_dp_dual_mode_helper.h | 2 +-
3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/display/drm_dp_dual_mode_helper.c b/drivers/gpu/drm/display/drm_dp_dual_mode_helper.c
index 14a2a8473682..d14b262b2344 100644
--- a/drivers/gpu/drm/display/drm_dp_dual_mode_helper.c
+++ b/drivers/gpu/drm/display/drm_dp_dual_mode_helper.c
@@ -486,16 +486,16 @@ EXPORT_SYMBOL(drm_lspcon_get_mode);
* @dev: &drm_device to use
* @adapter: I2C-over-aux adapter
* @mode: required mode of operation
+ * @time_out: LSPCON mode change settle timeout
*
* Returns:
* 0 on success, -error on failure/timeout
*/
int drm_lspcon_set_mode(const struct drm_device *dev, struct i2c_adapter *adapter,
- enum drm_lspcon_mode mode)
+ enum drm_lspcon_mode mode, int time_out)
{
u8 data = 0;
int ret;
- int time_out = 200;
enum drm_lspcon_mode current_mode;
if (mode == DRM_LSPCON_MODE_PCON)
diff --git a/drivers/gpu/drm/i915/display/intel_lspcon.c b/drivers/gpu/drm/i915/display/intel_lspcon.c
index f9db867fae89..30c31fddec99 100644
--- a/drivers/gpu/drm/i915/display/intel_lspcon.c
+++ b/drivers/gpu/drm/i915/display/intel_lspcon.c
@@ -211,7 +211,8 @@ static int lspcon_change_mode(struct intel_lspcon *lspcon,
return 0;
}
- err = drm_lspcon_set_mode(intel_dp->aux.drm_dev, ddc, mode);
+ err = drm_lspcon_set_mode(intel_dp->aux.drm_dev, ddc, mode,
+ lspcon_get_mode_settle_timeout(lspcon));
if (err < 0) {
drm_err(display->drm, "LSPCON mode change failed\n");
return err;
diff --git a/include/drm/display/drm_dp_dual_mode_helper.h b/include/drm/display/drm_dp_dual_mode_helper.h
index 7ee482265087..7ac6969db935 100644
--- a/include/drm/display/drm_dp_dual_mode_helper.h
+++ b/include/drm/display/drm_dp_dual_mode_helper.h
@@ -117,5 +117,5 @@ const char *drm_dp_get_dual_mode_type_name(enum drm_dp_dual_mode_type type);
int drm_lspcon_get_mode(const struct drm_device *dev, struct i2c_adapter *adapter,
enum drm_lspcon_mode *current_mode);
int drm_lspcon_set_mode(const struct drm_device *dev, struct i2c_adapter *adapter,
- enum drm_lspcon_mode reqd_mode);
+ enum drm_lspcon_mode reqd_mode, int time_out);
#endif
--
2.47.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
2024-10-17 7:57 [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout Giedrius Statkevičius
@ 2024-11-04 12:09 ` Giedrius Statkevičius
2024-11-04 21:28 ` Rodrigo Vivi
0 siblings, 1 reply; 7+ messages in thread
From: Giedrius Statkevičius @ 2024-11-04 12:09 UTC (permalink / raw)
To: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
Simona Vetter, Jani Nikula, Rodrigo Vivi, Joonas Lahtinen,
Tvrtko Ursulin
Cc: Ankit Nautiyal, dri-devel, linux-kernel, intel-gfx, intel-xe
Hello,
Kind ping.
On Thu, 17 Oct 2024 at 10:57, Giedrius Statkevičius
<giedriuswork@gmail.com> wrote:
>
> Avoid hardcoding the LSPCON settle timeout because it takes a longer
> time on certain chips made by certain vendors. Use the function that
> already exists to determine the timeout.
>
> Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
> Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
2024-11-04 12:09 ` Giedrius Statkevičius
@ 2024-11-04 21:28 ` Rodrigo Vivi
2024-11-07 8:21 ` Giedrius Statkevičius
2025-01-22 11:15 ` Giedrius Statkevičius
0 siblings, 2 replies; 7+ messages in thread
From: Rodrigo Vivi @ 2024-11-04 21:28 UTC (permalink / raw)
To: Giedrius Statkevičius
Cc: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
Simona Vetter, Jani Nikula, Joonas Lahtinen, Tvrtko Ursulin,
Ankit Nautiyal, dri-devel, linux-kernel, intel-gfx, intel-xe
On Mon, Nov 04, 2024 at 02:09:46PM +0200, Giedrius Statkevičius wrote:
> Hello,
>
> Kind ping.
There was a pipe underun in CI... I honestly don't believe this patch is
causing it, but anyway I decided to trigger a retest there before I push this.
Thanks for the patch and review.
>
>
> On Thu, 17 Oct 2024 at 10:57, Giedrius Statkevičius
> <giedriuswork@gmail.com> wrote:
> >
> > Avoid hardcoding the LSPCON settle timeout because it takes a longer
> > time on certain chips made by certain vendors. Use the function that
> > already exists to determine the timeout.
> >
> > Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
> > Signed-off-by: Giedrius Statkevičius <giedriuswork@gmail.com>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
2024-11-04 21:28 ` Rodrigo Vivi
@ 2024-11-07 8:21 ` Giedrius Statkevičius
2025-01-22 11:15 ` Giedrius Statkevičius
1 sibling, 0 replies; 7+ messages in thread
From: Giedrius Statkevičius @ 2024-11-07 8:21 UTC (permalink / raw)
To: Rodrigo Vivi
Cc: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
Simona Vetter, Jani Nikula, Joonas Lahtinen, Tvrtko Ursulin,
Ankit Nautiyal, dri-devel, linux-kernel, intel-gfx, intel-xe
Hello,
On Mon, 4 Nov 2024 at 23:28, Rodrigo Vivi <rodrigo.vivi@intel.com> wrote:
>
> On Mon, Nov 04, 2024 at 02:09:46PM +0200, Giedrius Statkevičius wrote:
> > Hello,
> >
> > Kind ping.
>
> There was a pipe underun in CI... I honestly don't believe this patch is
> causing it, but anyway I decided to trigger a retest there before I push this.
>
> Thanks for the patch and review.
I don't see that on my laptop. Resuming sometimes still doesn't work but
this helps a little from my testing. I will continue the investigation.
Best regards,
Giedrius
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
2024-11-04 21:28 ` Rodrigo Vivi
2024-11-07 8:21 ` Giedrius Statkevičius
@ 2025-01-22 11:15 ` Giedrius Statkevičius
2025-01-24 3:16 ` Rodrigo Vivi
1 sibling, 1 reply; 7+ messages in thread
From: Giedrius Statkevičius @ 2025-01-22 11:15 UTC (permalink / raw)
To: Rodrigo Vivi
Cc: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
Simona Vetter, Jani Nikula, Joonas Lahtinen, Tvrtko Ursulin,
Ankit Nautiyal, dri-devel, linux-kernel, intel-gfx, intel-xe
Hello,
On Mon, 4 Nov 2024 at 23:28, Rodrigo Vivi <rodrigo.vivi@intel.com> wrote:
>
> On Mon, Nov 04, 2024 at 02:09:46PM +0200, Giedrius Statkevičius wrote:
> > Hello,
> >
> > Kind ping.
>
> There was a pipe underun in CI... I honestly don't believe this patch is
> causing it, but anyway I decided to trigger a retest there before I push this.
>
> Thanks for the patch and review.
Ping. Could we merge this patch? This plus another patch (that I have yet to
send) fixes replugging the HDMI cable on my laptop.
Best regards,
Giedrius
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
2025-01-22 11:15 ` Giedrius Statkevičius
@ 2025-01-24 3:16 ` Rodrigo Vivi
2025-01-27 20:06 ` Rodrigo Vivi
0 siblings, 1 reply; 7+ messages in thread
From: Rodrigo Vivi @ 2025-01-24 3:16 UTC (permalink / raw)
To: Giedrius Statkevičius, Simona Vetter, Dave Airlie, dri-devel
Cc: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
Simona Vetter, Jani Nikula, Joonas Lahtinen, Tvrtko Ursulin,
Ankit Nautiyal, dri-devel, linux-kernel, intel-gfx, intel-xe
On Wed, Jan 22, 2025 at 01:15:31PM +0200, Giedrius Statkevičius wrote:
> Hello,
>
> On Mon, 4 Nov 2024 at 23:28, Rodrigo Vivi <rodrigo.vivi@intel.com> wrote:
> >
> > On Mon, Nov 04, 2024 at 02:09:46PM +0200, Giedrius Statkevičius wrote:
> > > Hello,
> > >
> > > Kind ping.
> >
> > There was a pipe underun in CI... I honestly don't believe this patch is
> > causing it, but anyway I decided to trigger a retest there before I push this.
> >
> > Thanks for the patch and review.
>
>
> Ping. Could we merge this patch? This plus another patch (that I have yet to
> send) fixes replugging the HDMI cable on my laptop.
First of all I'm sorry for the delay here.
CI was the problem, not the patch.
I was going to merge this right now, but I noticed it touches include/drm
Sima, Dave, ack to get this through drm-intel-next?
>
> Best regards,
> Giedrius
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout
2025-01-24 3:16 ` Rodrigo Vivi
@ 2025-01-27 20:06 ` Rodrigo Vivi
0 siblings, 0 replies; 7+ messages in thread
From: Rodrigo Vivi @ 2025-01-27 20:06 UTC (permalink / raw)
To: Giedrius Statkevičius, Simona Vetter, Dave Airlie, dri-devel
Cc: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Jani Nikula,
Joonas Lahtinen, Tvrtko Ursulin, Ankit Nautiyal, linux-kernel,
intel-gfx, intel-xe
On Thu, Jan 23, 2025 at 10:16:07PM -0500, Rodrigo Vivi wrote:
> On Wed, Jan 22, 2025 at 01:15:31PM +0200, Giedrius Statkevičius wrote:
> > Hello,
> >
> > On Mon, 4 Nov 2024 at 23:28, Rodrigo Vivi <rodrigo.vivi@intel.com> wrote:
> > >
> > > On Mon, Nov 04, 2024 at 02:09:46PM +0200, Giedrius Statkevičius wrote:
> > > > Hello,
> > > >
> > > > Kind ping.
> > >
> > > There was a pipe underun in CI... I honestly don't believe this patch is
> > > causing it, but anyway I decided to trigger a retest there before I push this.
> > >
> > > Thanks for the patch and review.
> >
> >
> > Ping. Could we merge this patch? This plus another patch (that I have yet to
> > send) fixes replugging the HDMI cable on my laptop.
>
> First of all I'm sorry for the delay here.
>
> CI was the problem, not the patch.
>
> I was going to merge this right now, but I noticed it touches include/drm
>
> Sima, Dave, ack to get this through drm-intel-next?
pushed to drm-intel-next with irc ack from sima
>
> >
> > Best regards,
> > Giedrius
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2025-01-27 20:07 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-17 7:57 [PATCH v2] drm/i915/lspcon: do not hardcode settle timeout Giedrius Statkevičius
2024-11-04 12:09 ` Giedrius Statkevičius
2024-11-04 21:28 ` Rodrigo Vivi
2024-11-07 8:21 ` Giedrius Statkevičius
2025-01-22 11:15 ` Giedrius Statkevičius
2025-01-24 3:16 ` Rodrigo Vivi
2025-01-27 20:06 ` Rodrigo Vivi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).