VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware/OvmfPkg/IoMmuDxe/IoMmuDxe.c@ 81913

Last change on this file since 81913 was 80721, checked in by vboxsync, 5 years ago

Devices/EFI/FirmwareNew: Start upgrade process to edk2-stable201908 (compiles on Windows and works to some extent), bugref:4643

  • Property svn:eol-style set to native
File size: 867 bytes
Line 
1/** @file
2
3 IoMmuDxe driver installs EDKII_IOMMU_PROTOCOL to provide the support for DMA
4 operations when SEV is enabled.
5
6 Copyright (c) 2017, AMD Inc. All rights reserved.<BR>
7
8 SPDX-License-Identifier: BSD-2-Clause-Patent
9
10**/
11
12#include "AmdSevIoMmu.h"
13
14EFI_STATUS
15EFIAPI
16IoMmuDxeEntryPoint (
17 IN EFI_HANDLE ImageHandle,
18 IN EFI_SYSTEM_TABLE *SystemTable
19 )
20{
21 EFI_STATUS Status;
22 EFI_HANDLE Handle;
23
24 //
25 // When SEV is enabled, install IoMmu protocol otherwise install the
26 // placeholder protocol so that other dependent module can run.
27 //
28 if (MemEncryptSevIsEnabled ()) {
29 Status = AmdSevInstallIoMmuProtocol ();
30 } else {
31 Handle = NULL;
32
33 Status = gBS->InstallMultipleProtocolInterfaces (
34 &Handle,
35 &gIoMmuAbsentProtocolGuid,
36 NULL, NULL);
37 }
38
39 return Status;
40}
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette