From: "Jason A. Donenfeld" <Jason@zx2c4.com>
To: Chenyuan Yang <chenyuan0y@gmail.com>
Cc: tytso@mit.edu, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] virt: vmgenid: Add Null check for device
Date: Wed, 19 Mar 2025 18:22:23 +0100 [thread overview]
Message-ID: <Z9r9T26d7Sk0R9jB@zx2c4.com> (raw)
In-Reply-To: <20250313042600.1168619-1-chenyuan0y@gmail.com>
On Wed, Mar 12, 2025 at 11:26:00PM -0500, Chenyuan Yang wrote:
> Not all devices have an ACPI companion fwnode, so device might be NULL.
> This is similar to the commit cd2fd6eab480
> ("platform/x86: int3472: Check for adev == NULL").
>
> Add a check for device not being set and return -ENODEV in that case to
> avoid a possible NULL pointer deref in vmgenid_add_acpi().
Is this causing a crash on some systems? What's happening here? "Not all
devices" - which ones, and why?
Jason
prev parent reply other threads:[~2025-03-19 17:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-13 4:26 Chenyuan Yang
2025-03-19 17:22 ` Jason A. Donenfeld [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=Z9r9T26d7Sk0R9jB@zx2c4.com \
--to=jason@zx2c4.com \
--cc=chenyuan0y@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tytso@mit.edu \
/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®