Commit 351c708c authored by Angus Ainslie's avatar Angus Ainslie
Browse files

Merge branch 'move_fuses' into 'librem5'

Move the board rev to the MAC address fuses

See merge request !37
parents 9a62f4df 7f491876
Pipeline #60720 passed with stage
in 5 minutes and 28 seconds
......@@ -568,15 +568,13 @@ int fastboot_key_pressed(void)
int board_late_init(void)
{
#ifdef CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG
u32 vid, rev;
u32 rev;
char rev_str[3];
env_set("board_name", "librem5");
if (fuse_read(8, 2, &vid) || fuse_read(14, 0, &rev))
if (fuse_read(9, 0, &rev)) {
env_set("board_rev", BOARD_REV_ERROR);
else if (vid == 0) {
env_set("board_rev", BOARD_REV_UNKNOWN);
} else if (vid == (PURISM_PID<<16 | PURISM_VID)) {
} else {
sprintf(rev_str, "%u", rev);
env_set("board_rev", rev_str);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment