diff options
author | Mathias Krause <minipli@googlemail.com> | 2015-06-13 08:26:55 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2015-06-15 08:23:44 -0400 |
commit | 048d16da75cc3ae1a75455c0e7b2bf107c4f0f84 (patch) | |
tree | b251c007186521df5075fc3825d9021e8717b0e5 /drivers/acpi/battery.c | |
parent | 27059b9132880f4211c41dfbf7665671cbf1ac91 (diff) |
ACPI / battery: mark DMI table as __initconst
The bat_dmi_table[] DMI table is referenced from the __init function
acpi_battery_init_async() only. It and its referenced functions can
therefore be marked __initconst to free up ~1kB of runtime memory after
initialization is done.
Signed-off-by: Mathias Krause <minipli@googlemail.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/battery.c')
-rw-r--r-- | drivers/acpi/battery.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/acpi/battery.c b/drivers/acpi/battery.c index c918c01c5ae6..b3628cc01a53 100644 --- a/drivers/acpi/battery.c +++ b/drivers/acpi/battery.c | |||
@@ -1124,19 +1124,21 @@ static int battery_notify(struct notifier_block *nb, | |||
1124 | return 0; | 1124 | return 0; |
1125 | } | 1125 | } |
1126 | 1126 | ||
1127 | static int battery_bix_broken_package_quirk(const struct dmi_system_id *d) | 1127 | static int __init |
1128 | battery_bix_broken_package_quirk(const struct dmi_system_id *d) | ||
1128 | { | 1129 | { |
1129 | battery_bix_broken_package = 1; | 1130 | battery_bix_broken_package = 1; |
1130 | return 0; | 1131 | return 0; |
1131 | } | 1132 | } |
1132 | 1133 | ||
1133 | static int battery_notification_delay_quirk(const struct dmi_system_id *d) | 1134 | static int __init |
1135 | battery_notification_delay_quirk(const struct dmi_system_id *d) | ||
1134 | { | 1136 | { |
1135 | battery_notification_delay_ms = 1000; | 1137 | battery_notification_delay_ms = 1000; |
1136 | return 0; | 1138 | return 0; |
1137 | } | 1139 | } |
1138 | 1140 | ||
1139 | static struct dmi_system_id bat_dmi_table[] = { | 1141 | static const struct dmi_system_id bat_dmi_table[] __initconst = { |
1140 | { | 1142 | { |
1141 | .callback = battery_bix_broken_package_quirk, | 1143 | .callback = battery_bix_broken_package_quirk, |
1142 | .ident = "NEC LZ750/LS", | 1144 | .ident = "NEC LZ750/LS", |