<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/gpu/drm/display, branch v6.1.186</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.1.186</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.1.186'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2026-08-19T15:16:21+00:00</updated>
<entry>
<title>drm/dp: Read the PCON max FRL bandwidth only for HDMI DFPs</title>
<updated>2026-08-19T15:16:21+00:00</updated>
<author>
<name>Alexander Kaplan</name>
<email>alexander.kaplan@sms-medipool.de</email>
</author>
<published>2026-06-10T19:38:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=618d6ad5c069c3c55b917d55bb104ed8d7c92deb'/>
<id>urn:sha1:618d6ad5c069c3c55b917d55bb104ed8d7c92deb</id>
<content type='text'>
commit e40e20ac089e32f1d910636155dc82e61e61dcf3 upstream.

The PCON max FRL bandwidth field lives in byte 2 of the DFP Detailed
Capability Info (DPCD 0x82 for the first DFP).
The DP standard defines the meaning of descriptor bytes 1-3 strictly
per DFP type, and for a DisplayPort type DFP all of them are
reserved, with "read all 0s" semantics (DP v2.0, section 2.12.3,
Table 2-183).
The FRL bandwidth field is an HDMI DFP extension added by the VESA
DP-to-HDMI PCON specification.
drm_dp_get_pcon_max_frl_bw() however parses the byte without checking
the DFP type, the branch presence or DETAILED_CAP_INFO_AVAILABLE.
Without the latter the port descriptors are one byte wide and
port_cap[2] is not even the right register.

All neighbouring helpers parsing the same descriptor are scoped by
the DFP type already, see for instance drm_dp_downstream_max_bpc()
reading the same byte and returning 0 for a DP type DFP.
amdgpu's DC parses the field only for HDMI(/DP++) detailed types as
well.

This is not theoretical.
A Synaptics VMM7100 based USB-C to HDMI adapter with a macOS targeted
firmware advertises a DisplayPort type DFP with the type byte
replicated across the whole descriptor (08 08 08 08).
i915 decodes that as "PCON limited to 18 Gbps FRL" and prunes every
mode above ~750 MHz dotclock, including all the 4k@100/120 modes the
sink EDID offers, while macOS drives 4k@120 through the same adapter
just fine via DP DSC (and amdgpu's type-scoped parser would ignore
the bogus field as well).

Only parse the field for an HDMI DFP behind a DPCD 1.1+ branch
device that reports detailed cap info, matching the type-scoped
field layout of the spec and the rest of the helpers.

Fixes: ce32a6239de6 ("drm/dp_helper: Add Helpers for FRL Link Training support for DP-HDMI2.1 PCON")
Cc: Ankit Nautiyal &lt;ankit.k.nautiyal@intel.com&gt;
Cc: Uma Shankar &lt;uma.shankar@intel.com&gt; (v2)
Cc: Jani Nikula &lt;jani.nikula@intel.com&gt;
Cc: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Cc: dri-devel@lists.freedesktop.org
Cc: &lt;stable@vger.kernel.org&gt; # v5.12+
Signed-off-by: Alexander Kaplan &lt;alexander.kaplan@sms-medipool.de&gt;
Reviewed-by: Ankit Nautiyal &lt;ankit.k.nautiyal@intel.com&gt;
Signed-off-by: Ankit Nautiyal &lt;ankit.k.nautiyal@intel.com&gt;
Link: https://patch.msgid.link/20260610193825.2933-1-alexander.kaplan@sms-medipool.de
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/dp/mst: fix OOB reads on 2-byte fields in sideband reply parsers</title>
<updated>2026-08-19T15:16:02+00:00</updated>
<author>
<name>Ashutosh Desai</name>
<email>ashutoshdesai993@gmail.com</email>
</author>
<published>2026-05-10T20:31:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6e3107e6522109a07fc9bb0fc4ec463f1982e113'/>
<id>urn:sha1:6e3107e6522109a07fc9bb0fc4ec463f1982e113</id>
<content type='text'>
commit 6b89ba3dba2f583626fb693e47e951ffb8bf591f upstream.

Three sideband reply parsers read 16-bit fields as:

  val = (raw-&gt;msg[idx] &lt;&lt; 8) | (raw-&gt;msg[idx+1]);

