diff options
author | Jan Janssen <medhefgo@web.de> | 2022-08-04 10:21:15 +0200 |
---|---|---|
committer | Jan Janssen <medhefgo@web.de> | 2022-08-04 10:21:15 +0200 |
commit | bafc594528767192bc4b3c0081a992a9e2647d50 (patch) | |
tree | 12c1efc35118bb424a654c611f0784effaa021a5 /src/boot/efi/util.h | |
parent | adb9485acb2b7f429a72ce6db024724a809b6ec1 (diff) | |
download | systemd-bafc594528767192bc4b3c0081a992a9e2647d50.tar.gz |
boot: Skip safety countdown when running in a VM
Diffstat (limited to 'src/boot/efi/util.h')
-rw-r--r-- | src/boot/efi/util.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/boot/efi/util.h b/src/boot/efi/util.h index bb4bb64e0e..afbc217d53 100644 --- a/src/boot/efi/util.h +++ b/src/boot/efi/util.h @@ -179,3 +179,11 @@ static inline void beep(UINTN beep_count) {} EFI_STATUS open_volume(EFI_HANDLE device, EFI_FILE **ret_file); EFI_STATUS make_file_device_path(EFI_HANDLE device, const char16_t *file, EFI_DEVICE_PATH **ret_dp); + +#if defined(__i386__) || defined(__x86_64__) +bool in_hypervisor(void); +#else +static inline bool in_hypervisor(void) { + return false; +} +#endif |