From: Johan Hovold <johan@kernel.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Ilia Sergachev <silia@ethz.ch>,
Karol Gugala <kgugala@antmicro.com>,
Mateusz Holenko <mholenko@antmicro.com>,
linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org,
Johan Hovold <johan@kernel.org>
Subject: [PATCH 0/3] serial: liteuart: fix compile testing and driver unbind
Date: Mon, 15 Nov 2021 14:37:42 +0100 [thread overview]
Message-ID: <20211115133745.11445-1-johan@kernel.org> (raw)
Ilia Sergachev noted that the liteuart remove() function would trigger a
NULL-pointer dereference if it was ever called since the driver data
pointer was never initialised.
Turns out there are more bugs in this part of the driver which clearly
has never been tested.
Also fix up the Kconfig dependencies so that the driver can actually be
compile tested.
Note that this series depends on the fix by Ilia:
https://lore.kernel.org/r/20211115031808.7ab632ef@dtkw
Johan
Johan Hovold (3):
serial: liteuart: fix compile testing
serial: liteuart: fix use-after-free and memleak on unbind
serial: liteuart: fix minor-number leak on probe errors
drivers/tty/serial/Kconfig | 4 ++--
drivers/tty/serial/liteuart.c | 18 +++++++++++++++---
2 files changed, 17 insertions(+), 5 deletions(-)
--
2.32.0
next reply other threads:[~2021-11-15 13:44 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-15 13:37 Johan Hovold [this message]
2021-11-15 13:37 ` [PATCH 1/3] serial: liteuart: fix compile testing Johan Hovold
2021-11-15 21:15 ` Stafford Horne
2021-11-16 15:44 ` Andy Shevchenko
2021-11-17 9:06 ` Johan Hovold
2021-11-15 13:37 ` [PATCH 2/3] serial: liteuart: fix use-after-free and memleak on unbind Johan Hovold
2021-11-15 21:15 ` Stafford Horne
2021-11-16 7:06 ` Johan Hovold
2021-11-15 13:37 ` [PATCH 3/3] serial: liteuart: fix minor-number leak on probe errors Johan Hovold
2021-11-15 21:16 ` Stafford Horne
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=20211115133745.11445-1-johan@kernel.org \
--to=johan@kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=kgugala@antmicro.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=mholenko@antmicro.com \
--cc=silia@ethz.ch \
/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;
as well as URLs for NNTP newsgroup(s).