OvmfPkg/VirtioNetDxe: add helper VirtioNetUninitRing()
Consolidate the virtio VRING resource cleanup into VirtioNetUninitRing(). Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Tom Lendacky <thomas.lendacky@amd.com> Cc: Laszlo Ersek <lersek@redhat.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Brijesh Singh <brijesh.singh@amd.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Regression-tested-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Laszlo Ersek <lersek@redhat.com>
This commit is contained in:
committed by
Laszlo Ersek
parent
b30abe7df4
commit
55dd5a673b
@@ -51,3 +51,19 @@ VirtioNetShutdownTx (
|
||||
{
|
||||
FreePool (Dev->TxFreeStack);
|
||||
}
|
||||
|
||||
/**
|
||||
Release TX and RX VRING resources.
|
||||
|
||||
@param[in,out] Dev The VNET_DEV driver instance which was using the ring.
|
||||
@param[in,out] Ring The virtio ring to clean up.
|
||||
*/
|
||||
VOID
|
||||
EFIAPI
|
||||
VirtioNetUninitRing (
|
||||
IN OUT VNET_DEV *Dev,
|
||||
IN OUT VRING *Ring
|
||||
)
|
||||
{
|
||||
VirtioRingUninit (Dev->VirtIo, Ring);
|
||||
}
|
||||
|
Reference in New Issue
Block a user