Kernel KVM virtualization development
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Alex Williamson <alex@shazbot.org>
Cc: kvm@vger.kernel.org
Subject: Re: [PATCH v7] vfio/pci: expose ACPI _ROM through a device region
Date: Fri, 4 Dec 2026 10:41:06 -0500	[thread overview]
Message-ID: <20261204102624-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <20261204080333.58dfbe2c@shazbot.org>

On Fri, Dec 04, 2026 at 08:03:33AM -0700, Alex Williamson wrote:
> On Fri, 4 Dec 2026 06:19:54 -0500
> "Michael S. Tsirkin" <mst@redhat.com> wrote:
> 
> > Some GPUs provide their option ROM through the ACPI _ROM method.
> > According to the spec, _ROM, if present, must supercede the
> > PCI ROM BAR, but VFIO currently provides no means to access its
> > contents.
> > 
> > Let's report it through a new VFIO_REGION_TYPE_ACPI subtype:
> > VFIO_REGION_SUBTYPE_ACPI_ROM.
> > 
> > Note that _ROM size is not provided by the firmware and has to be parsed
> > from the image. Let's leave this to userspace.
> 
> Nak.  This doesn't align with existing semantics that define other zero
> sized regions as not present.  It also makes it non-deterministic which
> region a user is trying to access based on offset.  The fixed region
> spacing is implementation, not API.  The API is to use region offset
> and size from the region-info ioctl.  We'll eventually be more densely
> packing regions to account for BARs and device memory that exceed the
> current 40 bit segmentation.  Thanks,
> 
> Alex

Well exactly. And _ROM is not in device memory at all. It's offset is
wholly artificial. Isn't it? So wouldn't packing a zero sized one be
easier, going forward?

I don't insist, I can code up the parser, just making sure you are sure
this is what you want.

-- 
MST

  reply	other threads:[~2026-12-04 15:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-04 11:19 [PATCH v7] vfio/pci: expose ACPI _ROM through a device region Michael S. Tsirkin
2026-12-04 11:54 ` sashiko-bot
2026-12-04 15:03 ` Alex Williamson
2026-12-04 15:41   ` Michael S. Tsirkin [this message]
2026-12-04 16:38     ` Alex Williamson

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=20261204102624-mutt-send-email-mst@kernel.org \
    --to=mst@redhat.com \
    --cc=alex@shazbot.org \
    --cc=kvm@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