<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-stable.git/drivers/rpmsg, branch master</title>
<subtitle>Linux kernel stable tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/'/>
<entry>
<title>rpmsg: glink: smem: order FIFO read after availability check</title>
<updated>2026-07-14T03:11:52+00:00</updated>
<author>
<name>Chunkai Deng</name>
<email>chunkai.deng@oss.qualcomm.com</email>
</author>
<published>2026-06-18T07:16:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=786439ad58763e04b91bc2ec5f590e463939f197'/>
<id>786439ad58763e04b91bc2ec5f590e463939f197</id>
<content type='text'>
glink_smem_rx_peek() reads the RX FIFO payload after the caller has
determined data is available via glink_smem_rx_avail(), which reads the
remote-updated head index. A control dependency between the head read
and the subsequent payload read does not order the two loads, so the
CPU may speculatively read the FIFO before observing the head update
and consume stale data the remote has not yet published.

Add rmb() in glink_smem_rx_peek() before the memcpy_fromio() so the
availability (head) read is ordered ahead of the FIFO payload read,
matching the consumer pattern in
Documentation/core-api/circular-buffers.rst.

Fixes: caf989c350e8 ("rpmsg: glink: Introduce glink smem based transport")
Cc: stable@vger.kernel.org
Signed-off-by: Chunkai Deng &lt;chunkai.deng@oss.qualcomm.com&gt;
Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260618-rpmsg-glink-smem-mb-v1-1-68a026453a69@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
glink_smem_rx_peek() reads the RX FIFO payload after the caller has
determined data is available via glink_smem_rx_avail(), which reads the
remote-updated head index. A control dependency between the head read
and the subsequent payload read does not order the two loads, so the
CPU may speculatively read the FIFO before observing the head update
and consume stale data the remote has not yet published.

Add rmb() in glink_smem_rx_peek() before the memcpy_fromio() so the
availability (head) read is ordered ahead of the FIFO payload read,
matching the consumer pattern in
Documentation/core-api/circular-buffers.rst.

Fixes: caf989c350e8 ("rpmsg: glink: Introduce glink smem based transport")
Cc: stable@vger.kernel.org
Signed-off-by: Chunkai Deng &lt;chunkai.deng@oss.qualcomm.com&gt;
Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260618-rpmsg-glink-smem-mb-v1-1-68a026453a69@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: glink: fix deadlock in endpoint destroy during driver detach</title>
<updated>2026-07-14T02:55:29+00:00</updated>
<author>
<name>Vishnu Santhosh</name>
<email>vishnu.santhosh@oss.qualcomm.com</email>
</author>
<published>2026-06-04T08:42:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=5a5a48e788e02fd8a8eb7188ce440572d6c12418'/>
<id>5a5a48e788e02fd8a8eb7188ce440572d6c12418</id>
<content type='text'>
During driver detach, the device core holds the device mutex throughout
the driver's remove callback chain.  When the rpmsg endpoint is
destroyed as part of that teardown, the GLINK endpoint destroy
implementation attempts to unregister the underlying rpmsg device.
That unregistration calls device_del(), which tries to re-acquire the
same device mutex already held higher up the stack, causing rmmod to
hang indefinitely.

The deadlock manifests with the following call chain:

