diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mainboard/google/herobrine/board.h | 1 | ||||
-rw-r--r-- | src/mainboard/google/herobrine/boardid.c | 20 |
2 files changed, 13 insertions, 8 deletions
diff --git a/src/mainboard/google/herobrine/board.h b/src/mainboard/google/herobrine/board.h index b604cf762e..9debfb8d6b 100644 --- a/src/mainboard/google/herobrine/board.h +++ b/src/mainboard/google/herobrine/board.h @@ -18,7 +18,6 @@ #define QCOM_SC7280_SKU1 0x0 #define QCOM_SC7280_SKU2 0x1 -#define QCOM_SC7280_SKU3 0x2 /* Fingerprint-specific GPIOs. Only for fingerprint-enabled devices. */ #if CONFIG(HEROBRINE_HAS_FINGERPRINT) diff --git a/src/mainboard/google/herobrine/boardid.c b/src/mainboard/google/herobrine/boardid.c index 7db3e0bc64..ad90dd9143 100644 --- a/src/mainboard/google/herobrine/boardid.c +++ b/src/mainboard/google/herobrine/boardid.c @@ -10,19 +10,25 @@ uint32_t board_id(void) { static uint32_t id = UNDEFINED_STRAPPING_ID; - const gpio_t pins[] = {[2] = GPIO(50), [1] = GPIO(49), [0] = GPIO(48)}; + gpio_t pins[3]; + if (CONFIG(BOARD_GOOGLE_HEROBRINE)) { + pins[2] = GPIO(75); + pins[1] = GPIO(74); + pins[0] = GPIO(73); + } else if (CONFIG(BOARD_GOOGLE_PIGLIN) || CONFIG(BOARD_GOOGLE_HOGLIN) + || CONFIG(BOARD_GOOGLE_SENOR)) { + pins[2] = GPIO(50); + pins[1] = GPIO(49); + pins[0] = GPIO(48); + } if (id == UNDEFINED_STRAPPING_ID) id = gpio_base3_value(pins, ARRAY_SIZE(pins)); - if ((id == QCOM_SC7280_SKU1) || (id == QCOM_SC7280_SKU2) || - (id == QCOM_SC7280_SKU3)) - printk(BIOS_INFO, "BoardID :%d - " + printk(BIOS_INFO, "BoardID :%d - " "Machine model: " "Qualcomm Technologies, Inc. " - "sc7280 IDP SKU%d platform\n", id, (id+1)); - else - printk(BIOS_ERR, "Invalid BoardId : %d\n", id); + "sc7280 platform\n", id); return id; } |