Skip to content

Commit efe67f7

Browse files
LSChyiChromeos LUCI
authored andcommitted
ec_commands: add EC_CMD_PWM_GET_FAN_DUTY for getting fan duty cycle
Add host command `EC_CMD_PWM_GET_FAN_DUTY` for host to get current fan duty cycle setting. BUG=b:411292427 TEST=make buildall Change-Id: Ifc51935c807d2a5fe94c03ceef5fb778fdbbef80 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/6466952 Commit-Queue: Sung-Chi Li <lschyi@chromium.org> Code-Coverage: Zoss <zoss-cl-coverage@prod.google.com> Reviewed-by: Wai-Hong Tam <waihong@google.com> Tested-by: Sung-Chi Li <lschyi@chromium.org>
1 parent fc52b72 commit efe67f7

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

‎include/ec_commands.h‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2333,6 +2333,16 @@ struct ec_response_pwm_get_duty {
23332333
uint16_t duty; /* Duty cycle, EC_PWM_MAX_DUTY = 100% */
23342334
} __ec_align2;
23352335

2336+
#define EC_CMD_PWM_GET_FAN_DUTY 0x0027
2337+
2338+
struct ec_params_pwm_get_fan_duty {
2339+
uint8_t fan_idx;
2340+
} __ec_align1;
2341+
2342+
struct ec_response_pwm_get_fan_duty {
2343+
uint32_t percent; /* Percentage of duty cycle, ranging from 0 ~ 100 */
2344+
} __ec_align4;
2345+
23362346
/*****************************************************************************/
23372347
/*
23382348
* Lightbar commands. This looks worse than it is. Since we only use one HOST

0 commit comments

Comments
 (0)