Angel Pons has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/46974 )
Change subject: soc/intel/broadwell: Shorten LPT/WPT _HID choosing methods ......................................................................
soc/intel/broadwell: Shorten LPT/WPT _HID choosing methods
Use a macro for brevity's sake.
Tested with BUILD_TIMELESS=1, Purism Librem 13 v1 remains identical.
Change-Id: Ic8cf732036131f962402e5f549d9164664038d73 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M src/soc/intel/broadwell/pch/acpi/serialio.asl 1 file changed, 16 insertions(+), 70 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/74/46974/1
diff --git a/src/soc/intel/broadwell/pch/acpi/serialio.asl b/src/soc/intel/broadwell/pch/acpi/serialio.asl index 1e6dbac..10da356 100644 --- a/src/soc/intel/broadwell/pch/acpi/serialio.asl +++ b/src/soc/intel/broadwell/pch/acpi/serialio.asl @@ -5,6 +5,15 @@ // Serial IO Device BAR0 and BAR1 is 4KB #define SIO_BAR_LEN 0x1000
+// Generate a method object that returns different values for LPT and WPT +#define DYNAMIC_NAME(obj_name, lpt_id, wpt_id) \ + Method (obj_name) { \ + If (\ISWP ()) { \ + Return (wpt_id) \ + } \ + Return (lpt_id) \ + } + // Put SerialIO device in D0 state // Arg0 - Ref to offset 0x84 of device's PCI config space Method (LPD0, 1, Serialized) @@ -156,16 +165,7 @@ Device (I2C0) { // Serial IO I2C0 Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3432") - } - - // LynxPoint-LP - Return ("INT33C2") - } + DYNAMIC_NAME (_HID, "INT33C2", "INT3432") Name (_CID, "INT33C2") Name (_UID, 1)
@@ -233,16 +233,7 @@ Device (I2C1) { // Serial IO I2C1 Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3433") - } - - // LynxPoint-LP - Return ("INT33C3") - } + DYNAMIC_NAME (_HID, "INT33C3", "INT3433") Name (_CID, "INT33C3") Name (_UID, 1)
@@ -310,16 +301,7 @@ Device (SPI0) { // Serial IO SPI0 Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3430") - } - - // LynxPoint-LP - Return ("INT33C0") - } + DYNAMIC_NAME (_HID, "INT33C0", "INT3430") Name (_CID, "INT33C0") Name (_UID, 1)
@@ -372,16 +354,7 @@ Device (SPI1) { // Serial IO SPI1 Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3431") - } - - // LynxPoint-LP - Return ("INT33C1") - } + DYNAMIC_NAME (_HID, "INT33C1", "INT3431") Name (_CID, "INT33C1") Name (_UID, 1)
@@ -446,16 +419,7 @@ Device (UAR0) { // Serial IO UART0 Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3434") - } - - // LynxPoint-LP - Return ("INT33C4") - } + DYNAMIC_NAME (_HID, "INT33C4", "INT3434") Name (_CID, "INT33C4") Name (_UID, 1)
@@ -520,16 +484,7 @@ Device (UAR1) { // Serial IO UART1 Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3435") - } - - // LynxPoint-LP - Return ("INT33C5") - } + DYNAMIC_NAME (_HID, "INT33C5", "INT3435") Name (_CID, "INT33C5") Name (_UID, 1)
@@ -582,16 +537,7 @@ Device (SDIO) { // Serial IO SDIO Controller - Method (_HID) - { - If (\ISWP ()) { - // WildcatPoint - Return ("INT3436") - } - - // LynxPoint-LP - Return ("INT33C6") - } + DYNAMIC_NAME (_HID, "INT33C6", "INT3436") Name (_CID, "PNP0D40") Name (_UID, 1)
Hello build bot (Jenkins), Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/46974
to look at the new patch set (#4).
Change subject: soc/intel/broadwell: Shorten LPT/WPT _HID choosing methods ......................................................................
soc/intel/broadwell: Shorten LPT/WPT _HID choosing methods
Use a macro for brevity's sake.
Tested with BUILD_TIMELESS=1, Purism Librem 13 v1 remains identical.
Change-Id: Ic8cf732036131f962402e5f549d9164664038d73 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M src/soc/intel/broadwell/pch/acpi/serialio.asl 1 file changed, 16 insertions(+), 70 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/74/46974/4