From ab65ea5db75d45f5363cf96c405b286052fdc4bc Mon Sep 17 00:00:00 2001 From: Mario Limonciello Date: Thu, 16 Sep 2021 00:55:28 -0500 Subject: [PATCH] trivial: uefi-recovery: only run the plugin if efivar is available This will cause it to disable on systems that are definitely not relevant. --- plugins/uefi-recovery/fu-plugin-uefi-recovery.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/plugins/uefi-recovery/fu-plugin-uefi-recovery.c b/plugins/uefi-recovery/fu-plugin-uefi-recovery.c index 63baed8f6..77f6bfff2 100644 --- a/plugins/uefi-recovery/fu-plugin-uefi-recovery.c +++ b/plugins/uefi-recovery/fu-plugin-uefi-recovery.c @@ -17,6 +17,15 @@ fu_plugin_init(FuPlugin *plugin) fu_plugin_add_flag(plugin, FWUPD_PLUGIN_FLAG_REQUIRE_HWID); } +gboolean +fu_plugin_startup(FuPlugin *plugin, GError **error) +{ + /* are the EFI dirs set up so we can update each device */ + if (!fu_efivar_supported(error)) + return FALSE; + return TRUE; +} + gboolean fu_plugin_coldplug(FuPlugin *plugin, GError **error) {