mirror of https://github.com/acidanthera/audk.git
OvmfPkg: VIRTIO_DEVICE_PROTOCOL: remove GetQueueAddress() member
This function was never consumed by drivers, and the current prototype is unsupportable with virtio-1.0. Remove the function from the protocol definition, and drop the current (unused) implementations. Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Jordan Justen <jordan.l.justen@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
This commit is contained in:
parent
bc8fde6f62
commit
235be6a0f1
|
@ -126,27 +126,6 @@ EFI_STATUS
|
||||||
IN UINT64 Features
|
IN UINT64 Features
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
|
||||||
Read the queue address field from the Virtio Header.
|
|
||||||
|
|
||||||
QueueAddress is the address of the virtqueue divided by 4096.
|
|
||||||
|
|
||||||
@param[in] This This instance of VIRTIO_DEVICE_PROTOCOL
|
|
||||||
|
|
||||||
@param[out] QueueAddress The 32-bit queue address field.
|
|
||||||
|
|
||||||
@retval EFI_SUCCESS The data was read successfully.
|
|
||||||
@retval EFI_UNSUPPORTED The underlying IO device doesn't support the
|
|
||||||
provided address offset and read size.
|
|
||||||
@retval EFI_INVALID_PARAMETER QueueAddress is NULL
|
|
||||||
**/
|
|
||||||
typedef
|
|
||||||
EFI_STATUS
|
|
||||||
(EFIAPI *VIRTIO_GET_QUEUE_ADDRESS) (
|
|
||||||
IN VIRTIO_DEVICE_PROTOCOL *This,
|
|
||||||
OUT UINT32 *QueueAddress
|
|
||||||
);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Write the queue address field in the Virtio Header.
|
Write the queue address field in the Virtio Header.
|
||||||
|
|
||||||
|
@ -356,7 +335,6 @@ struct _VIRTIO_DEVICE_PROTOCOL {
|
||||||
VIRTIO_GET_DEVICE_FEATURES GetDeviceFeatures;
|
VIRTIO_GET_DEVICE_FEATURES GetDeviceFeatures;
|
||||||
VIRTIO_SET_GUEST_FEATURES SetGuestFeatures;
|
VIRTIO_SET_GUEST_FEATURES SetGuestFeatures;
|
||||||
|
|
||||||
VIRTIO_GET_QUEUE_ADDRESS GetQueueAddress;
|
|
||||||
VIRTIO_SET_QUEUE_ADDRESS SetQueueAddress;
|
VIRTIO_SET_QUEUE_ADDRESS SetQueueAddress;
|
||||||
|
|
||||||
VIRTIO_SET_QUEUE_SEL SetQueueSel;
|
VIRTIO_SET_QUEUE_SEL SetQueueSel;
|
||||||
|
|
|
@ -25,7 +25,6 @@ static VIRTIO_DEVICE_PROTOCOL mMmioDeviceProtocolTemplate = {
|
||||||
0, // SubSystemDeviceId
|
0, // SubSystemDeviceId
|
||||||
VirtioMmioGetDeviceFeatures, // GetDeviceFeatures
|
VirtioMmioGetDeviceFeatures, // GetDeviceFeatures
|
||||||
VirtioMmioSetGuestFeatures, // SetGuestFeatures
|
VirtioMmioSetGuestFeatures, // SetGuestFeatures
|
||||||
VirtioMmioGetQueueAddress, // GetQueueAddress
|
|
||||||
VirtioMmioSetQueueAddress, // SetQueueAddress
|
VirtioMmioSetQueueAddress, // SetQueueAddress
|
||||||
VirtioMmioSetQueueSel, // SetQueueSel
|
VirtioMmioSetQueueSel, // SetQueueSel
|
||||||
VirtioMmioSetQueueNotify, // SetQueueNotify
|
VirtioMmioSetQueueNotify, // SetQueueNotify
|
||||||
|
|
|
@ -68,13 +68,6 @@ VirtioMmioGetDeviceFeatures (
|
||||||
OUT UINT64 *DeviceFeatures
|
OUT UINT64 *DeviceFeatures
|
||||||
);
|
);
|
||||||
|
|
||||||
EFI_STATUS
|
|
||||||
EFIAPI
|
|
||||||
VirtioMmioGetQueueAddress (
|
|
||||||
IN VIRTIO_DEVICE_PROTOCOL *This,
|
|
||||||
OUT UINT32 *QueueAddress
|
|
||||||
);
|
|
||||||
|
|
||||||
EFI_STATUS
|
EFI_STATUS
|
||||||
EFIAPI
|
EFIAPI
|
||||||
VirtioMmioGetQueueSize (
|
VirtioMmioGetQueueSize (
|
||||||
|
|
|
@ -38,26 +38,6 @@ VirtioMmioGetDeviceFeatures (
|
||||||
return EFI_SUCCESS;
|
return EFI_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
EFI_STATUS
|
|
||||||
EFIAPI
|
|
||||||
VirtioMmioGetQueueAddress (
|
|
||||||
IN VIRTIO_DEVICE_PROTOCOL *This,
|
|
||||||
OUT UINT32 *QueueAddress
|
|
||||||
)
|
|
||||||
{
|
|
||||||
VIRTIO_MMIO_DEVICE *Device;
|
|
||||||
|
|
||||||
if (QueueAddress == NULL) {
|
|
||||||
return EFI_INVALID_PARAMETER;
|
|
||||||
}
|
|
||||||
|
|
||||||
Device = VIRTIO_MMIO_DEVICE_FROM_VIRTIO_DEVICE (This);
|
|
||||||
|
|
||||||
*QueueAddress = VIRTIO_CFG_READ (Device, VIRTIO_MMIO_OFFSET_QUEUE_PFN);
|
|
||||||
|
|
||||||
return EFI_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
EFI_STATUS
|
EFI_STATUS
|
||||||
EFIAPI
|
EFIAPI
|
||||||
VirtioMmioGetQueueSize (
|
VirtioMmioGetQueueSize (
|
||||||
|
|
|
@ -30,7 +30,6 @@ STATIC VIRTIO_DEVICE_PROTOCOL mDeviceProtocolTemplate = {
|
||||||
0, // SubSystemDeviceId
|
0, // SubSystemDeviceId
|
||||||
VirtioPciGetDeviceFeatures, // GetDeviceFeatures
|
VirtioPciGetDeviceFeatures, // GetDeviceFeatures
|
||||||
VirtioPciSetGuestFeatures, // SetGuestFeatures
|
VirtioPciSetGuestFeatures, // SetGuestFeatures
|
||||||
VirtioPciGetQueueAddress, // GetQueueAddress
|
|
||||||
VirtioPciSetQueueAddress, // SetQueueAddress
|
VirtioPciSetQueueAddress, // SetQueueAddress
|
||||||
VirtioPciSetQueueSel, // SetQueueSel
|
VirtioPciSetQueueSel, // SetQueueSel
|
||||||
VirtioPciSetQueueNotify, // SetQueueNotify
|
VirtioPciSetQueueNotify, // SetQueueNotify
|
||||||
|
|
|
@ -86,13 +86,6 @@ VirtioPciGetDeviceFeatures (
|
||||||
OUT UINT64 *DeviceFeatures
|
OUT UINT64 *DeviceFeatures
|
||||||
);
|
);
|
||||||
|
|
||||||
EFI_STATUS
|
|
||||||
EFIAPI
|
|
||||||
VirtioPciGetQueueAddress (
|
|
||||||
IN VIRTIO_DEVICE_PROTOCOL *This,
|
|
||||||
OUT UINT32 *QueueAddress
|
|
||||||
);
|
|
||||||
|
|
||||||
EFI_STATUS
|
EFI_STATUS
|
||||||
EFIAPI
|
EFIAPI
|
||||||
VirtioPciGetQueueSize (
|
VirtioPciGetQueueSize (
|
||||||
|
|
|
@ -122,25 +122,6 @@ VirtioPciGetDeviceFeatures (
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
EFI_STATUS
|
|
||||||
EFIAPI
|
|
||||||
VirtioPciGetQueueAddress (
|
|
||||||
IN VIRTIO_DEVICE_PROTOCOL *This,
|
|
||||||
OUT UINT32 *QueueAddress
|
|
||||||
)
|
|
||||||
{
|
|
||||||
VIRTIO_PCI_DEVICE *Dev;
|
|
||||||
|
|
||||||
if (QueueAddress == NULL) {
|
|
||||||
return EFI_INVALID_PARAMETER;
|
|
||||||
}
|
|
||||||
|
|
||||||
Dev = VIRTIO_PCI_DEVICE_FROM_VIRTIO_DEVICE (This);
|
|
||||||
|
|
||||||
return VirtioPciIoRead (Dev, VIRTIO_PCI_OFFSET_QUEUE_ADDRESS, sizeof (UINT32),
|
|
||||||
sizeof (UINT32), QueueAddress);
|
|
||||||
}
|
|
||||||
|
|
||||||
EFI_STATUS
|
EFI_STATUS
|
||||||
EFIAPI
|
EFIAPI
|
||||||
VirtioPciGetQueueSize (
|
VirtioPciGetQueueSize (
|
||||||
|
|
Loading…
Reference in New Issue