VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware/OvmfPkg/Library/PxeBcPcdProducerLib/PxeBcPcd.c@ 98412

Last change on this file since 98412 was 85718, checked in by vboxsync, 5 years ago

Devices/EFI: Merge edk-stable202005 and make it build, bugref:4643

  • Property svn:eol-style set to native
File size: 898 bytes
Line 
1/** @file
2 Configure some PCDs dynamically for
3 "NetworkPkg/UefiPxeBcDxe/UefiPxeBcDxe.inf", from QEMU's fw_cfg.
4
5 Copyright (C) 2020, Red Hat, Inc.
6
7 SPDX-License-Identifier: BSD-2-Clause-Patent
8**/
9
10#include <Library/PcdLib.h>
11#include <Library/QemuFwCfgSimpleParserLib.h>
12
13RETURN_STATUS
14EFIAPI
15SetPxeBcPcds (
16 VOID
17 )
18{
19 BOOLEAN FwCfgBool;
20 RETURN_STATUS PcdStatus;
21
22 if (!RETURN_ERROR (QemuFwCfgParseBool ("opt/org.tianocore/IPv4PXESupport",
23 &FwCfgBool))) {
24 PcdStatus = PcdSet8S (PcdIPv4PXESupport, FwCfgBool);
25 if (RETURN_ERROR (PcdStatus)) {
26 return PcdStatus;
27 }
28 }
29
30 if (!RETURN_ERROR (QemuFwCfgParseBool ("opt/org.tianocore/IPv6PXESupport",
31 &FwCfgBool))) {
32 PcdStatus = PcdSet8S (PcdIPv6PXESupport, FwCfgBool);
33 if (RETURN_ERROR (PcdStatus)) {
34 return PcdStatus;
35 }
36 }
37
38 return RETURN_SUCCESS;
39}
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