and check bounds only after the fact. When idx == raw-&gt;curlen,
raw-&gt;msg[idx+1] reads one byte past the received message data into
the following struct fields (curchunk_len, curchunk_idx, curlen).

Affected functions:
 - drm_dp_sideband_parse_enum_path_resources_ack()
   full_payload_bw_number and avail_payload_bw_number fields
 - drm_dp_sideband_parse_allocate_payload_ack()
   allocated_pbn field
 - drm_dp_sideband_parse_query_payload_ack()
   allocated_pbn field

Fix by using a single combined check (idx + 2 &gt; curlen) before each
2-byte read. Since the check is strictly tighter than idx &gt; curlen,
no separate step is needed.

Fixes: ad7f8a1f9ced ("drm/helper: add Displayport multi-stream helper (v0.6)")
Cc: &lt;stable@vger.kernel.org&gt; # v3.17+
Signed-off-by: Ashutosh Desai &lt;ashutoshdesai993@gmail.com&gt;
Reviewed-by: Lyude Paul &lt;lyude@redhat.com&gt;
[added fixes tag]
Signed-off-by: Lyude Paul &lt;lyude@redhat.com&gt;
Link: https://patch.msgid.link/20260510203128.2884846-1-ashutoshdesai993@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/dp/mst: fix buffer overflows in sideband chunk accumulation</title>
<updated>2026-08-19T15:16:02+00:00</updated>
<author>
<name>Ashutosh Desai</name>
<email>ashutoshdesai993@gmail.com</email>
</author>
<published>2026-04-10T04:19:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4d5109075a787de28c9e89940f9dee45269f91fa'/>
<id>urn:sha1:4d5109075a787de28c9e89940f9dee45269f91fa</id>
<content type='text'>
commit 55bd5e685bda455b9b50c835f8c8442d52a344a3 upstream.

drm_dp_sideband_append_payload() has three related bugs when processing
device-provided sideband reply data:

1. Zero-length curchunk_len underflow: msg_len is a 6-bit field taken
   directly from the DP sideband header. If a device sends msg_len=0,
   curchunk_len is set to zero. The condition (curchunk_idx &gt;= curchunk_len)
   is immediately true, and curchunk_len-1 wraps to 255 (u8 underflow).
   drm_dp_msg_data_crc4() reads 255 bytes from chunk[48], then memcpy()
   writes 255 bytes into msg[], both far out of bounds.

2. chunk[48] overflow: curchunk_len can reach 63 (6-bit field). chunk[] is
   only 48 bytes. Multi-iteration payload assembly appends 16-byte blocks
   until curchunk_idx reaches curchunk_len, writing up to 15 bytes past
   the end of chunk[] into msg[].

3. msg[256] overflow: each chunk contributes (curchunk_len-1) bytes to
   msg[]. No check ensures curlen + (curchunk_len-1) stays within msg[256],
   so the memcpy can spill into adjacent struct fields.

All three are reachable from any DP MST device that can forge sideband
reply messages on a physical connection.

Fixes: ad7f8a1f9ced ("drm/helper: add Displayport multi-stream helper (v0.6)")
Cc: &lt;stable@vger.kernel.org&gt; # v3.17+
Signed-off-by: Ashutosh Desai &lt;ashutoshdesai993@gmail.com&gt;
Reviewed-by: Lyude Paul &lt;lyude@redhat.com&gt;
Signed-off-by: Lyude Paul &lt;lyude@redhat.com&gt;
Link: https://patch.msgid.link/20260410041901.2438960-1-ashutoshdesai993@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/dp/mst: fix OOB reads in remote DPCD/I2C sideband reply parsers</title>
<updated>2026-08-19T15:16:02+00:00</updated>
<author>
<name>Ashutosh Desai</name>
<email>ashutoshdesai993@gmail.com</email>
</author>
<published>2026-05-10T20:17:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c2fbda0fe0163c55ba3820ee6cea0c6b43622eda'/>
<id>urn:sha1:c2fbda0fe0163c55ba3820ee6cea0c6b43622eda</id>
<content type='text'>
commit 1a8f537f5a1eeac941f262fe73078d6b08ba83c0 upstream.

drm_dp_sideband_parse_remote_dpcd_read() reads num_bytes from the raw
message and then unconditionally does:

  memcpy(bytes, &amp;raw-&gt;msg[idx], num_bytes);