[&lt;0&gt;] device_del+0x44/0x414  &lt;- tries to acquire same mutex
[&lt;0&gt;] device_unregister+0x18/0x34
[&lt;0&gt;] rpmsg_unregister_device+0x28/0x4c
[&lt;0&gt;] qcom_glink_remove_rpmsg_device+0x70/0xc0
[&lt;0&gt;] qcom_glink_destroy_ept+0x58/0xbc
[&lt;0&gt;] rpmsg_dev_remove+0x50/0x60
[&lt;0&gt;] device_remove+0x4c/0x80
[&lt;0&gt;] device_release_driver_internal+0x1cc/0x228  &lt;- acquires device mutex
[&lt;0&gt;] driver_detach+0x4c/0x98
[&lt;0&gt;] bus_remove_driver+0x6c/0xbc
[&lt;0&gt;] driver_unregister+0x30/0x60
[&lt;0&gt;] unregister_rpmsg_driver+0x10/0x1c
[&lt;0&gt;] fastrpc_exit+0x28/0x38 [fastrpc]
[&lt;0&gt;] __arm64_sys_delete_module+0x1b8/0x294
[&lt;0&gt;] invoke_syscall+0x48/0x10c
[&lt;0&gt;] el0_svc_common.constprop.0+0xc0/0xe0
[&lt;0&gt;] do_el0_svc+0x1c/0x28
[&lt;0&gt;] el0_svc+0x34/0x108
[&lt;0&gt;] el0t_64_sync_handler+0xa0/0xe4
[&lt;0&gt;] el0t_64_sync+0x198/0x19c

The rpmsg device unregistration inside endpoint destroy is redundant.
In both contexts where endpoint destruction is triggered:

- Driver detach path: the driver core already tears down the rpmsg
  device.

- Channel close path: the rpmsg device is already unregistered before
  endpoint destruction is reached.

Remove the redundant unregistration to fix the deadlock.

Co-developed-by: Deepak Kumar Singh &lt;deepak.singh@oss.qualcomm.com&gt;
Signed-off-by: Deepak Kumar Singh &lt;deepak.singh@oss.qualcomm.com&gt;
Signed-off-by: Vishnu Santhosh &lt;vishnu.santhosh@oss.qualcomm.com&gt;
Tested-by: Bjorn Andersson &lt;bjorn.andersson@oss.qualcomm.com&gt;
Fixes: a53e356df548 ("rpmsg: glink: fix rpmsg device leak")
Reviewed-by: Dmitry Baryshkov &lt;dmitry.baryshkov@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260604-rpmsg-glink-fix-deadlock-destroy-ept-v1-1-b8a54ad1e4fd@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
During driver detach, the device core holds the device mutex throughout
the driver's remove callback chain.  When the rpmsg endpoint is
destroyed as part of that teardown, the GLINK endpoint destroy
implementation attempts to unregister the underlying rpmsg device.
That unregistration calls device_del(), which tries to re-acquire the
same device mutex already held higher up the stack, causing rmmod to
hang indefinitely.

The deadlock manifests with the following call chain:

[&lt;0&gt;] device_del+0x44/0x414  &lt;- tries to acquire same mutex
[&lt;0&gt;] device_unregister+0x18/0x34
[&lt;0&gt;] rpmsg_unregister_device+0x28/0x4c
[&lt;0&gt;] qcom_glink_remove_rpmsg_device+0x70/0xc0
[&lt;0&gt;] qcom_glink_destroy_ept+0x58/0xbc
[&lt;0&gt;] rpmsg_dev_remove+0x50/0x60
[&lt;0&gt;] device_remove+0x4c/0x80
[&lt;0&gt;] device_release_driver_internal+0x1cc/0x228  &lt;- acquires device mutex
[&lt;0&gt;] driver_detach+0x4c/0x98
[&lt;0&gt;] bus_remove_driver+0x6c/0xbc
[&lt;0&gt;] driver_unregister+0x30/0x60
[&lt;0&gt;] unregister_rpmsg_driver+0x10/0x1c
[&lt;0&gt;] fastrpc_exit+0x28/0x38 [fastrpc]
[&lt;0&gt;] __arm64_sys_delete_module+0x1b8/0x294
[&lt;0&gt;] invoke_syscall+0x48/0x10c
[&lt;0&gt;] el0_svc_common.constprop.0+0xc0/0xe0
[&lt;0&gt;] do_el0_svc+0x1c/0x28
[&lt;0&gt;] el0_svc+0x34/0x108
[&lt;0&gt;] el0t_64_sync_handler+0xa0/0xe4
[&lt;0&gt;] el0t_64_sync+0x198/0x19c

The rpmsg device unregistration inside endpoint destroy is redundant.
In both contexts where endpoint destruction is triggered:

