summaryrefslogtreecommitdiff
path: root/tools/lib/python
diff options
context:
space:
mode:
authorHongyan Xu <getshell@seu.edu.cn>2026-08-06 14:05:40 +0800
committerBjorn Andersson <andersson@kernel.org>2026-08-31 18:13:30 -0500
commit7dc14f37ca4ee35040c67c4b0180dd7b32079caf (patch)
treec1fb1497a5a67450ac920ed5c9f32f0130b2f8f2 /tools/lib/python
parent22f129fedb153a17d80b1d883a7c4dd2417cf38e (diff)
soc: qcom: apr: clean up failed service registrations
apr_add_device() publishes a service in svcs_idr before parsing the optional protection domain and registering the device. If device registration fails, put_device() frees the apr_device while its service remains in the IDR. A received packet can then dereference that stale entry. The property error path also leaves the service and allocation behind. Split device_register() into device_initialize() and device_add() so every pre-registration error can safely drop the device reference. Remove the service from the IDR on all failures after publication, then drain the RX workqueue before dropping the device reference. This prevents an in-flight lookup from outliving the device. Fixes: 6adba21eb434 ("soc: qcom: Add APR bus driver") Signed-off-by: Hongyan Xu <getshell@seu.edu.cn> Link: https://lore.kernel.org/r/20260806060541.820-1-getshell@seu.edu.cn Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Diffstat (limited to 'tools/lib/python')
0 files changed, 0 insertions, 0 deletions