Skip to content

Commit 3b224e0

Browse files
guohanjungregkh
authored andcommitted
ACPI: configfs: Add missing config_item_put() to fix refcount leak
commit 9a2e849 upstream. config_item_put() should be called in the drop_item callback, to decrement refcount for the config item. Fixes: 772bf1e ("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> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 36ed9e6 commit 3b224e0

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/acpi/acpi_configfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,7 @@ static void acpi_table_drop_item(struct config_group *group,
228228

229229
ACPI_INFO(("Host-directed Dynamic ACPI Table Unload"));
230230
acpi_unload_table(table->index);
231+
config_item_put(cfg);
231232
}
232233

233234
static struct configfs_group_operations acpi_table_group_ops = {

0 commit comments

Comments
 (0)