All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Alex Williamson <alex@shazbot.org>
Cc: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>,
	bhelgaas@google.com, mani@kernel.org, jjohnson@kernel.org,
	linux-pci@vger.kernel.org, linux-wireless@vger.kernel.org,
	ath11k@lists.infradead.org, ath12k@lists.infradead.org,
	mhi@lists.linux.dev, linux-kernel@vger.kernel.org,
	Jason Gunthorpe <jgg@ziepe.ca>
Subject: Re: [PATCH v14 0/2] PCI: Add device-specific reset for Qualcomm devices
Date: Fri, 2 Oct 2026 18:47:49 -0500	[thread overview]
Message-ID: <20261002234749.GA411439@bhelgaas> (raw)
In-Reply-To: <20261002170949.59c3d47a@shazbot.org>

On Fri, Oct 02, 2026 at 05:09:49PM -0600, Alex Williamson wrote:
> On Fri, 2 Oct 2026 16:40:58 -0500
> Bjorn Helgaas <helgaas@kernel.org> wrote:
> 
> > [cc->to: Alex, +cc Jason]
> > 
> > On Thu, Sep 17, 2026 at 09:16:49AM +0200, Jose Ignacio Tornos Martinez wrote:
> > > Some Qualcomm PCIe devices (WCN6855, WCN7850 WLAN; SDX62/SDX65 modems)
> > > lack working reset methods for VFIO passthrough scenarios. These devices
> > > have no FLR capability, advertise NoSoftRst+ (blocking PM reset), and have
> > > broken bus reset (addressed by quirk_no_bus_reset, merged for v7.2).  
> > 
> > Specifically, 6a4f64c3a3ad ("PCI: Avoid SBR for Qualcomm
> > WCN6855/WCN7850 WiFi, SDX62/SDX65 modems").  I don't know what the
> > behavior was prior to that commit.  I suppose it was something
> > obvious?
> > 
> > > VFIO attempts to reset devices on every reassignment:
> > > - For the listed modems, without a proper reset capability, these devices
> > > never successfully initialize even on first VM assignment.
> > > - For the listed WLAN devices, without a working reset method, the attempt
> > > fails. On clean VM shutdown, the guest driver properly deinitializes the
> > > device via .shutdown/.remove callbacks, leaving it in a usable state despite
> > > the failed reset. However, on unclean VM termination (crash, force-off), the
> > > guest driver callbacks are not triggered, the device remains in an undefined
> > > state (DMA active, interrupts enabled, etc.), and without a working reset it
> > > cannot be reused.  
> > 
> > So IIUC, prior to these patches, these devices were functional when
> > passed through to several successive guests as long as the guests shut
> > down cleanly, but the resets done by VFIO didn't work, so the host
> > couldn't enforce isolation between those guests.
> > 
> > If true, I propose updating the commit logs to emphasize the lack of
> > isolation and de-emphasize the VM clean shutdown vs crash behavior,
> > e.g.:
> > 
> >   Resets of this device always failed prior to this commit, so VFIO on
> >   the host could not enforce isolation between successive passthrough
> >   users.
> > 
> >   If a guest driver deinitialized the device, it may have been
> >   functional if passed through to a subsequent guest, despite the lack
> >   of isolation.  Otherwise the device may have been left in an
> >   undefined state (e.g., DMA and interrupts active) and unusable.
> > 
> > It would also be great to have Alex's ack here.
> 
> Yes, aiui it's an isolation and repeatability issue.  In fact, without
> knowing what's actually stored in the hardware, I'd suspect it's more
> the latter and the testing proves that.  Mani is really the one
> vouching for it from the hardware, isolation perspective.
> 
> Standard reset methods have never worked on these devices and that's
> now evident by the quirks that disable them for these devices.  This
> fills the remaining gap by providing device specific resets for the same
> hardware.
> 
> Both patches should properly reference the quirk_no_bus_reset commit,
> but otherwise these look correct, afaict.
> 
> Acked-by: Alex Williamson <alex@shazbot.org>

Thanks, Alex!

  reply	other threads:[~2026-10-02 23:47 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-17  7:16 [PATCH v14 0/2] PCI: Add device-specific reset for Qualcomm devices Jose Ignacio Tornos Martinez
2026-09-17  7:16 ` [PATCH v14 1/2] PCI: Add device-specific reset for Qualcomm SDX62/SDX65 modems Jose Ignacio Tornos Martinez
2026-09-17  7:35   ` sashiko-bot
2026-09-17 12:45     ` Jose Ignacio Tornos Martinez
2026-09-17  7:16 ` [PATCH v14 2/2] PCI: Add device-specific reset for Qualcomm WCN6855/WCN7850 WLAN Jose Ignacio Tornos Martinez
2026-09-17  7:26   ` sashiko-bot
2026-10-02 21:40 ` [PATCH v14 0/2] PCI: Add device-specific reset for Qualcomm devices Bjorn Helgaas
2026-10-02 23:09   ` Alex Williamson
2026-10-02 23:47     ` Bjorn Helgaas [this message]
2026-10-05 10:48       ` Jose Ignacio Tornos Martinez

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=20261002234749.GA411439@bhelgaas \
    --to=helgaas@kernel.org \
    --cc=alex@shazbot.org \
    --cc=ath11k@lists.infradead.org \
    --cc=ath12k@lists.infradead.org \
    --cc=bhelgaas@google.com \
    --cc=jgg@ziepe.ca \
    --cc=jjohnson@kernel.org \
    --cc=jtornosm@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=mani@kernel.org \
    --cc=mhi@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.