eDP DRRS patches with IGT app
Subsystems (2)
cover eDP DRRS patches with IGT app
When multiple eDP connectors are in place, these patches limit the eDP DRRS to only one eDP panel at a time. And also handles the issue with the initialization of the DRRS capability enum.
Along with these kernel patches an IGT app is implemented to test the eDP DRRS.
Ramalingam C (3):
drm/i915: Removing the drrs capability enum initialization drm/i915: eDP DRRS limited to only one panel at a time
tests/kms_drrs: Test Idleness DRRS
drivers/gpu/drm/i915/intel_dp.c | 7 +++++-- tests/Makefile.sources | 1 + tests/kms_drrs.c | 376 +++++++++++++++++++++++++++++++++++++++ 3 file changed, 382 insertions(+), 2 deletions(-) create mode 100644 tests/kms_drrs.c
Signature · 6 lines
1.7.9.5 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 1/2 drm/i915: Removing the drrs capability enum initialization
As part of allocation of the drm_i915_private variable, drrs capability enum is initialized to DRRS_NOT_SUPPORTED. Hence need not initialize at each connector init.
Moreover initializing this enum at connector init will reset the successful DRRS initialization of previous connector, as we have the DRRS support for only one panel at a time.
--- drivers/gpu/drm/i915/intel_dp.c | 2 -- 1 file changed, 2 deletions(-)
drivers/gpu/drm/i915/intel_dp.c +0 -2
@@ -5337,8 +5337,6 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,struct edid *edid;enum pipe pipe =INVALID_PIPE ; - dev_priv->drrs.type =DRRS_NOT_SUPPORTED ; -if (!is_edp (intel_dp))return true;
Signature · 6 lines
1.7.9.5 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/2] drm/i915: Removing the drrs capability enum initialization
Quoted 18 lines · Ramalingam C
As part of allocation of the
drm_i915_privatevariable, drrs capability enum is initialized toDRRS_NOT_SUPPORTED. Hence need not initialize at each connector init.Moreover initializing this enum at connector init will reset the successful DRRS initialization of previous connector, as we have the DRRS support for only one panel at a time.
Signed-off-by Ramalingam C <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 2 -- 1 file changed, 2 deletions(-)drivers/gpu/drm/i915/intel_dp.c +0
-0
drivers/gpu/drm/i915/intel_dp.c static bool intel_edp_init_connector(struct intel_dp *intel_dp, · line 5342
Quoted 8 lines
drivers/gpu/drm/i915/intel_dp.c +0
-2@@ -5337,8 +5337,6 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,struct edid *edid;enum pipe pipe =INVALID_PIPE ; - dev_priv->drrs.type =DRRS_NOT_SUPPORTED ; -if (!is_edp (intel_dp))return true;
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 2/2 drm/i915: eDP DRRS limited to only one panel at a time
In reply to Ramalingam CIn case of multiple eDP panels, only one can have
the DRRS enabled on it.
In future eDP DRRS will be extended for multiple panels.
--- drivers/gpu/drm/i915/intel_dp.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/gpu/drm/i915/intel_dp.c +5 -0
@@ -5311,6 +5311,11 @@ intel_dp_drrs_init(struct intel_connector *intel_connector,return NULL ; } +if (dev_priv->drrs.type ==SEAMLESS_DRRS_SUPPORT ) { +DRM_DEBUG_KMS ("DRRS already enabled on previous connector\n" ); +return NULL ; + } +INIT_DELAYED_WORK (&dev_priv->drrs.work, intel_edp_drrs_downclock_work);mutex_init (&dev_priv->drrs.mutex);
Signature · 6 lines
1.7.9.5 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 2/2] drm/i915: eDP DRRS limited to only one panel at a time
since drrs struct is used primarily in intel_dp.c file alone can it be moved to intel_dp ?
Quoted 16 lines · Ramalingam C
In case of multiple eDP panels, only one can have
the DRRS enabled on it.In future eDP DRRS will be extended for multiple panels.
Signed-off-by Ramalingam C <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 5 +++++ 1 file changed, 5 insertions(+)drivers/gpu/drm/i915/intel_dp.c +0
-0@@ -5311,6 +5311,11 @@ intel_dp_drrs_init(struct intel_connector *intel_connector,return NULL ;
drivers/gpu/drm/i915/intel_dp.c intel_dp_drrs_init(struct intel_connector *intel_connector, · line 5321
Quoted 10 lines
drivers/gpu/drm/i915/intel_dp.c +5
-0} +if (dev_priv->drrs.type ==SEAMLESS_DRRS_SUPPORT ) { +DRM_DEBUG_KMS ("DRRS already enabled on previous connector\n" ); +return NULL ; + } +INIT_DELAYED_WORK (&dev_priv->drrs.work, intel_edp_drrs_downclock_work);mutex_init (&dev_priv->drrs.mutex);
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 2/2] drm/i915: eDP DRRS limited to only one panel at a time
Hi Siva,
Since the same structure will be used to implement DRRS on DSI also we have placed it at i915_dev_priv. I am working on the RFC for the DRRS on DSI.
Quoted 30 lines · Sivakumar Thulasimani
since drrs struct is used primarily in
intel_dp.cfile alone can it be moved tointel_dp?Quoted 26 lines · Ramalingam C
In case of multiple eDP panels, only one can have
the DRRS enabled on it.In future eDP DRRS will be extended for multiple panels.
Signed-off-by Ramalingam C <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 5 +++++ 1 file changed, 5 insertions(+)drivers/gpu/drm/i915/intel_dp.c +4
-0@@ -5311,6 +5311,11 @@ intel_dp_drrs_init(struct intel_connector *intel_connector, return NULL; } + if (dev_priv->drrs.type == SEAMLESS_DRRS_SUPPORT) { +DRM_DEBUG_KMS ("DRRS already enabled on previous connector\n" ); +return NULL ; + } +INIT_DELAYED_WORK (&dev_priv->drrs.work, intel_edp_drrs_downclock_work);mutex_init (&dev_priv->drrs.mutex);
Signature · 6 lines
Ram _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 2/2] drm/i915: eDP DRRS limited to only one panel at a time
Quoted 5 lines · Ramalingam C
Hi Siva,
Since the same structure will be used to implement DRRS on DSI also we have placed it at
i915_dev_priv.
I am working on the RFC for the DRRS on DSI.
I think a better approach would be to make an array of dev_priv->drrs->dp pointers, so that we can support one drrs instance per pipe. Well maybe we need to change it from dp to intel_encoder so that it also works for dsi ports.
Aside since I just again looked at the code: The locking for drrs is still a bit broken:
- A few places check for ->drrs.dp != NULL without holding drrs.mutex.
- Imo we should add a WARN_ON(!mutex_locked(drrs.mutex)) to drrs_set_state function.
Ramalingam can you please take care of that?
Thanks, Daniel
Quoted 38 lines · Sivakumar Thulasimani
Quoted 32 lines
since drrs struct is used primarily in
intel_dp.cfile alone can it be moved tointel_dp?Quoted 27 lines · Ramalingam C
In case of multiple eDP panels, only one can have
the DRRS enabled on it.In future eDP DRRS will be extended for multiple panels.
Signed-off-by Ramalingam C <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 5 +++++ 1 file changed, 5 insertions(+)drivers/gpu/drm/i915/intel_dp.c +4
-0@@ -5311,6 +5311,11 @@ intel_dp_drrs_init(struct intel_connector *intel_connector, return NULL; } + if (dev_priv->drrs.type == SEAMLESS_DRRS_SUPPORT) { +DRM_DEBUG_KMS ("DRRS already enabled on previous connector\n" ); +return NULL ; + } +INIT_DELAYED_WORK (&dev_priv->drrs.work, intel_edp_drrs_downclock_work);mutex_init (&dev_priv->drrs.mutex);Signature · 1 line
Ram
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 2/2] drm/i915: eDP DRRS limited to only one panel at a time
Quoted 11 lines · Daniel Vetter
Quoted 5 lines · Ramalingam C
Hi Siva,
Since the same structure will be used to implement DRRS on DSI also we have placed it at
i915_dev_priv.
I am working on the RFC for the DRRS on DSI.I think a better approach would be to make an array of
dev_priv->drrs->dppointers, so that we can support one drrs instance per pipe. Well maybe we need to change it from dp tointel_encoderso that it also works for dsi ports.
Quoted 7 lines
Aside since I just again looked at the code: The locking for drrs is still a bit broken:
- A few places check for ->drrs.dp != NULL without holding drrs.mutex.
- Imo we should add a WARN_ON(!mutex_locked(drrs.mutex)) todrrs_set_statefunction.Ramalingam can you please take care of that?
Sure I will look into it Daniel.
Quoted 38 lines
Thanks, Daniel
Quoted 35 lines · Sivakumar Thulasimani
Quoted 31 lines
since drrs struct is used primarily in
intel_dp.cfile alone can it be moved tointel_dp?Quoted 27 lines · Ramalingam C
In case of multiple eDP panels, only one can have
the DRRS enabled on it.In future eDP DRRS will be extended for multiple panels.
Signed-off-by Ramalingam C <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 5 +++++ 1 file changed, 5 insertions(+)drivers/gpu/drm/i915/intel_dp.c +4
-0@@ -5311,6 +5311,11 @@ intel_dp_drrs_init(struct intel_connector *intel_connector, return NULL; } + if (dev_priv->drrs.type == SEAMLESS_DRRS_SUPPORT) { +DRM_DEBUG_KMS ("DRRS already enabled on previous connector\n" ); +return NULL ; + } +INIT_DELAYED_WORK (&dev_priv->drrs.work, intel_edp_drrs_downclock_work);mutex_init (&dev_priv->drrs.mutex);Signature · 1 line
Ram
Signature · 6 lines
Thanks --Ram _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 2/2] drm/i915: eDP DRRS limited to only one panel at a time
In reply to Ramalingam CTask id: 6031 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series Applied
PNV -2 275/275 273/275 ILK -1 303/303 302/303 SNB 304/304 304/304 IVB 339/339 339/339 BYT 287/287 287/287 HSW 361/361 361/361 BDW 310/310 310/310 -------------------------------------Detailed------------------------------------- Platform Test drm-intel-nightly Series Applied *PNV igt@gem_userptr_blits@minor-sync-interruptible PASS(3) DMESG_WARN(1)PASS(1) *PNV igt@gem_userptr_blits@minor-unsync-normal PASS(2) DMESG_WARN(2) *ILK igt@gem_unfence_active_buffers PASS(2) DMESG_WARN(2)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list [email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 1/1 tests/kms_drrs: Test Idleness DRRS
In reply to Ramalingam CIdleness DRRS:
By default the DRRS state will be at DRRS_HIGH_RR. When a Display content is Idle for more than 1Sec Idleness will be declared and DRRS_LOW_RR will be invoked. And as soon as there is a display content change there will be a DRRS state transition as DRRS_LOW_RR--> DRRS_HIGH_RR.
To test this Idleness DRRS IGT will probe the DRRS state at below instances and compare with the expected state.
Instance Expected State
1. Immediately after rendering the still image DRRS_HIGH_RR
2. After a delay of 1.2Sec DRRS_LOW_RR
3. After changing the frame buffer DRRS_HIGH_RR
4. After a delay of 1.2Sec DRRS_LOW_RR
5. After changing the frame buffer DRRS_HIGH_RR
6. After a delay of 1.2Sec DRRS_LOW_RR
--- tests/Makefile.sources | 1 + tests/kms_drrs.c | 376 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 377 insertions(+) create mode 100644 tests/kms_drrs.c
tests/Makefile.sources +1 -0
@@ -65,6 +65,7 @@ TESTS_progs_M = \ gem_write_read_ring_switch \ kms_addfb \ kms_cursor_crc \ + kms_drrs \ kms_fbc_crc \ kms_flip \ kms_flip_event_leak \
tests/kms_drrs.c new file +376 -0
376 lines not on this page · raw message
Signature · 6 lines
1.7.9.5 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx