]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Universal/BdsDxe/BootMaint/BBSsupport.h
95326b8d582d0a70088e32e6ed2b02fd1b171083
[mirror_edk2.git] / MdeModulePkg / Universal / BdsDxe / BootMaint / BBSsupport.h
1 /** @file
2 declares interface functions
3
4 Copyright (c) 2004 - 2008, Intel Corporation. <BR>
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 **/
14
15 #ifndef _EFI_BDS_BBS_SUPPORT_H_
16 #define _EFI_BDS_BBS_SUPPORT_H_
17
18 #include "BootMaint.h"
19
20 #define MAX_BBS_ENTRIES 0x100
21
22 /**
23 Build Legacy Device Name String according.
24
25 @param CurBBSEntry BBS Table.
26 @param Index Index.
27 @param BufSize The buffer size.
28 @param BootString The output string.
29
30 @return VOID No output.
31
32 **/
33 VOID
34 BdsBuildLegacyDevNameString (
35 IN BBS_TABLE *CurBBSEntry,
36 IN UINTN Index,
37 IN UINTN BufSize,
38 OUT CHAR16 *BootString
39 );
40
41 /**
42 Delete all the invalid legacy boot options.
43
44
45
46 @retval EFI_SUCCESS All invalide legacy boot options are deleted.
47 @retval EFI_OUT_OF_RESOURCES Fail to allocate necessary memory.
48 @retval EFI_NOT_FOUND Fail to retrive variable of boot order.
49 **/
50 EFI_STATUS
51 BdsDeleteAllInvalidLegacyBootOptions (
52 VOID
53 );
54
55 /**
56
57 Add the legacy boot options from BBS table if they do not exist.
58
59 @retval EFI_SUCCESS The boot options are added successfully or they are already in boot options.
60 @retval others An error occurred when creating legacy boot options.
61
62 **/
63 EFI_STATUS
64 BdsAddNonExistingLegacyBootOptions (
65 VOID
66 )
67 ;
68
69 /**
70
71 Add the legacy boot devices from BBS table into
72 the legacy device boot order.
73
74 @retval EFI_SUCCESS The boot devices are added successfully.
75
76 **/
77 EFI_STATUS
78 BdsUpdateLegacyDevOrder (
79 VOID
80 );
81
82 /**
83 Set the boot priority for BBS entries based on boot option entry and boot order.
84
85 @param Entry The boot option is to be checked for refresh BBS table.
86
87 @retval EFI_SUCCESS The boot priority for BBS entries is refreshed successfully.
88 @return status of BdsSetBootPriority4SameTypeDev()
89 **/
90 EFI_STATUS
91 BdsRefreshBbsTableForBoot (
92 IN BDS_COMMON_OPTION *Entry
93 );
94
95 #endif