]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Universal/BdsDxe/HwErrRecSupport.c
UEFI HII: Merge UEFI HII support changes from branch.
[mirror_edk2.git] / MdeModulePkg / Universal / BdsDxe / HwErrRecSupport.c
1 /*++
2
3 Copyright (c) 2007, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11
12 Module Name:
13
14 HwErrRecSupport.c
15
16 Abstract:
17
18 Set the level of support for Hardware Error Record Persistence that is
19 implemented by the platform.
20
21 Revision History
22
23 --*/
24
25 #include "HwErrRecSupport.h"
26
27 VOID
28 InitializeHwErrRecSupport (
29 IN UINT16 HwErrRecSupportLevel
30 )
31 /*++
32
33 Routine Description:
34 Set the HwErrRecSupport variable contains a binary UINT16 that supplies the
35 level of support for Hardware Error Record Persistence that is implemented
36 by the platform.
37
38 Arguments:
39 HwErrRecSupportLevel
40 zero value - Indicates that the platform implements no support for
41 Hardware Error Record Persistence.
42 non-zero value - Indicates that the platform implements Hardware Error
43 Record Persistence.
44
45 Returns:
46
47 --*/
48 {
49 EFI_STATUS Status;
50
51 Status = gRT->SetVariable (
52 L"HwErrRecSupport",
53 &gEfiGlobalVariableGuid,
54 EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_RUNTIME_ACCESS,
55 sizeof (UINT16),
56 &HwErrRecSupportLevel
57 );
58 if (EFI_ERROR (Status)) {
59 DEBUG ((EFI_D_ERROR, "HwErrRecSupport: Can not set the variable\n"));
60 }
61
62 }