- Driver detach path: the driver core already tears down the rpmsg
  device.

- Channel close path: the rpmsg device is already unregistered before
  endpoint destruction is reached.

Remove the redundant unregistration to fix the deadlock.

Co-developed-by: Deepak Kumar Singh &lt;deepak.singh@oss.qualcomm.com&gt;
Signed-off-by: Deepak Kumar Singh &lt;deepak.singh@oss.qualcomm.com&gt;
Signed-off-by: Vishnu Santhosh &lt;vishnu.santhosh@oss.qualcomm.com&gt;
Tested-by: Bjorn Andersson &lt;bjorn.andersson@oss.qualcomm.com&gt;
Fixes: a53e356df548 ("rpmsg: glink: fix rpmsg device leak")
Reviewed-by: Dmitry Baryshkov &lt;dmitry.baryshkov@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260604-rpmsg-glink-fix-deadlock-destroy-ept-v1-1-b8a54ad1e4fd@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: char: Check for ongoing chrdev destroy</title>
<updated>2026-07-09T20:11:17+00:00</updated>
<author>
<name>Chris Lew</name>
<email>christopher.lew@oss.qualcomm.com</email>
</author>
<published>2026-04-06T04:29:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=1f9c2897afb0fe86c1fdf4f5e23c5fb8f7442f6d'/>
<id>1f9c2897afb0fe86c1fdf4f5e23c5fb8f7442f6d</id>
<content type='text'>
A null pointer panic is observed when stopping a remoteproc and closing
a character device using the RPMSG_DESTROY_EPT_IOCTL. There is a race
where each context calls rpmsg_chrdev_eptdev_destroy(). The thread that
runs second will call cdev_device_del() for a second time, which fails
because the first call already removed the device from sysfs. Add a
check at the beginning of destroy and exit early if the destroy call
has already been done.

[ 26.654130] Call trace
[ 26.656658] kernfs_find_and_get_ns+0x28/0x8
[ 26.661140] sysfs_unmerge_group+0x2c/0x7
[ 26.665357] dpm_sysfs_remove+0x38/0x8
[ 26.669305] device_del+0xa4/0x3e
[ 26.672811] cdev_device_del+0x28/0x7
[ 26.676675] rpmsg_chrdev_eptdev_destroy+0x68/0x98
[ 26.682765] rpmsg_eptdev_ioctl+0x130/0x11c8
[ 26.688318] __arm64_sys_ioctl+0xb4/0x10
[ 26.692448] invoke_syscall+0x50/0x12
[ 26.696312] el0_svc_common.constprop.0+0xc8/0xf
[ 26.701151] do_el0_svc+0x24/0x3
[ 26.704570] el0_svc+0x40/0x17
[ 26.707810] el0t_64_sync_handler+0x120/0x13
[ 26.712288] el0t_64_sync+0x1a0/0x1a

Signed-off-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Signed-off-by: Vishnu Santhosh &lt;vishnu.santhosh@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260406-rpmsg-char-fix-chrdev-destroy-race-v1-1-7317434fa246@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A null pointer panic is observed when stopping a remoteproc and closing
a character device using the RPMSG_DESTROY_EPT_IOCTL. There is a race
where each context calls rpmsg_chrdev_eptdev_destroy(). The thread that
runs second will call cdev_device_del() for a second time, which fails
because the first call already removed the device from sysfs. Add a
check at the beginning of destroy and exit early if the destroy call
has already been done.

[ 26.654130] Call trace
[ 26.656658] kernfs_find_and_get_ns+0x28/0x8
[ 26.661140] sysfs_unmerge_group+0x2c/0x7
[ 26.665357] dpm_sysfs_remove+0x38/0x8
[ 26.669305] device_del+0xa4/0x3e
[ 26.672811] cdev_device_del+0x28/0x7
[ 26.676675] rpmsg_chrdev_eptdev_destroy+0x68/0x98
[ 26.682765] rpmsg_eptdev_ioctl+0x130/0x11c8
[ 26.688318] __arm64_sys_ioctl+0xb4/0x10
[ 26.692448] invoke_syscall+0x50/0x12
[ 26.696312] el0_svc_common.constprop.0+0xc8/0xf
[ 26.701151] do_el0_svc+0x24/0x3
[ 26.704570] el0_svc+0x40/0x17
[ 26.707810] el0t_64_sync_handler+0x120/0x13
[ 26.712288] el0t_64_sync+0x1a0/0x1a

