summaryrefslogtreecommitdiffstats
path: root/recipes-kernel/linux/linux-hierofalcon/412-2-styx-linux-tracking.git-390adff766de2d7117ec666674d114dfd5b5a911.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-kernel/linux/linux-hierofalcon/412-2-styx-linux-tracking.git-390adff766de2d7117ec666674d114dfd5b5a911.patch')
-rw-r--r--recipes-kernel/linux/linux-hierofalcon/412-2-styx-linux-tracking.git-390adff766de2d7117ec666674d114dfd5b5a911.patch90
1 files changed, 90 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-hierofalcon/412-2-styx-linux-tracking.git-390adff766de2d7117ec666674d114dfd5b5a911.patch b/recipes-kernel/linux/linux-hierofalcon/412-2-styx-linux-tracking.git-390adff766de2d7117ec666674d114dfd5b5a911.patch
new file mode 100644
index 0000000..20d6b7b
--- /dev/null
+++ b/recipes-kernel/linux/linux-hierofalcon/412-2-styx-linux-tracking.git-390adff766de2d7117ec666674d114dfd5b5a911.patch
@@ -0,0 +1,90 @@
1From c6824811936cbbdb9a13100b23b2f39b307b571f Mon Sep 17 00:00:00 2001
2From: Adrian Calianu <adrian.calianu@enea.com>
3Date: Mon, 10 Aug 2015 17:28:23 +0200
4Subject: [PATCH] Subject: [PATCH] ata: ahci_platform: Add ACPI _CLS matching
5
6Ported from 3.19 kernel:
7
8This patch adds ACPI supports for AHCI platform driver, which uses _CLS
9method to match the device.
10
11The following is an example of ASL structure in DSDT for a SATA controller,
12which contains _CLS package to be matched by the ahci_platform driver:
13
14 Device (AHC0) // AHCI Controller
15 {
16 Name(_HID, "AMDI0600")
17 Name (_CCA, 1)
18 Name (_CLS, Package (3)
19 {
20 0x01, // Base Class: Mass Storage
21 0x06, // Sub-Class: serial ATA
22 0x01, // Interface: AHCI
23 })
24 Name (_CRS, ResourceTemplate ()
25 {
26 Memory32Fixed (ReadWrite, 0xE0300000, 0x00010000)
27 Interrupt (ResourceConsumer, Level, ActiveHigh, Exclusive,,,) { 387 }
28 })
29 }
30
31Also, since ATA driver should not require PCI support for ATA_ACPI,
32this patch removes dependency in the driver/ata/Kconfig.
33
34Signed-off-by: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com>
35
36Signed-off-by: Adrian Calianu <adrian.calianu@enea.com>
37---
38 drivers/ata/Kconfig | 2 +-
39 drivers/ata/ahci_platform.c | 9 +++++++++
40 2 files changed, 10 insertions(+), 1 deletion(-)
41
42diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig
43index 9dca4b9..7954ea2 100644
44--- a/drivers/ata/Kconfig
45+++ b/drivers/ata/Kconfig
46@@ -48,7 +48,7 @@ config ATA_VERBOSE_ERROR
47
48 config ATA_ACPI
49 bool "ATA ACPI Support"
50- depends on ACPI && PCI
51+ depends on ACPI
52 default y
53 help
54 This option adds support for ATA-related ACPI objects.
55diff --git a/drivers/ata/ahci_platform.c b/drivers/ata/ahci_platform.c
56index 78d6ae0..c0c055d 100644
57--- a/drivers/ata/ahci_platform.c
58+++ b/drivers/ata/ahci_platform.c
59@@ -20,6 +20,8 @@
60 #include <linux/platform_device.h>
61 #include <linux/libata.h>
62 #include <linux/ahci_platform.h>
63+#include <linux/acpi.h>
64+#include <linux/pci_ids.h>
65 #include "ahci.h"
66
67 #define DRV_NAME "ahci"
68@@ -78,12 +80,19 @@ static const struct of_device_id ahci_of_match[] = {
69 };
70 MODULE_DEVICE_TABLE(of, ahci_of_match);
71
72+static const struct acpi_device_id ahci_acpi_match[] = {
73+ { "", 0, PCI_CLASS_STORAGE_SATA_AHCI },
74+ {},
75+};
76+MODULE_DEVICE_TABLE(acpi, ahci_acpi_match);
77+
78 static struct platform_driver ahci_driver = {
79 .probe = ahci_probe,
80 .remove = ata_platform_remove_one,
81 .driver = {
82 .name = DRV_NAME,
83 .of_match_table = ahci_of_match,
84+ .acpi_match_table = ahci_acpi_match,
85 .pm = &ahci_pm_ops,
86 },
87 };
88--
891.9.1
90