summaryrefslogtreecommitdiffstats
path: root/OvmfPkg/Include/IndustryStandard
diff options
context:
space:
mode:
authorLaszlo Ersek <lersek@redhat.com>2020-12-16 22:10:58 +0100
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-12-21 17:16:23 +0000
commitcd473d41dd8ba0cf400d2f4f4d4803f5dc56068e (patch)
tree68c341ac8c3c6dcb374a404f569e868ee9ab5e9e /OvmfPkg/Include/IndustryStandard
parenta70860f4499571669f3795adf52ccb0fa02cdac1 (diff)
downloadedk2-cd473d41dd8ba0cf400d2f4f4d4803f5dc56068e.tar.gz
edk2-cd473d41dd8ba0cf400d2f4f4d4803f5dc56068e.tar.bz2
edk2-cd473d41dd8ba0cf400d2f4f4d4803f5dc56068e.zip
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/Include/IndustryStandard')
-rw-r--r--OvmfPkg/Include/IndustryStandard/VirtioFs.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/OvmfPkg/Include/IndustryStandard/VirtioFs.h b/OvmfPkg/Include/IndustryStandard/VirtioFs.h
index 63aced229e..5d1d990a2d 100644
--- a/OvmfPkg/Include/IndustryStandard/VirtioFs.h
+++ b/OvmfPkg/Include/IndustryStandard/VirtioFs.h
@@ -84,6 +84,9 @@ typedef struct {
//
// File mode bitmasks.
//
+#define VIRTIO_FS_FUSE_MODE_TYPE_MASK 0170000u
+#define VIRTIO_FS_FUSE_MODE_TYPE_REG 0100000u
+#define VIRTIO_FS_FUSE_MODE_TYPE_DIR 0040000u
#define VIRTIO_FS_FUSE_MODE_PERM_RWXU 0000700u
#define VIRTIO_FS_FUSE_MODE_PERM_RUSR 0000400u
#define VIRTIO_FS_FUSE_MODE_PERM_WUSR 0000200u