Signed-off-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Signed-off-by: Vishnu Santhosh &lt;vishnu.santhosh@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260406-rpmsg-char-fix-chrdev-destroy-race-v1-1-7317434fa246@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: glink: Replace strcpy() with strscpy()</title>
<updated>2026-07-09T19:46:45+00:00</updated>
<author>
<name>Sudeepgoud Patil</name>
<email>quic_sudeepgo@quicinc.com</email>
</author>
<published>2025-12-11T08:48:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=ad6d7795388dbfc8a4c8980b49ad43648b1d6efe'/>
<id>ad6d7795388dbfc8a4c8980b49ad43648b1d6efe</id>
<content type='text'>
Replace strcpy() with the safer strscpy() to address unsafe API
usage warnings[1] from static analysis tools, as strcpy() performs
no bounds checking on the destination buffer.

[1] https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy

Signed-off-by: Sudeepgoud Patil &lt;quic_sudeepgo@quicinc.com&gt;
Signed-off-by: Vishnu Santhosh &lt;vishnu.santhosh@oss.qualcomm.com&gt;
Reviewed-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20251211-rpmsg-glink-strcpy-replace-v1-1-be06308e5724@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace strcpy() with the safer strscpy() to address unsafe API
usage warnings[1] from static analysis tools, as strcpy() performs
no bounds checking on the destination buffer.

[1] https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy

Signed-off-by: Sudeepgoud Patil &lt;quic_sudeepgo@quicinc.com&gt;
Signed-off-by: Vishnu Santhosh &lt;vishnu.santhosh@oss.qualcomm.com&gt;
Reviewed-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20251211-rpmsg-glink-strcpy-replace-v1-1-be06308e5724@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: core: Fix incorrect return value documentation</title>
<updated>2026-07-09T19:45:37+00:00</updated>
<author>
<name>Zhongqiu Han</name>
<email>zhongqiu.han@oss.qualcomm.com</email>
</author>
<published>2025-12-17T06:51:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=31a42429e043cde8a94da8872e002781a7068827'/>
<id>31a42429e043cde8a94da8872e002781a7068827</id>
<content type='text'>
The unregister_rpmsg_driver() function has a void return type but the
documentation incorrectly described a return value. Remove the incorrect
return value documentation to match the actual function signature.

Fixes: bcabbccabffe ("rpmsg: add virtio-based remote processor messaging bus")
Signed-off-by: Zhongqiu Han &lt;zhongqiu.han@oss.qualcomm.com&gt;
Reviewed-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20251217065112.18392-3-zhongqiu.han@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The unregister_rpmsg_driver() function has a void return type but the
documentation incorrectly described a return value. Remove the incorrect
return value documentation to match the actual function signature.

Fixes: bcabbccabffe ("rpmsg: add virtio-based remote processor messaging bus")
Signed-off-by: Zhongqiu Han &lt;zhongqiu.han@oss.qualcomm.com&gt;
Reviewed-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20251217065112.18392-3-zhongqiu.han@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: Replace sprintf() with sysfs_emit() in sysfs show</title>
<updated>2026-07-09T19:45:34+00:00</updated>
<author>
<name>Zhongqiu Han</name>
<email>zhongqiu.han@oss.qualcomm.com</email>
</author>
<published>2025-12-17T06:51:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=ef22e806ae3b6728df20b5a6c07aa5a01db38e7b'/>
<id>ef22e806ae3b6728df20b5a6c07aa5a01db38e7b</id>
<content type='text'>
Use sysfs_emit() instead of sprintf() in sysfs attribute show functions.
sysfs_emit() is the recommended API for sysfs output as it provides buffer
overflow protection and proper formatting.

