]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
5.10-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 11:41:30 +0000 (12:41 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 11:41:30 +0000 (12:41 +0100)
added patches:
drm-display-dp_mst-fix-down-message-handling-after-a-packet-reception-error.patch
drm-display-dp_mst-fix-down-up-message-handling-after-sink-disconnect.patch

queue-5.10/drm-display-dp_mst-fix-down-message-handling-after-a-packet-reception-error.patch [new file with mode: 0644]
queue-5.10/drm-display-dp_mst-fix-down-up-message-handling-after-sink-disconnect.patch [new file with mode: 0644]
queue-5.10/series

diff --git a/queue-5.10/drm-display-dp_mst-fix-down-message-handling-after-a-packet-reception-error.patch b/queue-5.10/drm-display-dp_mst-fix-down-message-handling-after-a-packet-reception-error.patch
new file mode 100644 (file)
index 0000000..bec9dba
--- /dev/null
@@ -0,0 +1,38 @@
+From 1241aedb6b5c7a5a8ad73e5eb3a41cfe18a3e00e Mon Sep 17 00:00:00 2001
+From: Imre Deak <imre.deak@intel.com>
+Date: Wed, 14 Dec 2022 20:42:57 +0200
+Subject: drm/display/dp_mst: Fix down message handling after a packet reception error
+
+From: Imre Deak <imre.deak@intel.com>
+
+commit 1241aedb6b5c7a5a8ad73e5eb3a41cfe18a3e00e upstream.
+
+After an error during receiving a packet for a multi-packet DP MST
+sideband message, the state tracking which packets have been received
+already is not reset. This prevents the reception of subsequent down
+messages (due to the pending message not yet completed with an
+end-of-message-transfer packet).
+
+Fix the above by resetting the reception state after a packet error.
+
+Cc: Lyude Paul <lyude@redhat.com>
+Cc: <stable@vger.kernel.org> # v3.17+
+Signed-off-by: Imre Deak <imre.deak@intel.com>
+Reviewed-by: Lyude Paul <lyude@redhat.com>
+Link: https://patchwork.freedesktop.org/patch/msgid/20221214184258.2869417-2-imre.deak@intel.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/gpu/drm/drm_dp_mst_topology.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/gpu/drm/drm_dp_mst_topology.c
++++ b/drivers/gpu/drm/drm_dp_mst_topology.c
+@@ -3988,7 +3988,7 @@ static int drm_dp_mst_handle_down_rep(st
+       struct drm_dp_sideband_msg_rx *msg = &mgr->down_rep_recv;
+       if (!drm_dp_get_one_sb_msg(mgr, false, &mstb))
+-              goto out;
++              goto out_clear_reply;
+       /* Multi-packet message transmission, don't clear the reply */
+       if (!msg->have_eomt)
diff --git a/queue-5.10/drm-display-dp_mst-fix-down-up-message-handling-after-sink-disconnect.patch b/queue-5.10/drm-display-dp_mst-fix-down-up-message-handling-after-sink-disconnect.patch
new file mode 100644 (file)
index 0000000..b6d56b2
--- /dev/null
@@ -0,0 +1,45 @@
+From 1d082618bbf3b6755b8cc68c0a8122af2842d593 Mon Sep 17 00:00:00 2001
+From: Imre Deak <imre.deak@intel.com>
+Date: Wed, 14 Dec 2022 20:42:56 +0200
+Subject: drm/display/dp_mst: Fix down/up message handling after sink disconnect
+
+From: Imre Deak <imre.deak@intel.com>
+
+commit 1d082618bbf3b6755b8cc68c0a8122af2842d593 upstream.
+
+If the sink gets disconnected during receiving a multi-packet DP MST AUX
+down-reply/up-request sideband message, the state keeping track of which
+packets have been received already is not reset. This results in a failed
+sanity check for the subsequent message packet received after a sink is
+reconnected (due to the pending message not yet completed with an
+end-of-message-transfer packet), indicated by the
+
+"sideband msg set header failed"
+
+error.
+
+Fix the above by resetting the up/down message reception state after a
+disconnect event.
+
+Cc: Lyude Paul <lyude@redhat.com>
+Cc: <stable@vger.kernel.org> # v3.17+
+Signed-off-by: Imre Deak <imre.deak@intel.com>
+Reviewed-by: Lyude Paul <lyude@redhat.com>
+Link: https://patchwork.freedesktop.org/patch/msgid/20221214184258.2869417-1-imre.deak@intel.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/gpu/drm/drm_dp_mst_topology.c |    3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/drivers/gpu/drm/drm_dp_mst_topology.c
++++ b/drivers/gpu/drm/drm_dp_mst_topology.c
+@@ -3769,6 +3769,9 @@ int drm_dp_mst_topology_mgr_set_mst(stru
+               set_bit(0, &mgr->payload_mask);
+               mgr->vcpi_mask = 0;
+               mgr->payload_id_table_cleared = false;
++
++              memset(&mgr->down_rep_recv, 0, sizeof(mgr->down_rep_recv));
++              memset(&mgr->up_req_recv, 0, sizeof(mgr->up_req_recv));
+       }
+ out_unlock:
index 360d094b9ae88f5f3c8de6c94ae6dbb8d46b8155..67c184f3884e57dd592e0905ac64da4f2a47cfe0 100644 (file)
@@ -513,3 +513,5 @@ soundwire-cadence-drain-the-rx-fifo-after-an-io-time.patch
 net-tls-avoid-hanging-tasks-on-the-tx_lock.patch
 x86-resctrl-apply-read_once-write_once-to-task_struct.-rmid-closid.patch
 x86-resctl-fix-scheduler-confusion-with-current.patch
+drm-display-dp_mst-fix-down-up-message-handling-after-sink-disconnect.patch
+drm-display-dp_mst-fix-down-message-handling-after-a-packet-reception-error.patch