]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
6.10-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Aug 2024 14:09:21 +0000 (16:09 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Aug 2024 14:09:21 +0000 (16:09 +0200)
added patches:
revert-drm-amd-display-add-null-check-for-afb-before-dereferencing-in-amdgpu_dm_plane_handle_cursor_update.patch
revert-drm-amd-display-handle-hpd_irq-for-internal-link.patch

queue-6.10/revert-drm-amd-display-add-null-check-for-afb-before-dereferencing-in-amdgpu_dm_plane_handle_cursor_update.patch [new file with mode: 0644]
queue-6.10/revert-drm-amd-display-handle-hpd_irq-for-internal-link.patch [new file with mode: 0644]
queue-6.10/series

diff --git a/queue-6.10/revert-drm-amd-display-add-null-check-for-afb-before-dereferencing-in-amdgpu_dm_plane_handle_cursor_update.patch b/queue-6.10/revert-drm-amd-display-add-null-check-for-afb-before-dereferencing-in-amdgpu_dm_plane_handle_cursor_update.patch
new file mode 100644 (file)
index 0000000..2642d07
--- /dev/null
@@ -0,0 +1,53 @@
+From 778e3979c5dc9cbdb5d1b92afed427de6bc483b4 Mon Sep 17 00:00:00 2001
+From: Ivan Lipski <ivlipski@amd.com>
+Date: Fri, 7 Jun 2024 12:33:59 -0400
+Subject: Revert "drm/amd/display: Add NULL check for 'afb' before dereferencing in amdgpu_dm_plane_handle_cursor_update"
+
+From: Ivan Lipski <ivlipski@amd.com>
+
+commit 778e3979c5dc9cbdb5d1b92afed427de6bc483b4 upstream.
+
+[WHY]
+This patch is a dupplicate implementation of 14bcf29b, which we
+are reverting due to a regression with kms_plane_cursor IGT tests.
+
+This reverts commit 38e6f715b02b572f74677eb2f29d3b4bc6f1ddff.
+
+Reviewed-by: Srinivasan Shanmugam <srinivasan.shanmugam@amd.com>
+Tested-by: George Zhang <George.zhang@amd.com>
+Signed-off-by: Ivan Lipski <ivlipski@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_plane.c |   16 ++++------------
+ 1 file changed, 4 insertions(+), 12 deletions(-)
+
+--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_plane.c
++++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_plane.c
+@@ -1231,22 +1231,14 @@ void amdgpu_dm_plane_handle_cursor_updat
+ {
+       struct amdgpu_device *adev = drm_to_adev(plane->dev);
+       struct amdgpu_framebuffer *afb = to_amdgpu_framebuffer(plane->state->fb);
+-      struct drm_crtc *crtc;
+-      struct dm_crtc_state *crtc_state;
+-      struct amdgpu_crtc *amdgpu_crtc;
+-      u64 address;
++      struct drm_crtc *crtc = afb ? plane->state->crtc : old_plane_state->crtc;
++      struct dm_crtc_state *crtc_state = crtc ? to_dm_crtc_state(crtc->state) : NULL;
++      struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc);
++      uint64_t address = afb ? afb->address : 0;
+       struct dc_cursor_position position = {0};
+       struct dc_cursor_attributes attributes;
+       int ret;
+-      if (!afb)
+-              return;
+-
+-      crtc = plane->state->crtc ? plane->state->crtc : old_plane_state->crtc;
+-      crtc_state = crtc ? to_dm_crtc_state(crtc->state) : NULL;
+-      amdgpu_crtc = to_amdgpu_crtc(crtc);
+-      address = afb->address;
+-
+       if (!plane->state->fb && !old_plane_state->fb)
+               return;
diff --git a/queue-6.10/revert-drm-amd-display-handle-hpd_irq-for-internal-link.patch b/queue-6.10/revert-drm-amd-display-handle-hpd_irq-for-internal-link.patch
new file mode 100644 (file)
index 0000000..ec1a6e5
--- /dev/null
@@ -0,0 +1,86 @@
+From a2919b25778b7479e477cf49af8c680017eafc24 Mon Sep 17 00:00:00 2001
+From: Sung-huai Wang <danny.wang@amd.com>
+Date: Fri, 31 May 2024 15:43:44 +0800
+Subject: Revert "drm/amd/display: Handle HPD_IRQ for internal link"
+
+From: Sung-huai Wang <danny.wang@amd.com>
+
+commit a2919b25778b7479e477cf49af8c680017eafc24 upstream.
+
+[How&Why]
+This reverts commit 239b31bd5c3fef3698440bf6436b2068c6bb08a3.
+
+Due to the it effects Replay resync.
+
+Reviewed-by: Wenjing Liu <wenjing.liu@amd.com>
+Acked-by: Zaeem Mohamed <zaeem.mohamed@amd.com>
+Signed-off-by: Sung-huai Wang <danny.wang@amd.com>
+Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_irq_handler.c |   24 +++-------
+ 1 file changed, 9 insertions(+), 15 deletions(-)
+
+--- a/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_irq_handler.c
++++ b/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_irq_handler.c
+@@ -373,7 +373,6 @@ bool dp_handle_hpd_rx_irq(struct dc_link
+       union device_service_irq device_service_clear = {0};
+       enum dc_status result;
+       bool status = false;
+-      bool allow_active = false;
+       if (out_link_loss)
+               *out_link_loss = false;
+@@ -428,6 +427,12 @@ bool dp_handle_hpd_rx_irq(struct dc_link
+               return false;
+       }
++      if (handle_hpd_irq_psr_sink(link))
++              /* PSR-related error was detected and handled */
++              return true;
++
++      handle_hpd_irq_replay_sink(link);
++
+       /* If PSR-related error handled, Main link may be off,
+        * so do not handle as a normal sink status change interrupt.
+        */
+@@ -449,8 +454,10 @@ bool dp_handle_hpd_rx_irq(struct dc_link
+        * If we got sink count changed it means
+        * Downstream port status changed,
+        * then DM should call DC to do the detection.
++       * NOTE: Do not handle link loss on eDP since it is internal link
+        */
+-      if (dp_parse_link_loss_status(
++      if ((link->connector_signal != SIGNAL_TYPE_EDP) &&
++                      dp_parse_link_loss_status(
+                                       link,
+                                       &hpd_irq_dpcd_data)) {
+               /* Connectivity log: link loss */
+@@ -459,11 +466,6 @@ bool dp_handle_hpd_rx_irq(struct dc_link
+                                       sizeof(hpd_irq_dpcd_data),
+                                       "Status: ");
+-              if (link->psr_settings.psr_feature_enabled)
+-                      edp_set_psr_allow_active(link, &allow_active, true, false, NULL);
+-              else if (link->replay_settings.replay_allow_active)
+-                      edp_set_replay_allow_active(link, &allow_active, true, false, NULL);
+-
+               if (defer_handling && has_left_work)
+                       *has_left_work = true;
+               else
+@@ -476,14 +478,6 @@ bool dp_handle_hpd_rx_irq(struct dc_link
+               dp_trace_link_loss_increment(link);
+       }
+-      if (*out_link_loss == false) {
+-              if (handle_hpd_irq_psr_sink(link))
+-                      /* PSR-related error was detected and handled */
+-                      return true;
+-
+-              handle_hpd_irq_replay_sink(link);
+-      }
+-
+       if (link->type == dc_connection_sst_branch &&
+               hpd_irq_dpcd_data.bytes.sink_cnt.bits.SINK_COUNT
+                       != link->dpcd_sink_count)
index e800e63a9cabfe91454e70629f182edd9ffc0c1b..ff0e2d1bf8feff71f66b5c3b4fb43a8be7b25e96 100644 (file)
@@ -248,3 +248,5 @@ drm-radeon-remove-__counted_by-from-statearray.states.patch
 mptcp-fully-established-after-add_addr-echo-on-mpj.patch
 mptcp-pm-deny-endp-with-signal-subflow-port.patch
 block-use-the-right-type-for-stub-rq_integrity_vec.patch
+revert-drm-amd-display-handle-hpd_irq-for-internal-link.patch
+revert-drm-amd-display-add-null-check-for-afb-before-dereferencing-in-amdgpu_dm_plane_handle_cursor_update.patch