diff options
Diffstat (limited to 'src/ec/starlabs/merlin/ec.c')
-rw-r--r-- | src/ec/starlabs/merlin/ec.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/ec/starlabs/merlin/ec.c b/src/ec/starlabs/merlin/ec.c index 40be138a82..e8eaa229d7 100644 --- a/src/ec/starlabs/merlin/ec.c +++ b/src/ec/starlabs/merlin/ec.c @@ -130,11 +130,12 @@ static void merlin_init(struct device *dev) CHARGE_60 }; - ec_write(ECRAM_MAX_CHARGE, - get_ec_value_from_option("max_charge", - 0, - max_charge, - ARRAY_SIZE(max_charge))); + if (CONFIG(EC_STARLABS_MAX_CHARGE)) + ec_write(ECRAM_MAX_CHARGE, + get_ec_value_from_option("max_charge", + 0, + max_charge, + ARRAY_SIZE(max_charge))); /* * Fan Mode |