File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -976,26 +976,17 @@ format_efi_partition() {
976976
977977# check for EFI support or try to enable it {{{
978978efi_support () {
979- local efivars_loaded=false
980- # this is for kernels versions before v3.10, which didn't provide efivarfs yet
981- if modprobe efivars & > /dev/null ; then
982- efivars_loaded=true
983- fi
984- # kernel versions v3.10 and newer usually provide efivarfs
985- if modprobe efivarfs & > /dev/null ; then
986- efivars_loaded=true
987- fi
979+ # Absence of an EFI runtime does not prevent loading efivarfs since commit
980+ # 301de9a2055357375a4e1053d9df0f8f3467ff00 which landed in Linux v6.3.
981+ # Unconditionally load it, in case nothing else attempted it.
982+ modprobe efivarfs & > /dev/null || true
988983
989984 if [ -d /sys/firmware/efi ] ; then
990985 einfo " EFI support detected."
991986 return 0
992987 fi
993988
994- if ! [ -d /sys/firmware/efi ] && [ " ${efivars_loaded:- } " = " true" ] ; then
995- einfo " EFI support detected, but system seems to be running in BIOS mode."
996- fi
997-
998- # The user may have a legitimate reason to do an EFI installation on a BIOS
989+ # The user may have a legitimate reason to do an EFI installation on a non-EFI
999990 # system (for instance if doing a hybrid-bootable installation), so don't
1000991 # return 1 here.
1001992}
You can’t perform that action at this time.
0 commit comments