summaryrefslogtreecommitdiffstats
path: root/src/config/general.h
diff options
context:
space:
mode:
authorMichael Brown2023-05-24 11:20:31 +0200
committerMichael Brown2023-05-24 11:20:31 +0200
commit6a7f560e60837fc2ce82a7aa976035656f7d231e (patch)
tree5a6f06694b4eaef5b8ec6ccb1e4976d8594d3dc2 /src/config/general.h
parent[efi] Support versions of shim that perform SBAT verification (diff)
downloadipxe-6a7f560e60837fc2ce82a7aa976035656f7d231e.tar.gz
ipxe-6a7f560e60837fc2ce82a7aa976035656f7d231e.tar.xz
ipxe-6a7f560e60837fc2ce82a7aa976035656f7d231e.zip
[efi] Implement "shim" as a dummy command on non-EFI platforms
The "shim" command will skip downloading the shim binary (and is therefore a conditional no-op) if there is already a selected EFI image that can be executed directly via LoadImage()/StartImage(). This allows the same iPXE script to be used with Secure Boot either enabled or disabled. Generalise this further to provide a dummy "shim" command that is an unconditional no-op on non-EFI platforms. This then allows the same iPXE script to be used for BIOS, EFI with Secure Boot disabled, or EFI with Secure Boot enabled. The same effect could be achieved by using "iseq ${platform} efi" within the script, but this would complicate end-user documentation. To minimise the code size impact, the dummy "shim" command is a pure no-op that does not call parse_options() and so will ignore even standardised arguments such as "--help". Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/config/general.h')
-rw-r--r--src/config/general.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/config/general.h b/src/config/general.h
index 2a371d0e..6e8e86b2 100644
--- a/src/config/general.h
+++ b/src/config/general.h
@@ -160,7 +160,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
//#define CERT_CMD /* Certificate management commands */
//#define IMAGE_MEM_CMD /* Read memory command */
#define IMAGE_ARCHIVE_CMD /* Archive image management commands */
-//#define SHIM_CMD /* EFI shim command */
+#define SHIM_CMD /* EFI shim command (or dummy command) */
/*
* ROM-specific options