summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/acpica
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2017-06-09 20:36:31 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2017-06-22 02:43:12 +0200
commit772bf1e2878ecfca0d1f332071c83e021dd9cf01 (patch)
tree432cea90575ff9277a72960e7eea4bc988e6c138 /drivers/acpi/acpica
parent41f1830f5a7af77cf5c86359aba3cbd706687e52 (diff)
downloadlinux-0-day-772bf1e2878ecfca0d1f332071c83e021dd9cf01.tar.gz
linux-0-day-772bf1e2878ecfca0d1f332071c83e021dd9cf01.tar.xz
ACPI: configfs: Unload SSDT on configfs entry removal
Call directly into acpica to load a table to obtain its index on return. We choose the direct call of acpica internal functions to avoid having to modify its API which is used outside of Linux as well. Use that index to unload the table again when the corresponding directory in configfs gets removed. This allows to change SSDTs without rebooting the system. It also allows to destroy devices again that a dynamically loaded SSDT created. This is widely similar to the DT overlay behavior. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/acpica')
-rw-r--r--drivers/acpi/acpica/tbdata.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/acpi/acpica/tbdata.c b/drivers/acpi/acpica/tbdata.c
index 27c5c27d48181..c9d6fa6d7cc6f 100644
--- a/drivers/acpi/acpica/tbdata.c
+++ b/drivers/acpi/acpica/tbdata.c
@@ -867,6 +867,8 @@ exit:
return_ACPI_STATUS(status);
}
+ACPI_EXPORT_SYMBOL(acpi_tb_install_and_load_table)
+
/*******************************************************************************
*
* FUNCTION: acpi_tb_unload_table
@@ -914,3 +916,5 @@ acpi_status acpi_tb_unload_table(u32 table_index)
acpi_tb_set_table_loaded_flag(table_index, FALSE);
return_ACPI_STATUS(status);
}
+
+ACPI_EXPORT_SYMBOL(acpi_tb_unload_table)