Re: [PATCH v4 0/10] CXL Reset support for Type 2 devices

Alex Williamson
2026-01-27T16:33:48Z

On Tue, 20 Jan 2026 22:26:00 +0000
<smadhavan@nvidia.com> wrote:
> Motivation:
> -----------
> This change is broadly useful for reasons including but not limited to the
> following:
>
> - As support for Type 2 devices [4] is being introduced, more devices will
> require finer-grained reset mechanisms beyond bus-wide reset methods.
>
> - FLR does not affect CXL.cache or CXL.mem protocols, making CXL Reset
> the preferred method in some cases.

This proposal adds cxl_reset to the pci_reset_fn_methods[] array, so
while the above suggests there are some use cases that would prefer CXL
reset, we're interleaving the capability into the default function for
PCI function scoped reset.

I'm concerned about use cases like vfio-pci emulation of FLR, where we
currently call through the pci_reset_function() interfaces to take
advantage of device specific quirks. Such a use case (guest directed
FLR) might reasonably expect the scope of the reset is limited to CXL.io
without affecting CXL.cache or CXL.mem, therefore it's not clear that
pci_reset_function() necessarily has the correct scope.

OTOH, we also expose a reset ioctl through vfio-pci that could
reasonably reset the full state of the device, PCI and CXL. cxl_reset
would be appropriate here, however cxl_reset is prioritized below FLR
reset in the default reset_methods array, so pci_reset_function()
doesn't have the correct scope here either.

Is it really appropriate to consider cxl_reset as just another PCI reset
method given the scope difference? Does there need to be a way to
specify the scope when calling pci_reset_function() for drivers aware
of CXL.mem/cache? Thanks,

Alex