iPXE
FileInfo.h
Go to the documentation of this file.
1/** @file
2 Provides a GUID and a data structure that can be used with EFI_FILE_PROTOCOL.SetInfo()
3 and EFI_FILE_PROTOCOL.GetInfo() to set or get generic file information.
4 This GUID is defined in UEFI specification.
5
6Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
7SPDX-License-Identifier: BSD-2-Clause-Patent
8
9**/
10
11#ifndef __FILE_INFO_H__
12#define __FILE_INFO_H__
13
14FILE_LICENCE ( BSD2_PATENT );
15FILE_SECBOOT ( PERMITTED );
16
17#define EFI_FILE_INFO_ID \
18 { \
19 0x9576e92, 0x6d3f, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b } \
20 }
21
22typedef struct {
23 ///
24 /// The size of the EFI_FILE_INFO structure, including the Null-terminated FileName string.
25 ///
27 ///
28 /// The size of the file in bytes.
29 ///
31 ///
32 /// PhysicalSize The amount of physical space the file consumes on the file system volume.
33 ///
35 ///
36 /// The time the file was created.
37 ///
39 ///
40 /// The time when the file was last accessed.
41 ///
43 ///
44 /// The time when the file's contents were last modified.
45 ///
47 ///
48 /// The attribute bits for the file.
49 ///
51 ///
52 /// The Null-terminated name of the file.
53 /// For a root directory, the name is an empty string.
54 ///
57
58///
59/// The FileName field of the EFI_FILE_INFO data structure is variable length.
60/// Whenever code needs to know the size of the EFI_FILE_INFO data structure, it needs to
61/// be the size of the data structure without the FileName field. The following macro
62/// computes this size correctly no matter how big the FileName array is declared.
63/// This is required to make the EFI_FILE_INFO data structure ANSI compilant.
64///
65#define SIZE_OF_EFI_FILE_INFO OFFSET_OF (EFI_FILE_INFO, FileName)
66
68
69#endif
unsigned long long UINT64
8-byte unsigned value.
unsigned short CHAR16
2-byte Character.
EFI_GUID gEfiFileInfoGuid
GUID EFI_GUID
128-bit buffer containing a unique identifier value.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
Definition compiler.h:896
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
Definition compiler.h:926
EFI_TIME ModificationTime
The time when the file's contents were last modified.
Definition FileInfo.h:46
UINT64 PhysicalSize
PhysicalSize The amount of physical space the file consumes on the file system volume.
Definition FileInfo.h:34
EFI_TIME CreateTime
The time the file was created.
Definition FileInfo.h:38
UINT64 Size
The size of the EFI_FILE_INFO structure, including the Null-terminated FileName string.
Definition FileInfo.h:26
UINT64 Attribute
The attribute bits for the file.
Definition FileInfo.h:50
CHAR16 FileName[1]
The Null-terminated name of the file.
Definition FileInfo.h:55
EFI_TIME LastAccessTime
The time when the file was last accessed.
Definition FileInfo.h:42
UINT64 FileSize
The size of the file in bytes.
Definition FileInfo.h:30
EFI Time Abstraction: Year: 1900 - 9999 Month: 1 - 12 Day: 1 - 31 Hour: 0 - 23 Minute: 0 - 59 Second:...