From: Jani Nikula <jani.nikula@linux.intel.com>
To: Deepanshu Kartikey <kartikey406@gmail.com>,
joonas.lahtinen@linux.intel.com, rodrigo.vivi@intel.com,
tursulin@ursulin.net, airlied@gmail.com, simona@ffwll.ch,
krzysztof.karas@intel.com
Cc: intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
linux-kernel@vger.kernel.org,
syzbot+db96c5ff032f4292a8dc@syzkaller.appspotmail.com,
stable@vger.kernel.org
Subject: Re: [PATCH v2] drm/i915: Guard against NULL driver_data in i915_pci_probe()
Date: Mon, 31 Aug 2026 11:04:33 +0300 [thread overview]
Message-ID: <79e8a3d71ca0e2cb7274aa1e5e053f934bc88333@intel.com> (raw)
In-Reply-To: <CADhLXY4YXGWUi8JcfdYMJ4HhKMKS2RLg2WvnZnku_XK45m4-fQ@mail.gmail.com>
On Sun, 30 Aug 2026, Deepanshu Kartikey <kartikey406@gmail.com> wrote:
> On Thu, Aug 13, 2026 at 12:19 PM Deepanshu Kartikey
> <kartikey406@gmail.com> wrote:
>>
>> pci_match_device() can return the dummy pci_device_id_any entry
>> when a device is force-bound via sysfs driver_override, in which
>> case ->driver_data is unset (NULL). i915_pci_probe() casts it to
>> struct intel_device_info * unconditionally and dereferences
>> intel_info->require_force_probe, causing a NULL-ptr-deref.
>>
>> Reported-by: syzbot+db96c5ff032f4292a8dc@syzkaller.appspotmail.com
>> Closes: https://syzkaller.appspot.com/bug?extid=db96c5ff032f4292a8dc
>> Tested-by: syzbot+db96c5ff032f4292a8dc@syzkaller.appspotmail.com
>> Cc: stable@vger.kernel.org
>> Signed-off-by: Deepanshu Kartikey <kartikey406@gmail.com>
>> ---
>> v2: Drop Fixes tag, this isn't a regression from a single commit -
>> the unconditional dereference of ->driver_data has always assumed
>> it points into a MODULE_DEVICE_TABLE()-backed entry, an assumption
>> broken by the generic driver_override fallback path, not by any
>> i915-specific change. Add Cc: stable instead. (Krzysztof, Jani)
>> ---
>> drivers/gpu/drm/i915/i915_pci.c | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/i915/i915_pci.c b/drivers/gpu/drm/i915/i915_pci.c
>> index 82415af47d54..2f03f95945f1 100644
>> --- a/drivers/gpu/drm/i915/i915_pci.c
>> +++ b/drivers/gpu/drm/i915/i915_pci.c
>> @@ -958,6 +958,9 @@ static int i915_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
>> (struct intel_device_info *) ent->driver_data;
>> int err;
>>
>> + if (!intel_info)
>> + return -ENODEV;
>> +
>> if (intel_info->require_force_probe && !id_forced(pdev->device)) {
>> dev_info(&pdev->dev,
>> "Your graphics device %04x is not properly supported by i915 in this\n"
>> --
>> 2.43.0
>>
>
> Gente Reminder. Let me know the status of this patch .
Sorry about the delay. Thanks for the patch, pushed to drm-intel-next.
BR,
Jani.
>
> Thanks
>
> Deepanshu
--
Jani Nikula, Intel
prev parent reply other threads:[~2026-08-31 8:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-13 6:49 [PATCH v2] drm/i915: Guard against NULL driver_data in i915_pci_probe() Deepanshu Kartikey
2026-08-13 17:33 ` ✗ LGCI.VerificationFailed: failure for drm/i915: Guard against NULL driver_data in i915_pci_probe() (rev2) Patchwork
2026-08-18 11:57 ` ✓ i915.CI.BAT: success for drm/i915: Guard against NULL driver_data in i915_pci_probe() (rev3) Patchwork
2026-08-18 21:59 ` ✗ i915.CI.Full: failure " Patchwork
2026-08-21 1:45 ` [PATCH v2] drm/i915: Guard against NULL driver_data in i915_pci_probe() Deepanshu Kartikey
2026-08-30 6:25 ` Deepanshu Kartikey
2026-08-31 8:04 ` Jani Nikula [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=79e8a3d71ca0e2cb7274aa1e5e053f934bc88333@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=airlied@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=joonas.lahtinen@linux.intel.com \
--cc=kartikey406@gmail.com \
--cc=krzysztof.karas@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rodrigo.vivi@intel.com \
--cc=simona@ffwll.ch \
--cc=stable@vger.kernel.org \
--cc=syzbot+db96c5ff032f4292a8dc@syzkaller.appspotmail.com \
--cc=tursulin@ursulin.net \
/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