Sean Rhodes has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/62700 )
Change subject: ec/starlabs/merlin: Make EC function names generic ......................................................................
ec/starlabs/merlin: Make EC function names generic
Signed-off-by: Sean Rhodes sean@starlabs.systems Change-Id: Ie61af233f731eb47772af1c82c6abdc515bc89cc --- M src/ec/starlabs/merlin/ite.c M src/ec/starlabs/merlin/ite.h M src/mainboard/starlabs/labtop/smbios.c M src/mainboard/starlabs/lite/smbios.c 4 files changed, 6 insertions(+), 6 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/00/62700/1
diff --git a/src/ec/starlabs/merlin/ite.c b/src/ec/starlabs/merlin/ite.c index ef317a9..8933996 100644 --- a/src/ec/starlabs/merlin/ite.c +++ b/src/ec/starlabs/merlin/ite.c @@ -10,7 +10,7 @@ #include "ite.h" #include "ecdefs.h"
-uint16_t it_get_version(void) +uint16_t ec_get_version(void) { return (ec_read(ECRAM_MAJOR_VERSION) << 8) | ec_read(ECRAM_MINOR_VERSION); } @@ -26,7 +26,7 @@ return lut[index]; }
-static uint16_t ite_get_chip_id(unsigned int port) +static uint16_t ec_get_chip_id(unsigned int port) { return (pnp_read_index(port, ITE_CHIPID1) << 8) | pnp_read_index(port, ITE_CHIPID2); @@ -49,7 +49,7 @@ return; }
- const uint16_t chip_id = ite_get_chip_id(dev->path.pnp.port); + const uint16_t chip_id = ec_get_chip_id(dev->path.pnp.port);
if (chip_id != ITE_CHIPID_VAL) { printk(BIOS_ERR, "ITE: Expected chip ID 0x%04x, but got 0x%04x instead.\n", diff --git a/src/ec/starlabs/merlin/ite.h b/src/ec/starlabs/merlin/ite.h index 8f8bb99..1e7607d 100644 --- a/src/ec/starlabs/merlin/ite.h +++ b/src/ec/starlabs/merlin/ite.h @@ -81,6 +81,6 @@ #define KBL_DISABLED 0x00 #define KBL_ENABLED 0xdd
-uint16_t it_get_version(void); +uint16_t ec_get_version(void);
#endif diff --git a/src/mainboard/starlabs/labtop/smbios.c b/src/mainboard/starlabs/labtop/smbios.c index b787986..5d64246 100644 --- a/src/mainboard/starlabs/labtop/smbios.c +++ b/src/mainboard/starlabs/labtop/smbios.c @@ -18,7 +18,7 @@ /* Get the Embedded Controller firmware version */ void smbios_ec_revision(uint8_t *ec_major_revision, uint8_t *ec_minor_revision) { - u16 ec_version = it_get_version(); + u16 ec_version = ec_get_version();
*ec_major_revision = ec_version >> 8; *ec_minor_revision = ec_version & 0xff; diff --git a/src/mainboard/starlabs/lite/smbios.c b/src/mainboard/starlabs/lite/smbios.c index 7894ebb..b552664 100644 --- a/src/mainboard/starlabs/lite/smbios.c +++ b/src/mainboard/starlabs/lite/smbios.c @@ -18,7 +18,7 @@ /* Get the Embedded Controller firmware version */ void smbios_ec_revision(uint8_t *ec_major_revision, uint8_t *ec_minor_revision) { - u16 ec_version = it_get_version(); + u16 ec_version = ec_get_version();
*ec_major_revision = ec_version >> 8; *ec_minor_revision = ec_version & 0xff;