HAOUAS Elyes has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/37570 )
Change subject: mb/msi/ms7721: Move pnp_{enter,exit}_conf_state to common place ......................................................................
mb/msi/ms7721: Move pnp_{enter,exit}_conf_state to common place
Change-Id: Ib27c518fb5ce99e17be25b974ff5adc8c6b3f3a6 Signed-off-by: Elyes HAOUAS ehaouas@noos.fr --- M src/mainboard/msi/ms7721/romstage.c M src/superio/fintek/common/early_serial.c M src/superio/fintek/common/fintek.h 3 files changed, 5 insertions(+), 17 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/70/37570/1
diff --git a/src/mainboard/msi/ms7721/romstage.c b/src/mainboard/msi/ms7721/romstage.c index 0266eff..02f27b0 100644 --- a/src/mainboard/msi/ms7721/romstage.c +++ b/src/mainboard/msi/ms7721/romstage.c @@ -41,21 +41,6 @@
/* GPIO configuration */ -#define FINTEK_ENTRY_KEY 0x87 -static void pnp_enter_conf_state(pnp_devfn_t dev) -{ - u16 port = dev >> 8; - outb(FINTEK_ENTRY_KEY, port); - outb(FINTEK_ENTRY_KEY, port); -} - -#define FINTEK_EXIT_KEY 0xAA -static void pnp_exit_conf_state(pnp_devfn_t dev) -{ - u16 port = dev >> 8; - outb(FINTEK_EXIT_KEY, port); -} - static void gpio_init(pnp_devfn_t dev) { pnp_enter_conf_state(dev); diff --git a/src/superio/fintek/common/early_serial.c b/src/superio/fintek/common/early_serial.c index c625b53..d0e0ab0 100644 --- a/src/superio/fintek/common/early_serial.c +++ b/src/superio/fintek/common/early_serial.c @@ -43,7 +43,7 @@ #define FINTEK_EXIT_KEY 0xAA
/* Enable configuration: pass entry key '0x87' into index port dev. */ -static void pnp_enter_conf_state(pnp_devfn_t dev) +void pnp_enter_conf_state(pnp_devfn_t dev) { u16 port = dev >> 8; outb(FINTEK_ENTRY_KEY, port); @@ -51,7 +51,7 @@ }
/* Disable configuration: pass exit key '0xAA' into index port dev. */ -static void pnp_exit_conf_state(pnp_devfn_t dev) +void pnp_exit_conf_state(pnp_devfn_t dev) { u16 port = dev >> 8; outb(FINTEK_EXIT_KEY, port); diff --git a/src/superio/fintek/common/fintek.h b/src/superio/fintek/common/fintek.h index cbd175f..306edee 100644 --- a/src/superio/fintek/common/fintek.h +++ b/src/superio/fintek/common/fintek.h @@ -22,4 +22,7 @@
void fintek_enable_serial(pnp_devfn_t dev, u16 iobase);
+void pnp_enter_conf_state(pnp_devfn_t dev); +void pnp_exit_conf_state(pnp_devfn_t dev); + #endif /* SUPERIO_FINTEK_COMMON_PRE_RAM_H */
Hello Felix Held, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/37570
to look at the new patch set (#2).
Change subject: mb/msi/ms7721: Don't rewrite pnp_{enter,exit}_conf_state function ......................................................................
mb/msi/ms7721: Don't rewrite pnp_{enter,exit}_conf_state function
Change-Id: Ib27c518fb5ce99e17be25b974ff5adc8c6b3f3a6 Signed-off-by: Elyes HAOUAS ehaouas@noos.fr --- M src/mainboard/msi/ms7721/romstage.c M src/superio/fintek/common/early_serial.c M src/superio/fintek/common/fintek.h 3 files changed, 5 insertions(+), 17 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/70/37570/2
Felix Held has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/37570 )
Change subject: mb/msi/ms7721: Don't rewrite pnp_{enter,exit}_conf_state function ......................................................................
Patch Set 2: Code-Review+2
Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/37570 )
Change subject: mb/msi/ms7721: Don't rewrite pnp_{enter,exit}_conf_state function ......................................................................
mb/msi/ms7721: Don't rewrite pnp_{enter,exit}_conf_state function
Change-Id: Ib27c518fb5ce99e17be25b974ff5adc8c6b3f3a6 Signed-off-by: Elyes HAOUAS ehaouas@noos.fr Reviewed-on: https://review.coreboot.org/c/coreboot/+/37570 Reviewed-by: Felix Held felix-coreboot@felixheld.de Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/mainboard/msi/ms7721/romstage.c M src/superio/fintek/common/early_serial.c M src/superio/fintek/common/fintek.h 3 files changed, 5 insertions(+), 17 deletions(-)
Approvals: build bot (Jenkins): Verified Felix Held: Looks good to me, approved
diff --git a/src/mainboard/msi/ms7721/romstage.c b/src/mainboard/msi/ms7721/romstage.c index ebb875d..bec2f40 100644 --- a/src/mainboard/msi/ms7721/romstage.c +++ b/src/mainboard/msi/ms7721/romstage.c @@ -41,21 +41,6 @@
/* GPIO configuration */ -#define FINTEK_ENTRY_KEY 0x87 -static void pnp_enter_conf_state(pnp_devfn_t dev) -{ - u16 port = dev >> 8; - outb(FINTEK_ENTRY_KEY, port); - outb(FINTEK_ENTRY_KEY, port); -} - -#define FINTEK_EXIT_KEY 0xAA -static void pnp_exit_conf_state(pnp_devfn_t dev) -{ - u16 port = dev >> 8; - outb(FINTEK_EXIT_KEY, port); -} - static void gpio_init(pnp_devfn_t dev) { pnp_enter_conf_state(dev); diff --git a/src/superio/fintek/common/early_serial.c b/src/superio/fintek/common/early_serial.c index c625b53..d0e0ab0 100644 --- a/src/superio/fintek/common/early_serial.c +++ b/src/superio/fintek/common/early_serial.c @@ -43,7 +43,7 @@ #define FINTEK_EXIT_KEY 0xAA
/* Enable configuration: pass entry key '0x87' into index port dev. */ -static void pnp_enter_conf_state(pnp_devfn_t dev) +void pnp_enter_conf_state(pnp_devfn_t dev) { u16 port = dev >> 8; outb(FINTEK_ENTRY_KEY, port); @@ -51,7 +51,7 @@ }
/* Disable configuration: pass exit key '0xAA' into index port dev. */ -static void pnp_exit_conf_state(pnp_devfn_t dev) +void pnp_exit_conf_state(pnp_devfn_t dev) { u16 port = dev >> 8; outb(FINTEK_EXIT_KEY, port); diff --git a/src/superio/fintek/common/fintek.h b/src/superio/fintek/common/fintek.h index cbd175f..306edee 100644 --- a/src/superio/fintek/common/fintek.h +++ b/src/superio/fintek/common/fintek.h @@ -22,4 +22,7 @@
void fintek_enable_serial(pnp_devfn_t dev, u16 iobase);
+void pnp_enter_conf_state(pnp_devfn_t dev); +void pnp_exit_conf_state(pnp_devfn_t dev); + #endif /* SUPERIO_FINTEK_COMMON_PRE_RAM_H */