Keith Hui has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/40964 )
Change subject: superio/winbond/w83627dhg: Boards use common config entry/exit function ......................................................................
superio/winbond/w83627dhg: Boards use common config entry/exit function
These 4 boards, using this super I/O, do more early init on it than just enabling early serial. Change them to use the common config entry/exit function. Allows to drop the duplicate just this chip holds.
Change-Id: Ia3cbf6fa9a7719fc420559b9343786c1f66858a4 Signed-off-by: Keith Hui buurin@gmail.com --- M src/mainboard/asus/p5gc-mx/early_init.c M src/mainboard/asus/p5ql-em/early_init.c M src/mainboard/asus/p5qpl-am/early_init.c M src/mainboard/intel/dg41wv/early_init.c 4 files changed, 8 insertions(+), 8 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/40964/1
diff --git a/src/mainboard/asus/p5gc-mx/early_init.c b/src/mainboard/asus/p5gc-mx/early_init.c index 4a17c37..be43fba 100644 --- a/src/mainboard/asus/p5gc-mx/early_init.c +++ b/src/mainboard/asus/p5gc-mx/early_init.c @@ -27,7 +27,7 @@ int need_reset = 0; u8 reg, old_reg;
- pnp_enter_ext_func_mode(GPIO_DEV); + pnp_enter_conf_state(GPIO_DEV); pnp_set_logical_device(GPIO_DEV);
reg = 0x9a; @@ -54,7 +54,7 @@ pnp_write_config(GPIO_DEV, 0xe1, reg); need_reset += ((reg & 0x20) != (old_reg & 0x20));
- pnp_exit_ext_func_mode(GPIO_DEV); + pnp_exit_conf_state(GPIO_DEV);
return need_reset; } diff --git a/src/mainboard/asus/p5ql-em/early_init.c b/src/mainboard/asus/p5ql-em/early_init.c index 3803801..1301018 100644 --- a/src/mainboard/asus/p5ql-em/early_init.c +++ b/src/mainboard/asus/p5ql-em/early_init.c @@ -67,7 +67,7 @@ break; }
- pnp_enter_ext_func_mode(GPIO_DEV); + pnp_enter_conf_state(GPIO_DEV); pnp_set_logical_device(GPIO_DEV);
/* @@ -99,7 +99,7 @@ old_reg = pnp_read_config(GPIO_DEV, 0xf5); /* GPIO4x data */ pnp_write_config(GPIO_DEV, 0xf5, old_reg | reg); need_reset += ((reg & 0x1) != (old_reg & 0x1)); - pnp_exit_ext_func_mode(GPIO_DEV); + pnp_exit_conf_state(GPIO_DEV);
return need_reset; } diff --git a/src/mainboard/asus/p5qpl-am/early_init.c b/src/mainboard/asus/p5qpl-am/early_init.c index afcd531..18cb314 100644 --- a/src/mainboard/asus/p5qpl-am/early_init.c +++ b/src/mainboard/asus/p5qpl-am/early_init.c @@ -69,7 +69,7 @@ break; }
- pnp_enter_ext_func_mode(GPIO_DEV); + pnp_enter_conf_state(GPIO_DEV); pnp_set_logical_device(GPIO_DEV);
if (CONFIG(BOARD_ASUS_P5QPL_AM)) { @@ -121,7 +121,7 @@ pnp_write_config(GPIO_DEV, 0xf5, old_reg | reg); need_reset += ((reg & 0x18) != (old_reg & 0x18)); } - pnp_exit_ext_func_mode(GPIO_DEV); + pnp_exit_conf_state(GPIO_DEV);
return need_reset; } diff --git a/src/mainboard/intel/dg41wv/early_init.c b/src/mainboard/intel/dg41wv/early_init.c index 584b936..c8d7c67 100644 --- a/src/mainboard/intel/dg41wv/early_init.c +++ b/src/mainboard/intel/dg41wv/early_init.c @@ -25,12 +25,12 @@ void bootblock_mainboard_early_init(void) { /* Set GPIOs on superio, enable UART */ - pnp_enter_ext_func_mode(SERIAL_DEV); + pnp_enter_conf_state(SERIAL_DEV); pnp_set_logical_device(SERIAL_DEV);
pnp_write_config(SERIAL_DEV, 0x2c, 0x13);
- pnp_exit_ext_func_mode(SERIAL_DEV); + pnp_exit_conf_state(SERIAL_DEV);
winbond_enable_serial(SERIAL_DEV, CONFIG_TTYS0_BASE);