Re: [RFC PATCH 2/5] PCI: Add pci_reset_bus_cond() for a caller-gated slot or bus reset

[email protected]
Newsgroups org.kernel.vger.linux-pci,org.kernel.vger.kvm
Message-ID <[email protected]>
> pci_reset_bus() locks every device affected by a slot or bus reset,
> performs the reset, and unlocks the devices, all internally.  A caller
> has no way to evaluate what the reset would actually touch.
> 
> Add pci_reset_bus_cond(), which takes a callback invoked on each
> affected device once they are all locked.  A nonzero return value from
> the callback aborts the reset and the value is returned to the caller.
> This allows, for instance, the caller to validate that SR-IOV is not
> enabled on any affected device under device_lock, where the value is
> known stable across the reset.
> 
> Assisted-by: Claude:claude-opus-4-8
> Signed-off-by: Alex Williamson <[email protected]>

Sashiko has reviewed this patch and found no issues. It looks great!

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=2
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.