efi_loader: set CapsuleMax from CONFIG_EFI_CAPSULE_MAX

Adds CONFIG_EFI_CAPSULE_MAX to configure the max index value used in
EFI capsule reports. Prior to this change is the hard coded value was
65535 which would exceed available storage for variables. Now the
default value is 15 which should work fine with most systems.

Signed-off-by: Etienne Carriere <etienne.carriere@linaro.org>
This commit is contained in:
Etienne Carriere
2023-02-16 18:21:41 +01:00
committed by Heinrich Schuchardt
parent aa2d3945ce
commit 4429393b5a
3 changed files with 48 additions and 15 deletions

View File

@@ -226,6 +226,14 @@ config EFI_CAPSULE_AUTHENTICATE
Select this option if you want to enable capsule
authentication
config EFI_CAPSULE_MAX
int "Max value for capsule index"
default 15
range 0 65535
help
Select the max capsule index value used for capsule report
variables. This value is used to create CapsuleMax variable.
config EFI_DEVICE_PATH_TO_TEXT
bool "Device path to text protocol"
default y