FAILED: patch "[PATCH] Input: exc3000 - properly stop timer on shutdown" failed to apply to 6.1-stable tree
Subsystems (2)
[email protected]
maintainerThe patch below does not apply to the 6.1-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.1.y
git checkout FETCH_HEAD
git cherry-pick -x 79c81d137d36f9635bbcbc3916c0cccb418a61dd
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '[email protected]' --subject-prefix 'PATCH 6.1.y' HEAD^..
Possible dependencies:
79c81d137d36 ("Input: exc3000 - properly stop timer on shutdown")
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 79c81d137d36f9635bbcbc3916c0cccb418a61dd Mon Sep 17 00:00:00 2001
From: Dmitry Torokhov <[email protected]>
Date: Fri, 3 Feb 2023 16:43:29 -0800
Subject: [PATCH] Input: exc3000 - properly stop timer on shutdown
We need to stop the timer on driver unbind or probe failures, otherwise we get UAF/Oops.
drivers/input/touchscreen/exc3000.c +10 -0
@@ -109,6 +109,11 @@ static inline void exc3000_schedule_timer(struct exc3000_data *data)mod_timer (&data->timer, jiffies +msecs_to_jiffies (EXC3000_TIMEOUT_MS )); } +static void exc3000_shutdown_timer (void *timer) +{ +timer_shutdown_sync (timer); +} +static int exc3000_read_frame (struct exc3000_data *data,u8 *buf) {struct i2c_client *client = data->client;
@@ -386,6 +391,11 @@ static int exc3000_probe(struct i2c_client *client)if (error)return error; + error =devm_add_action_or_reset (&client->dev, exc3000_shutdown_timer, + &data->timer); +if (error) +return error; + error =devm_request_threaded_irq (&client->dev, client->irq,NULL , exc3000_interrupt,IRQF_ONESHOT , client->name, data);