From: Takashi Iwai <tiwai@suse.de>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: linux-input@vger.kernel.org, Takashi Iwai <tiwai@suse.de>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Input: synaptics - fix crash when enabling pass-through port
Date: Sat, 18 Jan 2025 09:46:29 +0100 [thread overview]
Message-ID: <87o704qzkq.wl-tiwai@suse.de> (raw)
In-Reply-To: <Z4qSHORvPn7EU2j1@google.com>
On Fri, 17 Jan 2025 18:23:40 +0100,
Dmitry Torokhov wrote:
>
> When enabling a pass-through port an interrupt might come before psmouse
> driver binds to the pass-through port. However synaptics sub-driver
> tries to access psmouse instance presumably associated with the
> pass-through port to figure out if only 1 byte of response or entire
> protocol packet needs to be forwarded to the pass-through port and may
> crash if psmouse instance has not been attached to the port yet.
>
> Fix the crash by introducing open() and close() methods for the port and
> check if the port is open before trying to access psmouse instance.
> Because psmouse calls serio_open() only after attaching psmouse instance
> to serio port instance this prevents the potential crash.
>
> Reported-by: Takashi Iwai <tiwai@suse.de>
> Fixes: 100e16959c3c ("Input: libps2 - attach ps2dev instances as serio port's drvdata")
> Link: https://bugzilla.suse.com/show_bug.cgi?id=1219522
> Cc: stable@vger.kernel.org
> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Reviewed-by: Takashi Iwai <tiwai@suse.de>
Thanks!
Takashi
next prev parent reply other threads:[~2025-01-18 8:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-17 17:23 [PATCH] Input: synaptics - fix crash when enabling pass-through port Dmitry Torokhov
2025-01-18 8:46 ` Takashi Iwai [this message]
2025-01-18 9:33 ` Takashi Iwai
2025-01-21 5:25 ` Dmitry Torokhov
2025-01-21 7:00 ` Takashi Iwai
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=87o704qzkq.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=dmitry.torokhov@gmail.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@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