Commit 7f491876 authored by Angus Ainslie's avatar Angus Ainslie

board: purism: librem5: Move the board rev to the MAC address fuses

NXP has changed the layout of the OTP fuses and the user area is no longer
writable so we'll overload the MAC address as a board revision number.
Signed-off-by: default avatarAngus Ainslie <>
parent 9a62f4df
......@@ -568,15 +568,13 @@ int fastboot_key_pressed(void)
int board_late_init(void)
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
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment