From: Greg KH <gregkh@linuxfoundation.org>
To: Henry Martin <bsdhenrymartin@gmail.com>
Cc: arnd@arndb.de, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1] misc: tps6594-pfsm: Add NULL check in tps6594_pfsm_probe()
Date: Tue, 15 Apr 2025 16:13:46 +0200 [thread overview]
Message-ID: <2025041530-clinic-genre-35f9@gregkh> (raw)
In-Reply-To: <20250401133404.27793-1-bsdhenrymartin@gmail.com>
On Tue, Apr 01, 2025 at 09:34:04PM +0800, Henry Martin wrote:
> devm_kasprintf() returns NULL when memory allocation fails. Currently,
> tps6594_pfsm_probe() does not check for this case, which results in a
> NULL pointer dereference.
>
> Add NULL check after devm_kasprintf() to prevent this issue.
>
> Fixes: a0df3ef087f8 ("misc: tps6594-pfsm: Add driver for TI TPS6594 PFSM")
> Signed-off-by: Henry Martin <bsdhenrymartin@gmail.com>
> ---
> drivers/misc/tps6594-pfsm.c | 2 ++
> 1 file changed, 2 insertions(+)
Someone else sent this before you did, sorry:
https://lore.kernel.org/r/20250311010511.1028269-1-chenyuan0y@gmail.com
prev parent reply other threads:[~2025-04-15 14:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-01 13:34 Henry Martin
2025-04-01 13:39 ` Greg KH
2025-04-15 14:13 ` Greg KH [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=2025041530-clinic-genre-35f9@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=arnd@arndb.de \
--cc=bsdhenrymartin@gmail.com \
--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
all inboxes | Powered by JetHome®