aboutsummaryrefslogtreecommitdiff
path: root/test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py
diff options
context:
space:
mode:
authorRaymond Mao <raymond.mao@linaro.org>2023-11-10 13:25:37 +0900
committerIlias Apalodimas <ilias.apalodimas@linaro.org>2023-11-18 10:08:08 +0200
commit550862bc1279278a029c8c17871a0c6241c522d8 (patch)
tree2a5db6dd8c2ceb871618eb076b33a2f91cc4f866 /test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py
parentd822255d653421bdcda9d6f443929a5b67ca4454 (diff)
downloadu-boot-550862bc1279278a029c8c17871a0c6241c522d8.zip
u-boot-550862bc1279278a029c8c17871a0c6241c522d8.tar.gz
u-boot-550862bc1279278a029c8c17871a0c6241c522d8.tar.bz2
efi_loader: Boot var automatic management
Changes for complying to EFI spec ยง3.5.1.1 'Removable Media Boot Behavior'. Boot variables can be automatically generated during a removable media is probed. At the same time, unused boot variables will be detected and removed. Please note that currently the function 'efi_disk_remove' has no ability to distinguish below two scenarios a) Unplugging of a removable media under U-Boot b) U-Boot exiting and booting an OS Thus currently the boot variables management is not added into 'efi_disk_remove' to avoid boot options being added/erased repeatedly under scenario b) during power cycles See TODO comments under function 'efi_disk_remove' for more details The original efi_secboot tests expect that BootOrder EFI variable is not defined. With this commit, the BootOrder EFI variable is automatically added when the disk is detected. The original efi_secboot tests end up with unexpected failure. The efi_secboot tests need to be modified to explicitly set the BootOrder EFI variable. squashfs and erofs ls tests are also affected by this modification, need to clear the previous state before squashfs ls test starts. Co-developed-by: Masahisa Kojima <masahisa.kojima@linaro.org> Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org> Signed-off-by: Raymond Mao <raymond.mao@linaro.org> Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Reviewed-by: Joao Marcos Costa <jmcosta944@gmail.com> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Diffstat (limited to 'test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py')
-rw-r--r--test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py b/test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py
index 527a556..a20a7d1 100644
--- a/test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py
+++ b/test/py/tests/test_fs/test_squashfs/test_sqfs_ls.py
@@ -118,6 +118,15 @@ def test_sqfs_ls(u_boot_console):
"""
build_dir = u_boot_console.config.build_dir
+ # If the EFI subsystem is enabled and initialized, EFI subsystem tries to
+ # add EFI boot option when the new disk is detected. If there is no EFI
+ # System Partition exists, EFI subsystem outputs error messages and
+ # it ends up with test failure.
+ # Restart U-Boot to clear the previous state.
+ # TODO: Ideally EFI test cases need to be fixed, but it will
+ # increase the number of system reset.
+ u_boot_console.restart_uboot()
+
# setup test environment
check_mksquashfs_version()
generate_sqfs_src_dir(build_dir)