diff options
| author | David E. Box <[email protected]> | 2023-11-29 22:21:14 +0000 |
|---|---|---|
| committer | Hans de Goede <[email protected]> | 2023-12-04 13:53:23 +0000 |
| commit | ace7b6f00870cea56460df335606e35ace3c07ac (patch) | |
| tree | ac47ec8cfe47e6134621ceb5cf0595454216e268 /drivers/platform/x86/intel/vsec.c | |
| parent | platform/x86/intel/vsec: Fix xa_alloc memory leak (diff) | |
| download | kernel-ace7b6f00870cea56460df335606e35ace3c07ac.tar.gz kernel-ace7b6f00870cea56460df335606e35ace3c07ac.zip | |
platform/x86/intel/vsec: Remove unnecessary return
In intel_vsec_add_aux(), just return from the last call to
devm_add_action_or_reset() instead of checking its return value.
Suggested-by: Ilpo Järvinen <[email protected]>
Signed-off-by: David E. Box <[email protected]>
Reviewed-by: Ilpo Järvinen <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Hans de Goede <[email protected]>
Diffstat (limited to 'drivers/platform/x86/intel/vsec.c')
| -rw-r--r-- | drivers/platform/x86/intel/vsec.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/platform/x86/intel/vsec.c b/drivers/platform/x86/intel/vsec.c index 343ab6a82c01..25017227a0a6 100644 --- a/drivers/platform/x86/intel/vsec.c +++ b/drivers/platform/x86/intel/vsec.c @@ -175,12 +175,8 @@ int intel_vsec_add_aux(struct pci_dev *pdev, struct device *parent, return ret; } - ret = devm_add_action_or_reset(parent, intel_vsec_remove_aux, + return devm_add_action_or_reset(parent, intel_vsec_remove_aux, auxdev); - if (ret < 0) - return ret; - - return 0; } EXPORT_SYMBOL_NS_GPL(intel_vsec_add_aux, INTEL_VSEC); |
