falco: Add ACPI code to describe the I2C touchpad device
If the SerialIO devices are put into ACPI mode then it is possible to use ACPI to instantiate the touchpad in the kernel without needing to have a platform level driver to do the binding. This is the "new way" of describing on-board I2C devices and the upstream kernel is starting to add ACPI IDs to drivers so they can be used in this fashion. For the Cypress touchpad use a generic ACPI ID of "CYPA0000" to describe it. In order to support the proper scoping of the touchpad device under the appropriate I2C controller device the mainboard.asl file needs to be included after pch.asl so the I2C device exists. Change-Id: I81e053d27be478f3a19b6f9b13cd2b4fabcb88c0 Signed-off-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-on: http://review.coreboot.org/5194 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
This commit is contained in:
parent
6c03160d48
commit
b3b008a9b6
|
@ -108,3 +108,37 @@ Scope (\_SB)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Scope (\_SB.PCI0.I2C0)
|
||||||
|
{
|
||||||
|
Device (CYPA)
|
||||||
|
{
|
||||||
|
Name (_HID, "CYPA0000")
|
||||||
|
Name (_DDN, "Cypress Touchpad")
|
||||||
|
Name (_UID, 1)
|
||||||
|
|
||||||
|
Name (_CRS, ResourceTemplate()
|
||||||
|
{
|
||||||
|
I2cSerialBus (
|
||||||
|
BOARD_TRACKPAD_I2C_ADDR, // SlaveAddress
|
||||||
|
ControllerInitiated, // SlaveMode
|
||||||
|
400000, // ConnectionSpeed
|
||||||
|
AddressingMode7Bit, // AddressingMode
|
||||||
|
"\\_SB.PCI0.I2C0", // ResourceSource
|
||||||
|
)
|
||||||
|
Interrupt (ResourceConsumer, Edge, ActiveLow)
|
||||||
|
{
|
||||||
|
BOARD_TRACKPAD_IRQ
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
Method (_STA)
|
||||||
|
{
|
||||||
|
If (LEqual (\S1EN, 1)) {
|
||||||
|
Return (0xF)
|
||||||
|
} Else {
|
||||||
|
Return (0x0)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -31,7 +31,6 @@ DefinitionBlock(
|
||||||
{
|
{
|
||||||
// Some generic macros
|
// Some generic macros
|
||||||
#include "acpi/platform.asl"
|
#include "acpi/platform.asl"
|
||||||
#include "acpi/mainboard.asl"
|
|
||||||
|
|
||||||
// global NVS and variables
|
// global NVS and variables
|
||||||
#include <southbridge/intel/lynxpoint/acpi/globalnvs.asl>
|
#include <southbridge/intel/lynxpoint/acpi/globalnvs.asl>
|
||||||
|
@ -50,6 +49,9 @@ DefinitionBlock(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mainboard specific
|
||||||
|
#include "acpi/mainboard.asl"
|
||||||
|
|
||||||
// Thermal handler
|
// Thermal handler
|
||||||
#include "acpi/thermal.asl"
|
#include "acpi/thermal.asl"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue