diff options
author | Yu Ning <yu.ning@intel.com> | 2016-03-01 23:46:10 +0000 |
---|---|---|
committer | Jin Qian <jinqian@google.com> | 2016-11-17 09:56:06 -0800 |
commit | 779a63ef878a4d8cd601e791fdf81df9fd5f953a (patch) | |
tree | 59947ccc6718b4cb6ca1906cec0ddcc98b0d832b | |
parent | b58abfa8bd400855bf09c84ae27dd2a4446c60f9 (diff) |
BACKPORT: goldfish: Enable ACPI-based enumeration for goldfish battery
Add the ACPI bindings to the goldfish battery driver.
Signed-off-by: Yu Ning <yu.ning@intel.com>
Signed-off-by: Jin Qian <jinqian@android.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>
(cherry picked from commit fdb2f37a54470473c6b7c9d680c4c114dd9bc434)
Change-Id: I3b53481b5868b0b26848397420c9ba16a747819f
-rw-r--r-- | drivers/power/goldfish_battery.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/power/goldfish_battery.c b/drivers/power/goldfish_battery.c index 7510796e190c..f5c525e4482a 100644 --- a/drivers/power/goldfish_battery.c +++ b/drivers/power/goldfish_battery.c @@ -24,6 +24,7 @@ #include <linux/pci.h> #include <linux/interrupt.h> #include <linux/io.h> +#include <linux/acpi.h> struct goldfish_battery_data { void __iomem *reg_base; @@ -233,12 +234,19 @@ static const struct of_device_id goldfish_battery_of_match[] = { }; MODULE_DEVICE_TABLE(of, goldfish_battery_of_match); +static const struct acpi_device_id goldfish_battery_acpi_match[] = { + { "GFSH0001", 0 }, + { }, +}; +MODULE_DEVICE_TABLE(acpi, goldfish_battery_acpi_match); + static struct platform_driver goldfish_battery_device = { .probe = goldfish_battery_probe, .remove = goldfish_battery_remove, .driver = { .name = "goldfish-battery", .of_match_table = goldfish_battery_of_match, + .acpi_match_table = ACPI_PTR(goldfish_battery_acpi_match), } }; module_platform_driver(goldfish_battery_device); |