From 7d573335291bb65431b90011835a44169ec716f7 Mon Sep 17 00:00:00 2001 From: Sean Rhodes Date: Thu, 21 Aug 2025 21:00:22 +0100 Subject: [PATCH] ec/starlabs/merlin: Add a "off" mode for the power LED Users have requested to be able to disable the power LED, so add this as an option. Change-Id: I74da148c7891ab3dd5e5b692239670c9937ab302 Signed-off-by: Sean Rhodes Reviewed-on: https://review.coreboot.org/c/coreboot/+/88890 Reviewed-by: Matt DeVillier Tested-by: build bot (Jenkins) --- src/ec/starlabs/merlin/cfr.h | 1 + src/ec/starlabs/merlin/ec.h | 1 + src/ec/starlabs/merlin/ite.c | 5 +++-- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/ec/starlabs/merlin/cfr.h b/src/ec/starlabs/merlin/cfr.h index b56e7d2e52..f53ec5fa4c 100644 --- a/src/ec/starlabs/merlin/cfr.h +++ b/src/ec/starlabs/merlin/cfr.h @@ -109,6 +109,7 @@ static const struct sm_object power_led = SM_DECLARE_ENUM({ .values = (const struct sm_enum_value[]) { { "Normal", 0 }, { "Reduced", 1 }, + { "Off", 2 }, SM_ENUM_VALUE_END, }, }); diff --git a/src/ec/starlabs/merlin/ec.h b/src/ec/starlabs/merlin/ec.h index 82572bde73..4b6b791771 100644 --- a/src/ec/starlabs/merlin/ec.h +++ b/src/ec/starlabs/merlin/ec.h @@ -111,6 +111,7 @@ /* Power LED Brightness */ #define LED_NORMAL 0x00 #define LED_REDUCED 0x01 +#define LED_OFF 0x02 uint16_t ec_get_version(void); diff --git a/src/ec/starlabs/merlin/ite.c b/src/ec/starlabs/merlin/ite.c index 6eaa3e9915..f034a0505a 100644 --- a/src/ec/starlabs/merlin/ite.c +++ b/src/ec/starlabs/merlin/ite.c @@ -337,13 +337,14 @@ static void merlin_init(struct device *dev) * * Setting: power_led * - * Values: 0, 1 + * Values: 0, 1, 2 * Default: 0 * */ const uint8_t power_led[] = { LED_NORMAL, - LED_REDUCED + LED_REDUCED, + LED_OFF }; if (CONFIG(EC_STARLABS_POWER_LED))