Cleanups before decoupling ACPICA debug with ACPI driver
Subsystems (3)
v2 cover Cleanups before decoupling ACPICA debug with ACPI driver
With the evolution of the ACPI driver code, lots of the ACPICA debug functions such as ACPI_DEBUG_PRINT() used in ACPI drivers were removed away, this makes some of the ACPICA debug code in ACPI driver as dead, for example, _COMPONENT and ACPI_MODULE_NAME() are useless without ACPICA debug functions.
This patch set will cleanup those dead code before decoupling ACPICA debug with ACPI driver, should be no functional change.
v1->v2:
- Remove patches that not for ACPICA debug cleanups, send them seperately, this patch set only contains cleanups for ACPICA debug functionality.
Hanjun Guo (15):
ACPI: cmos_rtc: Remove the leftover ACPICA code ACPI_MODULE_NAME()
ACPI: LPSS: Remove the ACPI_MODULE_NAME()
ACPI: memhotplug: Remove the leftover ACPICA debug functionality
ACPI: platform: Remove the ACPI_MODULE_NAME()
ACPI: container: Remove the leftover ACPICA debug functionality
ACPI: custom_method: Remove the dead ACPICA debug code
ACPI: debugfs: Remove the dead ACPICA debug code
ACPI: dock: Remove the dead ACPICA debug code
ACPI: event: Remove the leftover ACPICA debug code
ACPI: PCI: Remove the unused ACPICA debug code
ACPI: proc: Remove the dead ACPICA debug code
ACPI: processor: Remove the dead ACPICA debug code
ACPI: tiny-power-button: Remove the dead ACPICA debug code
ACPI: video: Remove the leftover ACPICA debug code
ACPI: wakeup: Remove the dead ACPICA debug code
drivers/acpi/acpi_cmos_rtc.c | 2 -- drivers/acpi/acpi_lpss.c | 2 -- drivers/acpi/acpi_memhotplug.c | 7 ------- drivers/acpi/acpi_platform.c | 2 -- drivers/acpi/container.c | 3 --- drivers/acpi/custom_method.c | 2 -- drivers/acpi/debugfs.c | 3 --- drivers/acpi/dock.c | 2 -- drivers/acpi/event.c | 3 --- drivers/acpi/pci_root.c | 2 -- drivers/acpi/pci_slot.c | 3 --- drivers/acpi/proc.c | 4 ---- drivers/acpi/processor_core.c | 3 --- drivers/acpi/processor_thermal.c | 2 -- drivers/acpi/tiny-power-button.c | 1 - drivers/acpi/video_detect.c | 3 --- drivers/acpi/wakeup.c | 2 -- 17 files changed, 46 deletions(-)
Signature · 1 line
1.7.12.4
PATCH v2 1/15 ACPI: cmos_rtc: Remove the leftover ACPICA code ACPI_MODULE_NAME()
ACPI_MODULE_NAME() is only needed for ACPICA debug functionality such as ACPI_DEBUG_PRINT() which is not used in acpi_cmos_rtc.c, remove it.
--- drivers/acpi/acpi_cmos_rtc.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/acpi_cmos_rtc.c +0 -2
@@ -15,8 +15,6 @@#include "internal.h" -ACPI_MODULE_NAME ("cmos rtc" ); -static const struct acpi_device_id acpi_cmos_rtc_ids[] = { {"PNP0B00" }, {"PNP0B01" },
Signature · 1 line
1.7.12.4
PATCH v2 2/15 ACPI: LPSS: Remove the ACPI_MODULE_NAME()
In reply to Hanjun GuoACPI_MODULE_NAME() is only needed for ACPICA debug functionality such as ACPI_DEBUG_PRINT() which is not used in acpi_lpss.c, remove it.
--- drivers/acpi/acpi_lpss.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/acpi_lpss.c +0 -2
@@ -26,8 +26,6 @@#include "internal.h" -ACPI_MODULE_NAME ("acpi_lpss" ); -#ifdef CONFIG_X86_INTEL_LPSS #include <asm/cpu_device_id.h>
Signature · 1 line
1.7.12.4
PATCH v2 3/15 ACPI: memhotplug: Remove the leftover ACPICA debug functionality
In reply to Hanjun GuoAfter commit 0a34764411aa ("ACPI / scan: Make memory hotplug drive use struct acpi_scan_handler"), all the ACPICA debug functionality was removed, remove the leftover ACPICA debug code.
--- drivers/acpi/acpi_memhotplug.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/acpi/acpi_memhotplug.c +0 -7
@@ -22,13 +22,6 @@#define ACPI_MEMORY_DEVICE_HID "PNP0C80"#define ACPI_MEMORY_DEVICE_NAME "Hotplug Mem Device" -#define _COMPONENT ACPI_MEMORY_DEVICE_COMPONENT - -#undef PREFIX -#define PREFIX "ACPI:memory_hp:" - -ACPI_MODULE_NAME ("acpi_memhotplug" ); -static const struct acpi_device_id memory_device_ids[] = { {ACPI_MEMORY_DEVICE_HID ,0 }, {"" ,0 },
Signature · 1 line
1.7.12.4
PATCH v2 4/15 ACPI: platform: Remove the ACPI_MODULE_NAME()
In reply to Hanjun GuoACPI_MODULE_NAME() is not used in the acpi_platform.c, remove it.
--- drivers/acpi/acpi_platform.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/acpi_platform.c +0 -2
@@ -19,8 +19,6 @@#include "internal.h" -ACPI_MODULE_NAME ("platform" ); -static const struct acpi_device_id forbidden_id_list[] = { {"PNP0000" ,0 },/* PIC */ {"PNP0100" ,0 },/* Timer */
Signature · 1 line
1.7.12.4
PATCH v2 5/15 ACPI: container: Remove the leftover ACPICA debug functionality
In reply to Hanjun GuoAfter commit 737f1a9f8082 ("ACPI / scan: Make container driver use struct acpi_scan_handler"), ACPICA debug print function calls were removed, so the leftover ACPICA debug functionality is useless, remove it.
--- drivers/acpi/container.c | 3 --- 1 file changed, 3 deletions(-)
drivers/acpi/container.c +0 -3
@@ -14,9 +14,6 @@#include "internal.h" -#define _COMPONENT ACPI_CONTAINER_COMPONENT -ACPI_MODULE_NAME ("container" ); -static const struct acpi_device_id container_device_ids[] = { {"ACPI0004" ,0 }, {"PNP0A05" ,0 },
Signature · 1 line
1.7.12.4
PATCH v2 6/15 ACPI: custom_method: Remove the dead ACPICA debug code
In reply to Hanjun GuoACPICA debug code _COMPONENT and ACPI_MODULE_NAME() is not used in custom_method.c, remove it.
--- drivers/acpi/custom_method.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/custom_method.c +0 -2
@@ -13,8 +13,6 @@#include "internal.h" -#define _COMPONENT ACPI_SYSTEM_COMPONENT -ACPI_MODULE_NAME ("custom_method" );MODULE_LICENSE ("GPL" );static struct dentry *cm_dentry;
Signature · 1 line
1.7.12.4
PATCH v2 7/15 ACPI: debugfs: Remove the dead ACPICA debug code
In reply to Hanjun GuoThe _COMPONENT and ACPI_MODULE_NAME() were not used even when the debugfs.c was introduced, remove it.
--- drivers/acpi/debugfs.c | 3 --- 1 file changed, 3 deletions(-)
drivers/acpi/debugfs.c +0 -3
@@ -10,9 +10,6 @@#include "internal.h" -#define _COMPONENT ACPI_SYSTEM_COMPONENT -ACPI_MODULE_NAME ("debugfs" ); -struct dentry *acpi_debugfs_dir;EXPORT_SYMBOL_GPL (acpi_debugfs_dir);
Signature · 1 line
1.7.12.4
PATCH v2 8/15 ACPI: dock: Remove the dead ACPICA debug code
In reply to Hanjun GuoThe ACPICA debug code ACPI_MODULE_NAME() is not used, remove it.
--- drivers/acpi/dock.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/dock.c +0 -2
@@ -20,8 +20,6 @@#include "internal.h" -ACPI_MODULE_NAME ("dock" ); -static bool immediate_undock =1 ;module_param (immediate_undock, bool,0644 ); MODULE_PARM_DESC(immediate_undock, "1 (default) will cause the driver to "
Signature · 1 line
1.7.12.4
PATCH v2 9/15 ACPI: event: Remove the leftover ACPICA debug code
In reply to Hanjun GuoAfter commit (ff491a7334ac "netlink: change return-value logic of netlink_broadcast()"), ACPI_DEBUG_PRINT() was removed from event.c, so the ACPICA debug code is not used, remove it.
--- drivers/acpi/event.c | 3 --- 1 file changed, 3 deletions(-)
drivers/acpi/event.c +0 -3
@@ -19,9 +19,6 @@#include "internal.h" -#define _COMPONENT ACPI_SYSTEM_COMPONENT -ACPI_MODULE_NAME ("event" ); -/* ACPI notifier chain */ static BLOCKING_NOTIFIER_HEAD (acpi_chain_head);
Signature · 1 line
1.7.12.4
PATCH v2 10/15 ACPI: PCI: Remove the unused ACPICA debug code
In reply to Hanjun GuoThe ACPICA debug code _COMPONENT and ACPI_MODULE_NAME() are not used, so can be removed.
--- drivers/acpi/pci_root.c | 2 -- drivers/acpi/pci_slot.c | 3 --- 2 files changed, 5 deletions(-)
drivers/acpi/pci_root.c +0 -2
@@ -24,8 +24,6 @@#include "internal.h" -#define _COMPONENT ACPI_PCI_COMPONENT -ACPI_MODULE_NAME ("pci_root" );#define ACPI_PCI_ROOT_CLASS "pci_bridge"#define ACPI_PCI_ROOT_DEVICE_NAME "PCI Root Bridge" static int acpi_pci_root_add(struct acpi_device *device,
drivers/acpi/pci_slot.c +0 -3
@@ -28,9 +28,6 @@static int check_sta_before_sun; -#define _COMPONENT ACPI_PCI_COMPONENT -ACPI_MODULE_NAME ("pci_slot" ); -#define SLOT_NAME_SIZE 21/* Inspired by #define in acpiphp.h */ struct acpi_pci_slot {
Signature · 1 line
1.7.12.4
PATCH v2 11/15 ACPI: proc: Remove the dead ACPICA debug code
In reply to Hanjun GuoRemove the not used ACPICA debug code _COMPONENT and ACPI_MODULE_NAME() which were not used even when proc.c was introduced.
--- drivers/acpi/proc.c | 4 ---- 1 file changed, 4 deletions(-)
drivers/acpi/proc.c +0 -4
@@ -10,15 +10,11 @@#include "sleep.h" #include "internal.h" -#define _COMPONENT ACPI_SYSTEM_COMPONENT -/* * this file provides support for: * /proc/acpi/wakeup */ -ACPI_MODULE_NAME("sleep") -static int acpi_system_wakeup_device_seq_show (struct seq_file *seq,void *offset) {
Signature · 1 line
1.7.12.4
PATCH v2 12/15 ACPI: processor: Remove the dead ACPICA debug code
In reply to Hanjun GuoThe ACPICA debug code is not used anywhere in processor_core.c and processor_thermal.c, remove it.
--- drivers/acpi/processor_core.c | 3 --- drivers/acpi/processor_thermal.c | 2 -- 2 files changed, 5 deletions(-)
drivers/acpi/processor_core.c +0 -3
@@ -14,9 +14,6 @@#include <linux/acpi.h> #include <acpi/processor.h> -#define _COMPONENT ACPI_PROCESSOR_COMPONENT -ACPI_MODULE_NAME ("processor_core" ); -static struct acpi_table_madt *get_madt_table (void ) {static struct acpi_table_madt *madt;
drivers/acpi/processor_thermal.c +0 -2
@@ -20,8 +20,6 @@#define PREFIX "ACPI: "#define ACPI_PROCESSOR_CLASS "processor" -#define _COMPONENT ACPI_PROCESSOR_COMPONENT -ACPI_MODULE_NAME ("processor_thermal" );#ifdef CONFIG_CPU_FREQ
Signature · 1 line
1.7.12.4
PATCH v2 13/15 ACPI: tiny-power-button: Remove the dead ACPICA debug code
In reply to Hanjun GuoThe ACPICA debug code is not used, can be removed.
--- drivers/acpi/tiny-power-button.c | 1 - 1 file changed, 1 deletion(-)
drivers/acpi/tiny-power-button.c +0 -1
@@ -4,7 +4,6 @@#include <linux/acpi.h> #include <acpi/button.h> -ACPI_MODULE_NAME ("tiny-power-button" );MODULE_AUTHOR ("Josh Triplett" );MODULE_DESCRIPTION ("ACPI Tiny Power Button Driver" );MODULE_LICENSE ("GPL" );
Signature · 1 line
1.7.12.4
PATCH v2 14/15 ACPI: video: Remove the leftover ACPICA debug code
In reply to Hanjun GuoAfter commit (87521e16a7ab "acpi-video-detect: Rewrite backlight interface selection logic"), ACPI_DEBUG_PRINT() was remove, so ACPI_MODULE_NAME() and _COMPONENT are not used anymore, remove them.
--- drivers/acpi/video_detect.c | 3 --- 1 file changed, 3 deletions(-)
drivers/acpi/video_detect.c +0 -3
@@ -35,9 +35,6 @@#include <linux/workqueue.h> #include <acpi/video.h> -ACPI_MODULE_NAME ("video" ); -#define _COMPONENT ACPI_VIDEO_COMPONENT -void acpi_video_unregister_backlight (void );static bool backlight_notifier_registered;
Signature · 1 line
1.7.12.4
PATCH v2 15/15 ACPI: wakeup: Remove the dead ACPICA debug code
In reply to Hanjun GuoThe ACPICA debug code of ACPI_SYSTEM_COMPONENT and ACPI_MODULE_NAME() are not used in wakeup.c, remove it.
--- drivers/acpi/wakeup.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/wakeup.c +0 -2
@@ -26,8 +26,6 @@ struct acpi_wakeup_handler {* suspend/resume and isn't really required as this is called in S-state. At * that time, there is no device hotplug **/ -#define _COMPONENT ACPI_SYSTEM_COMPONENT -ACPI_MODULE_NAME ("wakeup_devices" )/** * acpi_enable_wakeup_devices - Enable wake-up device GPEs.
Signature · 1 line
1.7.12.4
Rafael J. Wysocki
maintainerQuoted 15 lines · Hanjun Guo
With the evolution of the ACPI driver code, lots of the ACPICA debug functions such as
ACPI_DEBUG_PRINT()used in ACPI drivers were removed away, this makes some of the ACPICA debug code in ACPI driver as dead, for example,_COMPONENTandACPI_MODULE_NAME()are useless without ACPICA debug functions.This patch set will cleanup those dead code before decoupling ACPICA debug with ACPI driver, should be no functional change.
v1->v2:
- Remove patches that not for ACPICA debug cleanups, send them seperately, this patch set only contains cleanups for ACPICA debug functionality.
Quoted 16 lines
Hanjun Guo (15):
ACPI:cmos_rtc: Remove the leftover ACPICA codeACPI_MODULE_NAME()
ACPI: LPSS: Remove theACPI_MODULE_NAME()
ACPI: memhotplug: Remove the leftover ACPICA debug functionality
ACPI: platform: Remove theACPI_MODULE_NAME()
ACPI: container: Remove the leftover ACPICA debug functionality
ACPI:custom_method: Remove the dead ACPICA debug code
ACPI: debugfs: Remove the dead ACPICA debug code
ACPI: dock: Remove the dead ACPICA debug code
ACPI: event: Remove the leftover ACPICA debug code
ACPI: PCI: Remove the unused ACPICA debug code
ACPI: proc: Remove the dead ACPICA debug code
ACPI: processor: Remove the dead ACPICA debug code
ACPI: tiny-power-button: Remove the dead ACPICA debug code
ACPI: video: Remove the leftover ACPICA debug code
ACPI: wakeup: Remove the dead ACPICA debug code
All applied as 5.10 material with minor subject and changelog edits, thanks!