diff options
author | Feng Kan <fkan@apm.com> | 2015-03-18 20:03:55 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2015-03-19 14:22:03 -0400 |
commit | 92b5bf989547b36c75231e4c24d0e2c351d3a0bc (patch) | |
tree | 6652e01d769ccd56af4893519a15e183327343ed | |
parent | 3661aa99d82ed06e3781964d43d89be1050593c0 (diff) |
sata: xgene: add ACPI support for APM X-Gene SATA ports
This adds ACPI support for the APM X-Gene SATA ports. When the system
boots using ACPI table, the SATA ports are able to configure using the
values supplied by the ACPI table rather than the DTS.
Signed-off-by: Feng Kan <fkan@apm.com>
Reviewed-by: Hanjun Guo <hanjun.guo@linaro.org>
Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
-rw-r--r-- | drivers/ata/ahci_xgene.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/ata/ahci_xgene.c b/drivers/ata/ahci_xgene.c index 2e8bb603e447..2b78510d94dd 100644 --- a/drivers/ata/ahci_xgene.c +++ b/drivers/ata/ahci_xgene.c | |||
@@ -22,6 +22,7 @@ | |||
22 | * NOTE: PM support is not currently available. | 22 | * NOTE: PM support is not currently available. |
23 | * | 23 | * |
24 | */ | 24 | */ |
25 | #include <linux/acpi.h> | ||
25 | #include <linux/module.h> | 26 | #include <linux/module.h> |
26 | #include <linux/platform_device.h> | 27 | #include <linux/platform_device.h> |
27 | #include <linux/ahci_platform.h> | 28 | #include <linux/ahci_platform.h> |
@@ -718,6 +719,14 @@ disable_resources: | |||
718 | return rc; | 719 | return rc; |
719 | } | 720 | } |
720 | 721 | ||
722 | #ifdef CONFIG_ACPI | ||
723 | static const struct acpi_device_id xgene_ahci_acpi_match[] = { | ||
724 | { "APMC0D0D", }, | ||
725 | { } | ||
726 | }; | ||
727 | MODULE_DEVICE_TABLE(acpi, xgene_ahci_acpi_match); | ||
728 | #endif | ||
729 | |||
721 | static const struct of_device_id xgene_ahci_of_match[] = { | 730 | static const struct of_device_id xgene_ahci_of_match[] = { |
722 | {.compatible = "apm,xgene-ahci"}, | 731 | {.compatible = "apm,xgene-ahci"}, |
723 | {}, | 732 | {}, |
@@ -730,6 +739,7 @@ static struct platform_driver xgene_ahci_driver = { | |||
730 | .driver = { | 739 | .driver = { |
731 | .name = DRV_NAME, | 740 | .name = DRV_NAME, |
732 | .of_match_table = xgene_ahci_of_match, | 741 | .of_match_table = xgene_ahci_of_match, |
742 | .acpi_match_table = ACPI_PTR(xgene_ahci_acpi_match), | ||
733 | }, | 743 | }, |
734 | }; | 744 | }; |
735 | 745 | ||