diff options
author | Hanjun Guo | 2020-09-18 17:13:28 +0800 |
---|---|---|
committer | Rafael J. Wysocki | 2020-09-25 18:08:39 +0200 |
commit | 9a2e849fb6de471b82d19989a7944d3b7671793c (patch) | |
tree | 7238d5e34f5162406a4ecc7f5b32239420d53d4b /drivers/acpi | |
parent | ba4f184e126b751d1bffad5897f263108befc780 (diff) |
ACPI: configfs: Add missing config_item_put() to fix refcount leak
config_item_put() should be called in the drop_item callback, to
decrement refcount for the config item.
Fixes: 772bf1e2878ec ("ACPI: configfs: Unload SSDT on configfs entry removal")
Signed-off-by: Hanjun Guo <guohanjun@huawei.com>
[ rjw: Subject edit ]
Cc: 4.13+ <stable@vger.kernel.org> # 4.13+
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r-- | drivers/acpi/acpi_configfs.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/acpi/acpi_configfs.c b/drivers/acpi/acpi_configfs.c index 88c8af455ea3..cf91f49101ea 100644 --- a/drivers/acpi/acpi_configfs.c +++ b/drivers/acpi/acpi_configfs.c @@ -228,6 +228,7 @@ static void acpi_table_drop_item(struct config_group *group, ACPI_INFO(("Host-directed Dynamic ACPI Table Unload")); acpi_unload_table(table->index); + config_item_put(cfg); } static struct configfs_group_operations acpi_table_group_ops = { |