diff options
author | Kane Chen <kane.chen@intel.com> | 2015-10-26 13:02:33 +0800 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2016-01-19 17:41:20 +0100 |
commit | 54093e4fce280faf85fcaa2f1d14833845895022 (patch) | |
tree | 70329e94f05d489afec7f4801c51cc79fc5d90b9 | |
parent | a1b3547f0f6e08ad2c83c0224e375217bf187120 (diff) | |
download | coreboot-54093e4fce280faf85fcaa2f1d14833845895022.tar.xz |
Braswell: add code to support customization of I2C data hold time
The I2C data hold time can be vary on different boards/devices.
So, it needs to be customized by boards/devices
TEST=compile ok and check IC_SDA_HOLD is changed if the hold time
is defined in onboard.h
Original-Reviewed-on: https://chromium-review.googlesource.com/308623
Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Change-Id: I66c799de400670916cebbcb529d4f59d5b0f081b
Signed-off-by: Kane Chen <kane.chen@intel.com>
Reviewed-on: https://review.coreboot.org/12740
Tested-by: build bot (Jenkins)
Reviewed-by: Martin Roth <martinroth@google.com>
-rw-r--r-- | src/soc/intel/braswell/acpi/lpss.asl | 59 |
1 files changed, 45 insertions, 14 deletions
diff --git a/src/soc/intel/braswell/acpi/lpss.asl b/src/soc/intel/braswell/acpi/lpss.asl index a2d5f3f73b..34d1e4ddeb 100644 --- a/src/soc/intel/braswell/acpi/lpss.asl +++ b/src/soc/intel/braswell/acpi/lpss.asl @@ -14,6 +14,37 @@ * GNU General Public License for more details. */ +/* The below definitions are used for customization + * Some boards/devices may need different data hold time + */ +#ifndef BOARD_I2C1_DATA_HOLD_TIME +#define BOARD_I2C1_DATA_HOLD_TIME 6 +#endif + +#ifndef BOARD_I2C2_DATA_HOLD_TIME +#define BOARD_I2C2_DATA_HOLD_TIME 6 +#endif + +#ifndef BOARD_I2C3_DATA_HOLD_TIME +#define BOARD_I2C3_DATA_HOLD_TIME 6 +#endif + +#ifndef BOARD_I2C4_DATA_HOLD_TIME +#define BOARD_I2C4_DATA_HOLD_TIME 6 +#endif + +#ifndef BOARD_I2C5_DATA_HOLD_TIME +#define BOARD_I2C5_DATA_HOLD_TIME 6 +#endif + +#ifndef BOARD_I2C6_DATA_HOLD_TIME +#define BOARD_I2C6_DATA_HOLD_TIME 6 +#endif + +#ifndef BOARD_I2C7_DATA_HOLD_TIME +#define BOARD_I2C7_DATA_HOLD_TIME 6 +#endif + Device (SDM1) { Name (_HID, "INTL9C60") @@ -85,10 +116,10 @@ Device (I2C1) Name (_DDN, "I2C Controller #1") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C1_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C1_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { @@ -144,10 +175,10 @@ Device (I2C2) Name (_DDN, "I2C Controller #2") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C2_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C2_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { @@ -203,10 +234,10 @@ Device (I2C3) Name (_DDN, "I2C Controller #3") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C3_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C3_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { @@ -262,10 +293,10 @@ Device (I2C4) Name (_DDN, "I2C Controller #4") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C4_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C4_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { @@ -321,10 +352,10 @@ Device (I2C5) Name (_DDN, "I2C Controller #5") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C5_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C5_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { @@ -380,10 +411,10 @@ Device (I2C6) Name (_DDN, "I2C Controller #6") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C6_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C6_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { @@ -439,10 +470,10 @@ Device (I2C7) Name (_DDN, "I2C Controller #7") /* Standard Mode: HCNT, LCNT, SDA Hold Time */ - Name (SSCN, Package () { 0x200, 0x200, 0x6 }) + Name (SSCN, Package () { 0x200, 0x200, BOARD_I2C7_DATA_HOLD_TIME }) /* Fast Mode: HCNT, LCNT, SDA Hold Time */ - Name (FMCN, Package () { 0x55, 0x99, 0x6 }) + Name (FMCN, Package () { 0x55, 0x99, BOARD_I2C7_DATA_HOLD_TIME }) Name (RBUF, ResourceTemplate() { |