From 6493b9d76191f4fa6da9a3a328f02d0300c5ea59 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Thu, 18 Apr 2024 14:27:27 +0200 Subject: [PATCH] Update libvfio API Signed-off-by: Evan Lezar --- internal/cdi/lib-vfio.go | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/internal/cdi/lib-vfio.go b/internal/cdi/lib-vfio.go index 167dd06f..75d86703 100644 --- a/internal/cdi/lib-vfio.go +++ b/internal/cdi/lib-vfio.go @@ -92,7 +92,7 @@ func (l *vfiolib) GetGPUDeviceEdits(device.Device) (*cdi.ContainerEdits, error) } // GetGPUDeviceSpecs should not be called for vfiolib -func (l *vfiolib) GetGPUDeviceSpecs(int, device.Device) (*specs.Device, error) { +func (l *vfiolib) GetGPUDeviceSpecs(int, device.Device) ([]specs.Device, error) { return nil, fmt.Errorf("unexpected call to vfiolib.GetGPUDeviceSpecs()") } @@ -102,6 +102,11 @@ func (l *vfiolib) GetMIGDeviceEdits(device.Device, device.MigDevice) (*cdi.Conta } // GetMIGDeviceSpecs should not be called for vfiolib -func (l *vfiolib) GetMIGDeviceSpecs(int, device.Device, int, device.MigDevice) (*specs.Device, error) { +func (l *vfiolib) GetMIGDeviceSpecs(int, device.Device, int, device.MigDevice) ([]specs.Device, error) { return nil, fmt.Errorf("unexpected call to vfiolib.GetMIGDeviceSpecs()") } + +// GetDeviceSpecsByID should not be called for vfiolib. +func (l *vfiolib) GetDeviceSpecsByID(...string) ([]specs.Device, error) { + return nil, fmt.Errorf("unexpected call to vfiolib.GetDeviceSpecsByID()") +}