diff options
author | Alex Deucher <alexander.deucher@amd.com> | 2023-02-14 21:47:58 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2023-02-14 21:47:58 -0500 |
commit | 4792b2565deb5a629b5866bd3dd831b6ce53d3b5 (patch) | |
tree | 24be1b4dced55508400e742d96b1176297455ef7 /drivers/firmware | |
parent | 54f350bcde31b21b94ebaa2f11a5c9464c6fc0b2 (diff) | |
parent | 21e996306a6afaae88295858de0ffb8955173a15 (diff) | |
download | linux-4792b2565deb5a629b5866bd3dd831b6ce53d3b5.tar.gz |
Merge tag 'v6.1.7' into amd-staging-drm-next
This is the 6.1.7 stable release Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/firmware')
-rw-r--r-- | drivers/firmware/efi/efi.c | 9 | ||||
-rw-r--r-- | drivers/firmware/efi/runtime-wrappers.c | 1 | ||||
-rw-r--r-- | drivers/firmware/psci/psci.c | 3 |
3 files changed, 10 insertions, 3 deletions
diff --git a/drivers/firmware/efi/efi.c b/drivers/firmware/efi/efi.c index f12cc29bd4b8..033aac6be7da 100644 --- a/drivers/firmware/efi/efi.c +++ b/drivers/firmware/efi/efi.c @@ -374,8 +374,8 @@ static int __init efisubsys_init(void) efi_kobj = kobject_create_and_add("efi", firmware_kobj); if (!efi_kobj) { pr_err("efi: Firmware registration failed.\n"); - destroy_workqueue(efi_rts_wq); - return -ENOMEM; + error = -ENOMEM; + goto err_destroy_wq; } if (efi_rt_services_supported(EFI_RT_SUPPORTED_GET_VARIABLE | @@ -423,7 +423,10 @@ err_unregister: generic_ops_unregister(); err_put: kobject_put(efi_kobj); - destroy_workqueue(efi_rts_wq); +err_destroy_wq: + if (efi_rts_wq) + destroy_workqueue(efi_rts_wq); + return error; } diff --git a/drivers/firmware/efi/runtime-wrappers.c b/drivers/firmware/efi/runtime-wrappers.c index f3e54f6616f0..60075e0e4943 100644 --- a/drivers/firmware/efi/runtime-wrappers.c +++ b/drivers/firmware/efi/runtime-wrappers.c @@ -62,6 +62,7 @@ struct efi_runtime_work efi_rts_work; \ if (!efi_enabled(EFI_RUNTIME_SERVICES)) { \ pr_warn_once("EFI Runtime Services are disabled!\n"); \ + efi_rts_work.status = EFI_DEVICE_ERROR; \ goto exit; \ } \ \ diff --git a/drivers/firmware/psci/psci.c b/drivers/firmware/psci/psci.c index e7bcfca4159f..447ee4ea5c90 100644 --- a/drivers/firmware/psci/psci.c +++ b/drivers/firmware/psci/psci.c @@ -440,6 +440,9 @@ static const struct file_operations psci_debugfs_ops = { static int __init psci_debugfs_init(void) { + if (!invoke_psci_fn || !psci_ops.get_version) + return 0; + return PTR_ERR_OR_ZERO(debugfs_create_file("psci", 0444, NULL, NULL, &psci_debugfs_ops)); } |