From: Lee Jones <lee@kernel.org>
To: lee@kernel.org,
"Roderick Colenbrander" <roderick.colenbrander@sony.com>,
"Jiri Kosina" <jikos@kernel.org>,
"Benjamin Tissoires" <bentiss@kernel.org>,
"Barnabás Pőcze" <pobrn@protonmail.com>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: stable@vger.kernel.org
Subject: [PATCH 10/10] HID: playstation: Cancel DualSense output worker on create failure
Date: Mon, 23 Nov 2026 15:50:54 +0000 [thread overview]
Message-ID: <20261123155138.2907049-11-lee@kernel.org> (raw)
In-Reply-To: <20261123155138.2907049-1-lee@kernel.org>
dualsense_create() schedules ds->output_worker via
dualsense_set_lightbar() before registering player LEDs and assigning a
player ID. If either step fails, the error path returns without
cancelling ds->output_worker, leaving queued or running work accessing
ds after devres frees it in hid_device_probe().
Call dualsense_remove() in the dualsense_create() error path to disable
further scheduling and cancel ds->output_worker synchronously.
Fixes: 949aaccda019 ("HID: playstation: add DualSense player LED support.")
Fixes: 182934a1e93b ("HID: playstation: stop DualSense output work on remove.")
Closes: https://sashiko.dev/#/bug/linux-b657d8df-afc1-429c-9bf5-b2583501dedd
Cc: stable@vger.kernel.org
Signed-off-by: Lee Jones <lee@kernel.org>
---
drivers/hid/hid-playstation.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/hid/hid-playstation.c b/drivers/hid/hid-playstation.c
index 143eb891e4a1..1113294f4add 100644
--- a/drivers/hid/hid-playstation.c
+++ b/drivers/hid/hid-playstation.c
@@ -1905,6 +1905,7 @@ static struct ps_device *dualsense_create(struct hid_device *hdev)
return &ds->base;
err:
+ dualsense_remove(ps_dev);
ps_devices_list_remove(ps_dev);
return ERR_PTR(ret);
}
--
2.56.1.750.gf70dc682cf-goog
prev parent reply other threads:[~2026-11-23 15:52 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-23 15:50 [PATCH 00/10] HID: Assorted bug fixes across HID core and drivers Lee Jones
2026-11-23 15:50 ` [PATCH 01/10] HID: core: Protect hid->inputs traversal in hid_check_keys_pressed() Lee Jones
2026-11-23 15:50 ` [PATCH 02/10] HID: mcp2221: Synchronise rxbuf access against raw_event callback Lee Jones
2026-11-23 15:50 ` [PATCH 03/10] HID: logitech-hidpp: Synchronise send_receive_buf against raw events Lee Jones
2026-11-23 16:14 ` sashiko-bot
2026-11-23 15:50 ` [PATCH 04/10] HID: sensor-hub: Serialise synchronous read teardown under data->lock Lee Jones
2026-11-23 16:13 ` sashiko-bot
2026-11-23 15:50 ` [PATCH 05/10] HID: roccat: pyra: Resolve USB device from parent in actual_profile Lee Jones
2026-11-23 15:50 ` [PATCH 06/10] HID: hyperv: Validate VMBus packet and payload bounds on receive Lee Jones
2026-11-23 15:50 ` [PATCH 07/10] HID: hid-goodix-spi: Validate package sizes in goodix_hid_irq() Lee Jones
2026-11-23 15:50 ` [PATCH 08/10] HID: wacom: Stop HID hardware before releasing resources on mode change Lee Jones
2026-11-23 16:08 ` sashiko-bot
2026-11-23 15:50 ` [PATCH 09/10] HID: debug: Hold driver_input_lock while dumping raw report descriptor Lee Jones
2026-11-23 15:50 ` Lee Jones [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261123155138.2907049-11-lee@kernel.org \
--to=lee@kernel.org \
--cc=bentiss@kernel.org \
--cc=jikos@kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pobrn@protonmail.com \
--cc=roderick.colenbrander@sony.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox