From e712245d08d95fac6467fd0d05a12d6506aeda2d Mon Sep 17 00:00:00 2001 From: Alper Nebi Yasak Date: Wed, 19 May 2021 19:33:31 +0300 Subject: sandbox: cros-ec: Add tests for the Chromium OS EC PWM driver This patch adds a limited pulse-width modulator to sandbox's Chromium OS Embedded Controller emulation. The emulated PWM device supports multiple channels but can only set a duty cycle for each, as the actual EC doesn't expose any functionality or information other than that. Though the EC supports specifying the PWM channel by its type (e.g. display backlight, keyboard backlight), this is not implemented in the emulation as nothing in U-Boot uses this type specification. This emulated PWM device is then used to test the Chromium OS PWM driver in sandbox. Adding the required device node to the sandbox test device-tree unfortunately makes it the first PWM device, so this also touches some other tests to make sure they still use the sandbox PWM. Signed-off-by: Alper Nebi Yasak Reviewed-by: Simon Glass --- configs/sandbox_spl_defconfig | 1 + 1 file changed, 1 insertion(+) (limited to 'configs/sandbox_spl_defconfig') diff --git a/configs/sandbox_spl_defconfig b/configs/sandbox_spl_defconfig index 8bc1373ec3..c7d15de939 100644 --- a/configs/sandbox_spl_defconfig +++ b/configs/sandbox_spl_defconfig @@ -183,6 +183,7 @@ CONFIG_REGULATOR_S5M8767=y CONFIG_DM_REGULATOR_SANDBOX=y CONFIG_REGULATOR_TPS65090=y CONFIG_DM_PWM=y +CONFIG_PWM_CROS_EC=y CONFIG_PWM_SANDBOX=y CONFIG_RAM=y CONFIG_REMOTEPROC_SANDBOX=y -- cgit v1.2.3