diff options
author | raywu <raywu0301@gmail.com> | 2018-06-15 00:00:50 +0800 |
---|---|---|
committer | raywu <raywu0301@gmail.com> | 2018-06-15 00:00:50 +0800 |
commit | b7c51c9cf4864df6aabb99a1ae843becd577237c (patch) | |
tree | eebe9b0d0ca03062955223097e57da84dd618b9a /EDK/Foundation/Ppi/FlashMap | |
download | zprj-master.tar.xz |
Diffstat (limited to 'EDK/Foundation/Ppi/FlashMap')
-rw-r--r-- | EDK/Foundation/Ppi/FlashMap/FlashMap.c | 28 | ||||
-rw-r--r-- | EDK/Foundation/Ppi/FlashMap/FlashMap.h | 59 |
2 files changed, 87 insertions, 0 deletions
diff --git a/EDK/Foundation/Ppi/FlashMap/FlashMap.c b/EDK/Foundation/Ppi/FlashMap/FlashMap.c new file mode 100644 index 0000000..10a276b --- /dev/null +++ b/EDK/Foundation/Ppi/FlashMap/FlashMap.c @@ -0,0 +1,28 @@ +/*++ + +Copyright (c) 2004, Intel Corporation +All rights reserved. This program and the accompanying materials +are licensed and made available under the terms and conditions of the BSD License +which accompanies this distribution. The full text of the license may be found at +http://opensource.org/licenses/bsd-license.php + +THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. + +Module Name: + + FlashMap.c + +Abstract: + + Flash Map PPI GUID as defined in Tiano + +--*/ + +#include "Tiano.h" +#include "Pei.h" +#include EFI_PPI_DEFINITION (FlashMap) + +EFI_GUID gPeiFlashMapPpiGuid = PEI_FLASH_MAP_PPI_GUID; + +EFI_GUID_STRING(&gPeiFlashMapPpiGuid, "Flash Map", "Flash Map PPI"); diff --git a/EDK/Foundation/Ppi/FlashMap/FlashMap.h b/EDK/Foundation/Ppi/FlashMap/FlashMap.h new file mode 100644 index 0000000..123f1e7 --- /dev/null +++ b/EDK/Foundation/Ppi/FlashMap/FlashMap.h @@ -0,0 +1,59 @@ +/*++ + +Copyright (c) 2004, Intel Corporation +All rights reserved. This program and the accompanying materials +are licensed and made available under the terms and conditions of the BSD License +which accompanies this distribution. The full text of the license may be found at +http://opensource.org/licenses/bsd-license.php + +THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. + +Module Name: + + FlashMap.h + +Abstract: + + FlashMap PPI defined in Tiano + + This code abstracts FlashMap access + +--*/ + +#ifndef _PEI_FLASH_MAP_PPI_H_ +#define _PEI_FLASH_MAP_PPI_H_ + +#define PEI_FLASH_MAP_PPI_GUID \ + { \ + 0xf34c2fa0, 0xde88, 0x4270, 0x84, 0x14, 0x96, 0x12, 0x22, 0xf4, 0x52, 0x1c \ + } + +#include "EfiFlashMap.h" + +EFI_FORWARD_DECLARATION (PEI_FLASH_MAP_PPI); + +// +// Functions +// +typedef +EFI_STATUS +(EFIAPI *PEI_GET_FLASH_AREA_INFO) ( + IN EFI_PEI_SERVICES **PeiServices, + IN PEI_FLASH_MAP_PPI * This, + IN EFI_FLASH_AREA_TYPE AreaType, + IN EFI_GUID * AreaTypeGuid, + OUT UINT32 *NumEntries, + OUT EFI_FLASH_SUBAREA_ENTRY **Entries + ); + +// +// PEI_FLASH_MAP_PPI +// +typedef struct _PEI_FLASH_MAP_PPI { + PEI_GET_FLASH_AREA_INFO GetAreaInfo; +} PEI_FLASH_MAP_PPI; + +extern EFI_GUID gPeiFlashMapPpiGuid; + +#endif // _PEI_FLASH_MAP_PPI_H_ |