From a40b7f3e1d637c01a29f7e7fe05201c5d61f428f Mon Sep 17 00:00:00 2001 From: Duncan Laurie Date: Thu, 13 Aug 2015 12:27:56 -0700 Subject: glados: Add touchscreen device in ACPI Add the ELAN touchscreen device in ACPI to bind it to the I2C device at bus I2C0, address 0x10, interrupt 31 (GPP_E7). BUG=chrome-os-partner:43514 BRANCH=none TEST=boot on glados P2 and see touchscreen initialized by kernel Original-Change-Id: I23b071b2767547baed239c94216cda6162d045dd Original-Signed-off-by: Duncan Laurie Original-Reviewed-on: https://chromium-review.googlesource.com/293512 Original-Reviewed-by: Aaron Durbin Change-Id: I8a9492e6fa1f650cef0871329ae8944caffdaf5a Signed-off-by: Duncan Laurie Reviewed-on: http://review.coreboot.org/11278 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi --- src/mainboard/google/glados/acpi/mainboard.asl | 35 ++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) (limited to 'src') diff --git a/src/mainboard/google/glados/acpi/mainboard.asl b/src/mainboard/google/glados/acpi/mainboard.asl index f955bb7d32..e2a1b5f0f8 100644 --- a/src/mainboard/google/glados/acpi/mainboard.asl +++ b/src/mainboard/google/glados/acpi/mainboard.asl @@ -22,6 +22,9 @@ #define BOARD_TOUCHPAD_I2C_ADDR 0x15 #define BOARD_TOUCHPAD_IRQ GPP_B3_IRQ +#define BOARD_TOUCHSCREEN_I2C_ADDR 0x10 +#define BOARD_TOUCHSCREEN_IRQ GPP_E7_IRQ + #define BOARD_HP_MIC_CODEC_I2C_ADDR 0x1a #define BOARD_LEFT_SPEAKER_AMP_I2C_ADDR 0x34 #define BOARD_RIGHT_SPEAKER_AMP_I2C_ADDR 0x35 @@ -72,6 +75,38 @@ Scope (\_SB.PCI0.LPCB) #include } +Scope (\_SB.PCI0.I2C0) +{ + /* Touchscreen */ + Device (ELTS) + { + Name (_HID, "ELAN0001") + Name (_DDN, "Elan Touchscreen") + Name (_UID, 1) + Name (_S0W, 4) + + Name (_CRS, ResourceTemplate() + { + I2cSerialBus ( + BOARD_TOUCHSCREEN_I2C_ADDR, + ControllerInitiated, + 400000, + AddressingMode7Bit, + "\\_SB.PCI0.I2C0", + ) + Interrupt (ResourceConsumer, Edge, ActiveLow) + { + BOARD_TOUCHSCREEN_IRQ + } + }) + + Method (_STA) + { + Return (0xF) + } + } +} + Scope (\_SB.PCI0.I2C1) { /* Touchpad */ -- cgit v1.2.3