No functional changes.

Signed-off-by: Zhongqiu Han &lt;zhongqiu.han@oss.qualcomm.com&gt;
Reviewed-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20251217065112.18392-2-zhongqiu.han@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use sysfs_emit() instead of sprintf() in sysfs attribute show functions.
sysfs_emit() is the recommended API for sysfs output as it provides buffer
overflow protection and proper formatting.

No functional changes.

Signed-off-by: Zhongqiu Han &lt;zhongqiu.han@oss.qualcomm.com&gt;
Reviewed-by: Chris Lew &lt;christopher.lew@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20251217065112.18392-2-zhongqiu.han@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge tag 'rpmsg-v7.2' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux</title>
<updated>2026-06-21T06:31:15+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-06-21T06:31:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=c7f112e12de3098176e3c5eef022dd0eecfeeeba'/>
<id>c7f112e12de3098176e3c5eef022dd0eecfeeeba</id>
<content type='text'>
Pull rpmsg update from Bjorn Andersson:

 - Fix use-after-free in rpmsg-char driver

* tag 'rpmsg-v7.2' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux:
  rpmsg: char: Fix use-after-free on probe error path
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull rpmsg update from Bjorn Andersson:

 - Fix use-after-free in rpmsg-char driver

* tag 'rpmsg-v7.2' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux:
  rpmsg: char: Fix use-after-free on probe error path
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: char: Fix use-after-free on probe error path</title>
<updated>2026-06-04T17:58:37+00:00</updated>
<author>
<name>Yuho Choi</name>
<email>dbgh9129@gmail.com</email>
</author>
<published>2026-06-01T18:32:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=1ff3f528e67d20e2b1483dcaba899dc7832b2e6b'/>
<id>1ff3f528e67d20e2b1483dcaba899dc7832b2e6b</id>
<content type='text'>
rpmsg_chrdev_probe() stores the newly allocated eptdev in the default
endpoint's priv pointer before calling rpmsg_chrdev_eptdev_add(). If
rpmsg_chrdev_eptdev_add() then fails, its error path frees eptdev while
the default endpoint may still dispatch callbacks with the stale priv
pointer.

Avoid publishing eptdev through the default endpoint until
rpmsg_chrdev_eptdev_add() succeeds. Messages received before the priv
pointer is published should be ignored by rpmsg_ept_cb(). Flow-control
updates can hit rpmsg_ept_flow_cb() in the same window, so make both
callbacks return success when priv is NULL.

Fixes: bc69d1066569 ("rpmsg: char: Introduce the "rpmsg-raw" channel")
Signed-off-by: Yuho Choi &lt;dbgh9129@gmail.com&gt;
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20260601183247.1962010-1-dbgh9129@gmail.com
Signed-off-by: Mathieu Poirier &lt;mathieu.poirier@linaro.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
rpmsg_chrdev_probe() stores the newly allocated eptdev in the default
endpoint's priv pointer before calling rpmsg_chrdev_eptdev_add(). If
rpmsg_chrdev_eptdev_add() then fails, its error path frees eptdev while
the default endpoint may still dispatch callbacks with the stale priv
pointer.

Avoid publishing eptdev through the default endpoint until
rpmsg_chrdev_eptdev_add() succeeds. Messages received before the priv
pointer is published should be ignored by rpmsg_ept_cb(). Flow-control
updates can hit rpmsg_ept_flow_cb() in the same window, so make both
callbacks return success when priv is NULL.

