]> git.proxmox.com Git - mirror_edk2.git/commitdiff
ArmVirtPkg: raise PcdShellFileOperationSize to 128KB
authorLaszlo Ersek <lersek@redhat.com>
Wed, 13 Jan 2021 08:54:46 +0000 (09:54 +0100)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Tue, 19 Jan 2021 18:23:28 +0000 (18:23 +0000)
Some UEFI shell commands read and write files in chunks. The chunk size is
given by "PcdShellFileOperationSize", whose default in
"ShellPkg/ShellPkg.dec" is 4KB (0x1000).

The virtio-fs daemon of QEMU advertizes a 128KB maximum buffer size by
default, for the FUSE_WRITE operation.

By raising PcdShellFileOperationSize 32-fold, the number of FUSE write
requests shrinks proportionately, when writing large files. And when a
Virtio Filesystem is not used, a 128KB chunk size is still not
particularly wasteful.

Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
Cc: Leif Lindholm <leif@nuviainc.com>
Cc: Philippe Mathieu-Daudé <philmd@redhat.com>
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3125
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Acked-by: Ard Biesheuvel <ard.biesheuvel@arm.com>
Message-Id: <20210113085453.10168-4-lersek@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
ArmVirtPkg/ArmVirtQemu.dsc
ArmVirtPkg/ArmVirtQemuKernel.dsc

index ef5d6dbeaddcb4a3168fd265baaca0b00242e2b0..b8bc08d739218972a192930844f48ace75bb1bc9 100644 (file)
 !endif\r
 \r
   gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|3\r
+  gEfiShellPkgTokenSpaceGuid.PcdShellFileOperationSize|0x20000\r
 \r
 [PcdsFixedAtBuild.AARCH64]\r
   # Clearing BIT0 in this PCD prevents installing a 32-bit SMBIOS entry point,\r
index f8f5f7f4b94b94cee4583af1fae62bbc05f490c2..2ef86f96688f3477f3d0cf43ffcbc95878f50c21 100644 (file)
 !endif\r
 \r
   gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|3\r
+  gEfiShellPkgTokenSpaceGuid.PcdShellFileOperationSize|0x20000\r
 \r
 [PcdsPatchableInModule.common]\r
   # we need to provide a resolution for this PCD that supports PcdSet64()\r