mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: w15303746062@163.com
Cc: arnd@arndb.de, linux-kernel@vger.kernel.org, kees@kernel.org,
	Mingyu Wang <25181214217@stu.xidian.edu.cn>,
	stable@vger.kernel.org
Subject: Re: [PATCH] misc: ibmasm: Fix out-of-bounds MMIO access during module load
Date: Tue, 23 Jun 2026 09:16:19 +0200	[thread overview]
Message-ID: <2026062354-crawfish-t-shirt-d45d@gregkh> (raw)
In-Reply-To: <20260623070909.362260-1-w15303746062@163.com>

On Tue, Jun 23, 2026 at 03:09:09PM +0800, w15303746062@163.com wrote:
> From: Mingyu Wang <25181214217@stu.xidian.edu.cn>
> 
> The ibmasm driver maps PCI BAR 0 without verifying if the hardware-provided
> resource length is sufficient. The driver statically accesses the
> INTR_CONTROL_REGISTER at offset 0x13A4.

The kernel trusts the hardware to not do foolish things like this :)

> When evaluating the driver against emulated hardware or during virtual
> device fuzzing, a malformed device may expose a significantly undersized
> BAR 0 (e.g., 4KB). In this scenario, the readl() in enable_sp_interrupts()
> crosses the mapped page boundary into unmapped memory, causing a page fault
> during probe.

Are you sure this is the only code path for this type of issue for this
device/driver?  Why just worry about this one?


thanks,

greg k-h

  reply	other threads:[~2026-06-23  7:17 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-23  7:09 w15303746062
2026-06-23  7:16 ` Greg KH [this message]
2026-06-23 11:40   ` [PATCH v2] misc: ibmasm: Fix static and dynamic out-of-bounds MMIO accesses w15303746062
2026-06-23 11:53     ` Greg KH
2026-06-23 12:00       ` Mingyu Wang
2026-06-23 11:47   ` [PATCH] misc: ibmasm: Fix out-of-bounds MMIO access during module load Mingyu Wang

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=2026062354-crawfish-t-shirt-d45d@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=25181214217@stu.xidian.edu.cn \
    --cc=arnd@arndb.de \
    --cc=kees@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=w15303746062@163.com \
    /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®