without checking that idx + num_bytes &lt;= raw-&gt;curlen. raw-&gt;msg[] is
256 bytes; if a malicious or misbehaving MST hub sets num_bytes larger
than the remaining payload, the memcpy reads past the received data
into whatever follows in raw-&gt;msg[].

drm_dp_sideband_parse_remote_i2c_read_ack() has the same flaw (noted
with a /* TODO check */ comment since the code was introduced).

Fix both functions by using a single combined check
(idx + num_bytes &gt; curlen) before each memcpy. Since num_bytes is u8,
it is always &gt;= 0, so this strictly subsumes the simpler idx &gt; curlen
form and no separate step is needed.

Fixes: ad7f8a1f9ced ("drm/helper: add Displayport multi-stream helper (v0.6)")
Cc: &lt;stable@vger.kernel.org&gt; # v3.17+
Signed-off-by: Ashutosh Desai &lt;ashutoshdesai993@gmail.com&gt;
Reviewed-by: Lyude Paul &lt;lyude@redhat.com&gt;
[added missing fixes tag]
Signed-off-by: Lyude Paul &lt;lyude@redhat.com&gt;
Link: https://patch.msgid.link/20260510201733.2882224-1-ashutoshdesai993@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/display/dp_mst: Add protection against 0 vcpi</title>
<updated>2026-03-04T12:20:18+00:00</updated>
<author>
<name>Suraj Kandpal</name>
<email>suraj.kandpal@intel.com</email>
</author>
<published>2025-11-19T09:46:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=95dbd525efce2a9e9e1c50ad15213de644c85ad0'/>
<id>urn:sha1:95dbd525efce2a9e9e1c50ad15213de644c85ad0</id>
<content type='text'>
[ Upstream commit 342ccffd9f77fc29fe1c05fd145e4d842bd2feaa ]

When releasing a timeslot there is a slight chance we may end up
with the wrong payload mask due to overflow if the delayed_destroy_work
ends up coming into play after a DP 2.1 monitor gets disconnected
which causes vcpi to become 0 then we try to make the payload =
~BIT(vcpi - 1) which is a negative shift. VCPI id should never
really be 0 hence skip changing the payload mask if VCPI is 0.

