Re: [PATCH 1/4] vfio: selftests: Add support for passing vf_token in device init
From: Raghavendra Rao Ananta
Date: Thu Nov 06 2025 - 11:33:32 EST
On Thu, Nov 6, 2025 at 5:42 AM David Matlack <dmatlack@xxxxxxxxxx> wrote:
>
> On 2025-11-05 11:52 PM, David Matlack wrote:
> > On 2025-11-04 12:35 AM, Raghavendra Rao Ananta wrote:
> >
> > > -struct vfio_pci_device *vfio_pci_device_init(const char *bdf, const char *iommu_mode);
> > > +struct vfio_pci_device *vfio_pci_device_init(const char *bdf,
> > > + const char *iommu_mode,
> > > + const char *vf_token);
> >
> > Vipin is also looking at adding an optional parameter to
> > vfio_pci_device_init():
> > https://lore.kernel.org/kvm/20251018000713.677779-20-vipinsh@xxxxxxxxxx/
> >
> > I am wondering if we should support an options struct for such
> > parameters. e.g. something like this
>
> Wait, patch 4 doesn't even use vfio_pci_device_init(). Do we need this
> commit? It seems like we just need some of the inner functions to have
> support for vf_token.
Gah, that's my bad. I changed the approach later but forgot to revert
the API. I'll fix it in v2.