Fixes: bc69d1066569 ("rpmsg: char: Introduce the "rpmsg-raw" channel")
Signed-off-by: Yuho Choi &lt;dbgh9129@gmail.com&gt;
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20260601183247.1962010-1-dbgh9129@gmail.com
Signed-off-by: Mathieu Poirier &lt;mathieu.poirier@linaro.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: use generic driver_override infrastructure</title>
<updated>2026-05-30T20:25:45+00:00</updated>
<author>
<name>Danilo Krummrich</name>
<email>dakr@kernel.org</email>
</author>
<published>2026-05-05T13:37:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=55ced13c42921714e90f8fae94b6ed803330dc6a'/>
<id>55ced13c42921714e90f8fae94b6ed803330dc6a</id>
<content type='text'>
When a driver is probed through __driver_attach(), the bus' match()
callback is called without the device lock held, thus accessing the
driver_override field without a lock, which can cause a UAF.

Fix this by using the driver-core driver_override infrastructure taking
care of proper locking internally.

Note that calling match() from __driver_attach() without the device lock
held is intentional. [1]

Link: https://lore.kernel.org/driver-core/DGRGTIRHA62X.3RY09D9SOK77P@kernel.org/ [1]
Reported-by: Gui-Dong Han &lt;hanguidong02@gmail.com&gt;
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=220789
Fixes: e95060478244 ("rpmsg: Introduce a driver override mechanism")
Reviewed-by: Mathieu Poirier &lt;mathieu.poirier@linaro.org&gt;
Reviewed-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Link: https://patch.msgid.link/20260505133935.3772495-5-dakr@kernel.org
Signed-off-by: Danilo Krummrich &lt;dakr@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a driver is probed through __driver_attach(), the bus' match()
callback is called without the device lock held, thus accessing the
driver_override field without a lock, which can cause a UAF.

Fix this by using the driver-core driver_override infrastructure taking
care of proper locking internally.

Note that calling match() from __driver_attach() without the device lock
held is intentional. [1]

Link: https://lore.kernel.org/driver-core/DGRGTIRHA62X.3RY09D9SOK77P@kernel.org/ [1]
Reported-by: Gui-Dong Han &lt;hanguidong02@gmail.com&gt;
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=220789
Fixes: e95060478244 ("rpmsg: Introduce a driver override mechanism")
Reviewed-by: Mathieu Poirier &lt;mathieu.poirier@linaro.org&gt;
Reviewed-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Link: https://patch.msgid.link/20260505133935.3772495-5-dakr@kernel.org
Signed-off-by: Danilo Krummrich &lt;dakr@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>rpmsg: Constify buffer passed to send API</title>
<updated>2026-04-06T14:37:51+00:00</updated>
<author>
<name>Krzysztof Kozlowski</name>
<email>krzysztof.kozlowski@oss.qualcomm.com</email>
</author>
<published>2026-03-17T12:36:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=b8077b4da2e89917ec4c632b66e60d49089bbda3'/>
<id>b8077b4da2e89917ec4c632b66e60d49089bbda3</id>
<content type='text'>
The rpmsg_send(), rpmsg_sendto() and other variants of sending
interfaces should only send the passed data, without modifying its
contents, so mark pointer 'data' as pointer to const.  All users of this
interface already follow this approach, so only the function
declarations have to be updated.

Acked-by: Mathieu Poirier &lt;mathieu.poirier@linaro.org&gt;
Reviewed-by: AngeloGioacchino Del Regno &lt;angelogioacchino.delregno@collabora.com&gt;
Signed-off-by: Krzysztof Kozlowski &lt;krzysztof.kozlowski@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260317-rpmsg-send-const-v3-3-4d7fd27f037f@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The rpmsg_send(), rpmsg_sendto() and other variants of sending
interfaces should only send the passed data, without modifying its
contents, so mark pointer 'data' as pointer to const.  All users of this
interface already follow this approach, so only the function
declarations have to be updated.

Acked-by: Mathieu Poirier &lt;mathieu.poirier@linaro.org&gt;
Reviewed-by: AngeloGioacchino Del Regno &lt;angelogioacchino.delregno@collabora.com&gt;
Signed-off-by: Krzysztof Kozlowski &lt;krzysztof.kozlowski@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260317-rpmsg-send-const-v3-3-4d7fd27f037f@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
