summaryrefslogtreecommitdiff
path: root/src/mainboard/google/parrot
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2015-04-24 16:05:58 +0300
committerKyösti Mälkki <kyosti.malkki@gmail.com>2015-05-05 17:56:24 +0200
commitb9cd5ece14f0aeaa713299d114fcdca46276acf9 (patch)
tree040a8d4983bf2919b97424d10d6579938cbcec19 /src/mainboard/google/parrot
parent168eda5f0d26a233bd997e0b0597926e80df57a3 (diff)
sandy/ivy boards: Rename defines from onboard.h for ACPI
Adopted style from later Chromebooks. Change-Id: I4993b8f40489b6bf5d08e00089f36f293853629e Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/9992 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Diffstat (limited to 'src/mainboard/google/parrot')
-rw-r--r--src/mainboard/google/parrot/acpi/mainboard.asl16
-rw-r--r--src/mainboard/google/parrot/mainboard.c12
-rw-r--r--src/mainboard/google/parrot/onboard.h10
3 files changed, 23 insertions, 15 deletions
diff --git a/src/mainboard/google/parrot/acpi/mainboard.asl b/src/mainboard/google/parrot/acpi/mainboard.asl
index 503e44b620..9116c69ccd 100644
--- a/src/mainboard/google/parrot/acpi/mainboard.asl
+++ b/src/mainboard/google/parrot/acpi/mainboard.asl
@@ -19,6 +19,8 @@
* MA 02110-1301 USA
*/
+#include <mainboard/google/parrot/onboard.h>
+
Scope (\_GPE) {
Method(_L1F, 0x0, NotSerialized)
{
@@ -59,19 +61,25 @@ Scope (\_SB) {
Name(_HID, EisaId("PNP0C0E"))
// Trackpad Wake is GPIO12, wake from S3
- Name(_PRW, Package(){0x1c, 0x03})
+ Name(_PRW, Package() { BOARD_TRACKPAD_WAKE_GPIO, 0x03 })
Name(_CRS, ResourceTemplate()
{
// PIRQA -> GSI16
- Interrupt (ResourceConsumer, Level, ActiveLow) {16}
+ Interrupt (ResourceConsumer, Level, ActiveLow)
+ {
+ BOARD_TRACKPAD_IRQ_DVT
+ }
// PIRQE -> GSI20
- Interrupt (ResourceConsumer, Edge, ActiveLow) {20}
+ Interrupt (ResourceConsumer, Edge, ActiveLow)
+ {
+ BOARD_TRACKPAD_IRQ_PVT
+ }
// SMBUS Address 0x67
- VendorShort (ADDR) {0x67}
+ VendorShort (ADDR) { BOARD_TRACKPAD_I2C_ADDR }
})
}
diff --git a/src/mainboard/google/parrot/mainboard.c b/src/mainboard/google/parrot/mainboard.c
index 547680e7e2..39d2c8428f 100644
--- a/src/mainboard/google/parrot/mainboard.c
+++ b/src/mainboard/google/parrot/mainboard.c
@@ -62,19 +62,19 @@ static int parrot_onboard_smbios_data(device_t dev, int *handle,
if (hardware_version < 0x2) { /* DVT vs PVT */
len += smbios_write_type41(
current, handle,
- PARROT_TRACKPAD_NAME, /* name */
- PARROT_TRACKPAD_IRQ_DVT, /* instance */
+ BOARD_TRACKPAD_NAME, /* name */
+ BOARD_TRACKPAD_IRQ_DVT, /* instance */
0, /* segment */
- PARROT_TRACKPAD_I2C_ADDR, /* bus */
+ BOARD_TRACKPAD_I2C_ADDR, /* bus */
0, /* device */
0); /* function */
} else {
len += smbios_write_type41(
current, handle,
- PARROT_TRACKPAD_NAME, /* name */
- PARROT_TRACKPAD_IRQ_PVT, /* instance */
+ BOARD_TRACKPAD_NAME, /* name */
+ BOARD_TRACKPAD_IRQ_PVT, /* instance */
0, /* segment */
- PARROT_TRACKPAD_I2C_ADDR, /* bus */
+ BOARD_TRACKPAD_I2C_ADDR, /* bus */
0, /* device */
0); /* function */
}
diff --git a/src/mainboard/google/parrot/onboard.h b/src/mainboard/google/parrot/onboard.h
index f3d200d54e..1f878afc59 100644
--- a/src/mainboard/google/parrot/onboard.h
+++ b/src/mainboard/google/parrot/onboard.h
@@ -20,10 +20,10 @@
#ifndef PARROT_ONBOARD_H
#define PARROT_ONBOARD_H
-#include <arch/smp/mpspec.h>
+#define BOARD_TRACKPAD_NAME "trackpad"
+#define BOARD_TRACKPAD_I2C_ADDR 0x67
+#define BOARD_TRACKPAD_IRQ_DVT 16
+#define BOARD_TRACKPAD_IRQ_PVT 20
+#define BOARD_TRACKPAD_WAKE_GPIO 0x1c
-#define PARROT_TRACKPAD_NAME "trackpad"
-#define PARROT_TRACKPAD_I2C_ADDR 0x67
-#define PARROT_TRACKPAD_IRQ_DVT 16
-#define PARROT_TRACKPAD_IRQ_PVT 20
#endif