Otherwise it leads to
&lt;7&gt; [515.287237] xe 0000:03:00.0: [drm:drm_dp_mst_get_port_malloc
[drm_display_helper]] port ffff888126ce9000 (3)
&lt;4&gt; [515.287267] -----------[ cut here ]-----------
&lt;3&gt; [515.287268] UBSAN: shift-out-of-bounds in
../drivers/gpu/drm/display/drm_dp_mst_topology.c:4575:36
&lt;3&gt; [515.287271] shift exponent -1 is negative
&lt;4&gt; [515.287275] CPU: 7 UID: 0 PID: 3108 Comm: kworker/u64:33 Tainted: G
S U 6.17.0-rc6-lgci-xe-xe-3795-3e79699fa1b216e92+ #1 PREEMPT(voluntary)
&lt;4&gt; [515.287279] Tainted: [S]=CPU_OUT_OF_SPEC, [U]=USER
&lt;4&gt; [515.287279] Hardware name: ASUS System Product Name/PRIME Z790-P
WIFI, BIOS 1645 03/15/2024
&lt;4&gt; [515.287281] Workqueue: drm_dp_mst_wq drm_dp_delayed_destroy_work
[drm_display_helper]
&lt;4&gt; [515.287303] Call Trace:
&lt;4&gt; [515.287304] &lt;TASK&gt;
&lt;4&gt; [515.287306] dump_stack_lvl+0xc1/0xf0
&lt;4&gt; [515.287313] dump_stack+0x10/0x20
&lt;4&gt; [515.287316] __ubsan_handle_shift_out_of_bounds+0x133/0x2e0
&lt;4&gt; [515.287324] ? drm_atomic_get_private_obj_state+0x186/0x1d0
&lt;4&gt; [515.287333] drm_dp_atomic_release_time_slots.cold+0x17/0x3d
[drm_display_helper]
&lt;4&gt; [515.287355] mst_connector_atomic_check+0x159/0x180 [xe]
&lt;4&gt; [515.287546] drm_atomic_helper_check_modeset+0x4d9/0xfa0
&lt;4&gt; [515.287550] ? __ww_mutex_lock.constprop.0+0x6f/0x1a60
&lt;4&gt; [515.287562] intel_atomic_check+0x119/0x2b80 [xe]
&lt;4&gt; [515.287740] ? find_held_lock+0x31/0x90
&lt;4&gt; [515.287747] ? lock_release+0xce/0x2a0
&lt;4&gt; [515.287754] drm_atomic_check_only+0x6a2/0xb40
&lt;4&gt; [515.287758] ? drm_atomic_add_affected_connectors+0x12b/0x140
&lt;4&gt; [515.287765] drm_atomic_commit+0x6e/0xf0
&lt;4&gt; [515.287766] ? _pfx__drm_printfn_info+0x10/0x10
&lt;4&gt; [515.287774] drm_client_modeset_commit_atomic+0x25c/0x2b0
&lt;4&gt; [515.287794] drm_client_modeset_commit_locked+0x60/0x1b0
&lt;4&gt; [515.287795] ? mutex_lock_nested+0x1b/0x30
&lt;4&gt; [515.287801] drm_client_modeset_commit+0x26/0x50
&lt;4&gt; [515.287804] __drm_fb_helper_restore_fbdev_mode_unlocked+0xdc/0x110
&lt;4&gt; [515.287810] drm_fb_helper_hotplug_event+0x120/0x140
&lt;4&gt; [515.287814] drm_fbdev_client_hotplug+0x28/0xd0
&lt;4&gt; [515.287819] drm_client_hotplug+0x6c/0xf0
&lt;4&gt; [515.287824] drm_client_dev_hotplug+0x9e/0xd0
&lt;4&gt; [515.287829] drm_kms_helper_hotplug_event+0x1a/0x30
&lt;4&gt; [515.287834] drm_dp_delayed_destroy_work+0x3df/0x410
[drm_display_helper]
&lt;4&gt; [515.287861] process_one_work+0x22b/0x6f0
&lt;4&gt; [515.287874] worker_thread+0x1e8/0x3d0
&lt;4&gt; [515.287879] ? __pfx_worker_thread+0x10/0x10
&lt;4&gt; [515.287882] kthread+0x11c/0x250
&lt;4&gt; [515.287886] ? __pfx_kthread+0x10/0x10
&lt;4&gt; [515.287890] ret_from_fork+0x2d7/0x310
&lt;4&gt; [515.287894] ? __pfx_kthread+0x10/0x10
&lt;4&gt; [515.287897] ret_from_fork_asm+0x1a/0x30

Closes: https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/6303
Signed-off-by: Suraj Kandpal &lt;suraj.kandpal@intel.com&gt;
Reviewed-by: Imre Deak &lt;imre.deak@intel.com&gt;
Reviewed-by: Lyude Paul &lt;lyude@redhat.com&gt;
Link: https://patch.msgid.link/20251119094650.799135-1-suraj.kandpal@intel.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>Revert "drm/dp: Change AUX DPCD probe address from DPCD_REV to LANE0_1_STATUS"</title>
<updated>2025-09-04T13:26:31+00:00</updated>
<author>
<name>Imre Deak</name>
<email>imre.deak@intel.com</email>
</author>
<published>2025-08-28T17:49:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6f06f45a18edfcdadaf7364b160d0a97360b2455'/>
<id>urn:sha1:6f06f45a18edfcdadaf7364b160d0a97360b2455</id>
<content type='text'>
This reverts commit 4f546a77671076a0a49c08b4c6a7d0888d72f7d2 which is
commit a40c5d727b8111b5db424a1e43e14a1dcce1e77f upstream.

