From ff7d7138b08a3db9875ad2f1e575dd662fec356b Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Wed, 15 Feb 2023 19:04:04 -0700 Subject: [PATCH] Support power limits above 256W --- src/board/system76/common/power.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/board/system76/common/power.c b/src/board/system76/common/power.c index 93189c5..08fc2d0 100644 --- a/src/board/system76/common/power.c +++ b/src/board/system76/common/power.c @@ -306,7 +306,7 @@ void power_off(void) { #ifdef HAVE_DGPU static bool power_peci_limit(bool ac) { - uint8_t watts = ac ? POWER_LIMIT_AC : POWER_LIMIT_DC; + uint16_t watts = ac ? POWER_LIMIT_AC : POWER_LIMIT_DC; // Set PL4 using PECI int16_t res = peci_wr_pkg_config(60, 0, ((uint32_t)watts) * 8); DEBUG("power_peci_limit %d = %d\n", watts, res);