diff options
author | Laszlo Ersek <lersek@redhat.com> | 2020-12-16 22:10:58 +0100 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2020-12-21 17:16:23 +0000 |
commit | cd473d41dd8ba0cf400d2f4f4d4803f5dc56068e (patch) | |
tree | 68c341ac8c3c6dcb374a404f569e868ee9ab5e9e /OvmfPkg/VirtioFsDxe/VirtioFsDxe.h | |
parent | a70860f4499571669f3795adf52ccb0fa02cdac1 (diff) | |
download | edk2-cd473d41dd8ba0cf400d2f4f4d4803f5dc56068e.tar.gz |
OvmfPkg/VirtioFsDxe: convert FUSE inode attributes to EFI_FILE_INFO
Introduce the VirtioFsFuseAttrToEfiFileInfo() function, for converting
FUSE inode attributes to EFI_FILE_INFO.
The EpochToEfiTime() function from EmbeddedPkg's TimeBaseLib proves
invaluable for converting the file access times.
This is the first time we consume TimeBaseLib in OvmfPkg, so add the
necessary lib class resolution. We need not modify any ArmVirtPkg DSC
files: see commit af5fed90bfbf ("ArmPlatformPkg,ArmVirtPkg: delete
redundant PL031 functions", 2017-05-10).
Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Philippe Mathieu-Daudé <philmd@redhat.com>
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3097
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Message-Id: <20201216211125.19496-22-lersek@redhat.com>
Acked-by: Ard Biesheuvel <ard.biesheuvel@arm.com>
Diffstat (limited to 'OvmfPkg/VirtioFsDxe/VirtioFsDxe.h')
-rw-r--r-- | OvmfPkg/VirtioFsDxe/VirtioFsDxe.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/OvmfPkg/VirtioFsDxe/VirtioFsDxe.h b/OvmfPkg/VirtioFsDxe/VirtioFsDxe.h index 795cf4ee5d..6cc5257bab 100644 --- a/OvmfPkg/VirtioFsDxe/VirtioFsDxe.h +++ b/OvmfPkg/VirtioFsDxe/VirtioFsDxe.h @@ -11,6 +11,7 @@ #define VIRTIO_FS_DXE_H_
#include <Base.h> // SIGNATURE_64()
+#include <Guid/FileInfo.h> // EFI_FILE_INFO
#include <IndustryStandard/VirtioFs.h> // VIRTIO_FS_TAG_BYTES
#include <Library/DebugLib.h> // CR()
#include <Protocol/SimpleFileSystem.h> // EFI_SIMPLE_FILE_SYSTEM_PROTOCOL
@@ -225,6 +226,12 @@ VirtioFsAppendPath ( OUT BOOLEAN *RootEscape
);
+EFI_STATUS
+VirtioFsFuseAttrToEfiFileInfo (
+ IN VIRTIO_FS_FUSE_ATTRIBUTES_RESPONSE *FuseAttr,
+ OUT EFI_FILE_INFO *FileInfo
+ );
+
//
// Wrapper functions for FUSE commands (primitives).
//
|