The upstream commit a40c5d727b8111b5db424a1e43e14a1dcce1e77f ("drm/dp:
Change AUX DPCD probe address from DPCD_REV to LANE0_1_STATUS") the
reverted commit backported causes a regression, on one eDP panel at
least resulting in display flickering, described in detail at the Link:
below. The issue fixed by the upstream commit will need a different
solution, revert the backport for now.

Cc: intel-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Cc: Sasha Levin &lt;sashal@kernel.org&gt;
Link: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/14558
Signed-off-by: Imre Deak &lt;imre.deak@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/dp: Change AUX DPCD probe address from DPCD_REV to LANE0_1_STATUS</title>
<updated>2025-08-28T14:26:16+00:00</updated>
<author>
<name>Imre Deak</name>
<email>imre.deak@intel.com</email>
</author>
<published>2025-08-23T13:16:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4f546a77671076a0a49c08b4c6a7d0888d72f7d2'/>
<id>urn:sha1:4f546a77671076a0a49c08b4c6a7d0888d72f7d2</id>
<content type='text'>
[ Upstream commit a40c5d727b8111b5db424a1e43e14a1dcce1e77f ]

Reading DPCD registers has side-effects in general. In particular
accessing registers outside of the link training register range
(0x102-0x106, 0x202-0x207, 0x200c-0x200f, 0x2216) is explicitly
forbidden by the DP v2.1 Standard, see

3.6.5.1 DPTX AUX Transaction Handling Mandates
3.6.7.4 128b/132b DP Link Layer LTTPR Link Training Mandates

Based on my tests, accessing the DPCD_REV register during the link
training of an UHBR TBT DP tunnel sink leads to link training failures.

Solve the above by using the DP_LANE0_1_STATUS (0x202) register for the
DPCD register access quirk.

Cc: &lt;stable@vger.kernel.org&gt;
Cc: Ville Syrjälä &lt;ville.syrjala@linux.intel.com&gt;
Cc: Jani Nikula &lt;jani.nikula@linux.intel.com&gt;
Acked-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
Signed-off-by: Imre Deak &lt;imre.deak@intel.com&gt;
Link: https://lore.kernel.org/r/20250605082850.65136-2-imre.deak@intel.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>drm/dp_mst: Fix drm RAD print</title>
<updated>2025-04-10T12:33:32+00:00</updated>
<author>
<name>Wayne Lin</name>
<email>Wayne.Lin@amd.com</email>
</author>
<published>2025-01-13T09:10:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=21daa13f7b643228703b56d029064ed72c04f116'/>
<id>urn:sha1:21daa13f7b643228703b56d029064ed72c04f116</id>
<content type='text'>
[ Upstream commit 6bbce873a9c97cb12f5455c497be279ac58e707f ]

[Why]
The RAD of sideband message printed today is incorrect.
For RAD stored within MST branch
- If MST branch LCT is 1, it's RAD array is untouched and remained as 0.
- If MST branch LCT is larger than 1, use nibble to store the up facing
  port number in cascaded sequence as illustrated below:

  u8 RAD[0] = (LCT_2_UFP &lt;&lt; 4) | LCT_3_UFP
     RAD[1] = (LCT_4_UFP &lt;&lt; 4) | LCT_5_UFP
     ...

In drm_dp_mst_rad_to_str(), it wrongly to use BIT_MASK(4) to fetch the port
number of one nibble.

[How]
Adjust the code by:
- RAD array items are valuable only for LCT &gt;= 1.
- Use 0xF as the mask to replace BIT_MASK(4)

V2:
- Document how RAD is constructed (Imre)

V3:
- Adjust the comment for rad[] so kdoc formats it properly (Lyude)

Fixes: 2f015ec6eab6 ("drm/dp_mst: Add sideband down request tracing + selftests")
Cc: Imre Deak &lt;imre.deak@intel.com&gt;
Cc: Ville Syrjälä &lt;ville.syrjala@linux.intel.com&gt;
Cc: Harry Wentland &lt;hwentlan@amd.com&gt;
Cc: Lyude Paul &lt;lyude@redhat.com&gt;
Reviewed-by: Lyude Paul &lt;lyude@redhat.com&gt;
Signed-off-by: Wayne Lin &lt;Wayne.Lin@amd.com&gt;
Signed-off-by: Lyude Paul &lt;lyude@redhat.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20250113091100.3314533-2-Wayne.Lin@amd.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>drm/dp_mst: Fix locking when skipping CSN before topology probing</title>
<updated>2025-03-28T20:58:56+00:00</updated>
<author>
<name>Imre Deak</name>
<email>imre.deak@intel.com</email>
</author>
<published>2025-03-07T18:31:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e8aeee0d12ac23903063ec7f200c5a1f1784e86d'/>
<id>urn:sha1:e8aeee0d12ac23903063ec7f200c5a1f1784e86d</id>
<content type='text'>
commit 12d8f318347b1d4feac48e8ac351d3786af39599 upstream.

The handling of the MST Connection Status Notify message is skipped if
the probing of the topology is still pending. Acquiring the
drm_dp_mst_topology_mgr::probe_lock for this in
drm_dp_mst_handle_up_req() is problematic: the task/work this function
is called from is also responsible for handling MST down-request replies
(in drm_dp_mst_handle_down_rep()). Thus drm_dp_mst_link_probe_work() -
holding already probe_lock - could be blocked waiting for an MST
down-request reply while drm_dp_mst_handle_up_req() is waiting for
probe_lock while processing a CSN message. This leads to the probe
work's down-request message timing out.

A scenario similar to the above leading to a down-request timeout is
handling a CSN message in drm_dp_mst_handle_conn_stat(), holding the
probe_lock and sending down-request messages while a second CSN message
sent by the sink subsequently is handled by drm_dp_mst_handle_up_req().

Fix the above by moving the logic to skip the CSN handling to
drm_dp_mst_process_up_req(). This function is called from a work
(separate from the task/work handling new up/down messages), already
holding probe_lock. This solves the above timeout issue, since handling
of down-request replies won't be blocked by probe_lock.

Fixes: ddf983488c3e ("drm/dp_mst: Skip CSN if topology probing is not done yet")
Cc: Wayne Lin &lt;Wayne.Lin@amd.com&gt;
Cc: Lyude Paul &lt;lyude@redhat.com&gt;
Cc: stable@vger.kernel.org # v6.6+
Reviewed-by: Wayne Lin &lt;Wayne.Lin@amd.com&gt;
Reviewed-by: Lyude Paul &lt;lyude@redhat.com&gt;
Signed-off-by: Imre Deak &lt;imre.deak@intel.com&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20250307183152.3822170-1-imre.deak@intel.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>gpu: drm_dp_cec: fix broken CEC adapter properties check</title>
<updated>2025-02-21T12:49:36+00:00</updated>
<author>
<name>Hans Verkuil</name>
<email>hverkuil@xs4all.nl</email>
</author>
<published>2025-01-29T09:51:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f8f7d4d16f2c461daafcf09e9b88b90e0439375d'/>
<id>urn:sha1:f8f7d4d16f2c461daafcf09e9b88b90e0439375d</id>
<content type='text'>
[ Upstream commit 6daaae5ff7f3b23a2dacc9c387ff3d4f95b67cad ]

If the hotplug detect of a display is low for longer than one second
(configurable through drm_dp_cec_unregister_delay), then the CEC adapter
is unregistered since we assume the display was disconnected. If the
HPD went low for less than one second, then we check if the properties
of the CEC adapter have changed, since that indicates that we actually
switch to new hardware and we have to unregister the old CEC device and
register a new one.

Unfortunately, the test for changed properties was written poorly, and
after a new CEC capability was added to the CEC core code the test always
returned true (i.e. the properties had changed).

As a result the CEC device was unregistered and re-registered for every
HPD toggle. If the CEC remote controller integration was also enabled
(CONFIG_MEDIA_CEC_RC was set), then the corresponding input device was
also unregistered and re-registered. As a result the input device in
/sys would keep incrementing its number, e.g.:

/sys/devices/pci0000:00/0000:00:08.1/0000:e7:00.0/rc/rc0/input20

Since short HPD toggles are common, the number could over time get into
the thousands.

While not a serious issue (i.e. nothing crashes), it is not intended
to work that way.

This patch changes the test so that it only checks for the single CEC
capability that can actually change, and it ignores any other
capabilities, so this is now safe as well if new caps are added in
the future.

With the changed test the bit under #ifndef CONFIG_MEDIA_CEC_RC can be
dropped as well, so that's a nice cleanup.

Signed-off-by: Hans Verkuil &lt;hverkuil@xs4all.nl&gt;
Reported-by: Farblos &lt;farblos@vodafonemail.de&gt;
Reviewed-by: Dmitry Baryshkov &lt;dmitry.baryshkov@linaro.org&gt;
Fixes: 2c6d1fffa1d9 ("drm: add support for DisplayPort CEC-Tunneling-over-AUX")
Tested-by: Farblos &lt;farblos@vodafonemail.de&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/361bb03d-1691-4e23-84da-0861ead5dbdc@xs4all.nl
Signed-off-by: Dmitry Baryshkov &lt;dmitry.baryshkov@linaro.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
</feed>
