Aaron Durbin has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
ec/google/chromeec: add BOARD_VERSION CBI support
Obtaining the CBI_TAG_BOARD_VERSION value wasn't in the code base. Add the binding for it so it can be used.
BUG=b:153640981
Change-Id: Ie2f289631f908014432596448e56b5048a196a10 Signed-off-by: Aaron Durbin adurbin@chromium.org --- M src/ec/google/chromeec/ec.c M src/ec/google/chromeec/ec.h 2 files changed, 8 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/55/40355/1
diff --git a/src/ec/google/chromeec/ec.c b/src/ec/google/chromeec/ec.c index 8d9c2ac..17e110c 100644 --- a/src/ec/google/chromeec/ec.c +++ b/src/ec/google/chromeec/ec.c @@ -848,6 +848,11 @@ return cbi_get_uint32(id, CBI_TAG_OEM_ID); }
+int google_chromeec_cbi_get_board_version(uint32_t *version) +{ + return cbi_get_uint32(version, CBI_TAG_BOARD_VERSION); +} + static int cbi_get_string(char *buf, size_t bufsize, uint32_t tag) { struct ec_params_get_cbi params = { diff --git a/src/ec/google/chromeec/ec.h b/src/ec/google/chromeec/ec.h index 77ba211..a7a7b55 100644 --- a/src/ec/google/chromeec/ec.h +++ b/src/ec/google/chromeec/ec.h @@ -78,6 +78,9 @@ int google_chromeec_cbi_get_fw_config(uint32_t *fw_config); int google_chromeec_cbi_get_dram_part_num(char *buf, size_t bufsize); int google_chromeec_cbi_get_oem_name(char *buf, size_t bufsize); +/* version may be stored in CBI as a smaller integer width, but the EC code + * handles it correctly. */ +int google_chromeec_cbi_get_board_version(uint32_t *version);
#define CROS_SKU_UNKNOWN 0xFFFFFFFF #define CROS_SKU_UNPROVISIONED 0x7FFFFFFF
Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
Patch Set 1: Code-Review+2
Paul Menzel has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
Patch Set 1:
(1 comment)
https://review.coreboot.org/c/coreboot/+/40355/1/src/ec/google/chromeec/ec.h File src/ec/google/chromeec/ec.h:
https://review.coreboot.org/c/coreboot/+/40355/1/src/ec/google/chromeec/ec.h... PS1, Line 82: * handles it correctly. */ Please remove the asterisk in the beginning to use the allowed concise multi-line comment style.
https://doc.coreboot.org/coding_style.html#commenting
Edward O'Callaghan has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
Patch Set 1: Code-Review+2
Hello build bot (Jenkins), Furquan Shaikh, Edward O'Callaghan,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/40355
to look at the new patch set (#2).
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
ec/google/chromeec: add BOARD_VERSION CBI support
Obtaining the CBI_TAG_BOARD_VERSION value wasn't in the code base. Add the binding for it so it can be used.
BUG=b:153640981
Change-Id: Ie2f289631f908014432596448e56b5048a196a10 Signed-off-by: Aaron Durbin adurbin@chromium.org --- M src/ec/google/chromeec/ec.c M src/ec/google/chromeec/ec.h 2 files changed, 8 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/55/40355/2
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
Patch Set 2:
(1 comment)
https://review.coreboot.org/c/coreboot/+/40355/1/src/ec/google/chromeec/ec.h File src/ec/google/chromeec/ec.h:
https://review.coreboot.org/c/coreboot/+/40355/1/src/ec/google/chromeec/ec.h... PS1, Line 82: * handles it correctly. */
Please remove the asterisk in the beginning to use the allowed concise multi-line comment style. […]
Done
Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
Patch Set 2: Code-Review+2
Aaron Durbin has submitted this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
ec/google/chromeec: add BOARD_VERSION CBI support
Obtaining the CBI_TAG_BOARD_VERSION value wasn't in the code base. Add the binding for it so it can be used.
BUG=b:153640981
Change-Id: Ie2f289631f908014432596448e56b5048a196a10 Signed-off-by: Aaron Durbin adurbin@chromium.org Reviewed-on: https://review.coreboot.org/c/coreboot/+/40355 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Furquan Shaikh furquan@google.com --- M src/ec/google/chromeec/ec.c M src/ec/google/chromeec/ec.h 2 files changed, 8 insertions(+), 0 deletions(-)
Approvals: build bot (Jenkins): Verified Furquan Shaikh: Looks good to me, approved
diff --git a/src/ec/google/chromeec/ec.c b/src/ec/google/chromeec/ec.c index 8d9c2ac..17e110c 100644 --- a/src/ec/google/chromeec/ec.c +++ b/src/ec/google/chromeec/ec.c @@ -848,6 +848,11 @@ return cbi_get_uint32(id, CBI_TAG_OEM_ID); }
+int google_chromeec_cbi_get_board_version(uint32_t *version) +{ + return cbi_get_uint32(version, CBI_TAG_BOARD_VERSION); +} + static int cbi_get_string(char *buf, size_t bufsize, uint32_t tag) { struct ec_params_get_cbi params = { diff --git a/src/ec/google/chromeec/ec.h b/src/ec/google/chromeec/ec.h index 77ba211..13e3bd9 100644 --- a/src/ec/google/chromeec/ec.h +++ b/src/ec/google/chromeec/ec.h @@ -78,6 +78,9 @@ int google_chromeec_cbi_get_fw_config(uint32_t *fw_config); int google_chromeec_cbi_get_dram_part_num(char *buf, size_t bufsize); int google_chromeec_cbi_get_oem_name(char *buf, size_t bufsize); +/* version may be stored in CBI as a smaller integer width, but the EC code + handles it correctly. */ +int google_chromeec_cbi_get_board_version(uint32_t *version);
#define CROS_SKU_UNKNOWN 0xFFFFFFFF #define CROS_SKU_UNPROVISIONED 0x7FFFFFFF
9elements QA has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/40355 )
Change subject: ec/google/chromeec: add BOARD_VERSION CBI support ......................................................................
Patch Set 3:
Automatic boot test returned (PASS/FAIL/TOTAL): 3/0/3 Emulation targets: EMULATION_QEMU_X86_Q35 using payload TianoCore : SUCCESS : https://lava.9esec.io/r/2371 EMULATION_QEMU_X86_Q35 using payload SeaBIOS : SUCCESS : https://lava.9esec.io/r/2370 EMULATION_QEMU_X86_I440FX using payload SeaBIOS : SUCCESS : https://lava.9esec.io/r/2369
Please note: This test is under development and might not be accurate at all!