From 1804301a1e46b1e2f6a0d25abdc915856f04ec54 Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Mon, 25 Apr 2022 18:33:51 +0200 Subject: [PATCH] test: dm: pinmux: Get LED2 udevice in the pinmux test The UT reinitializes the pin controller state, get LED2 udevice to trigger its probe and configure the pin controller pin state as it is expected by the test. Signed-off-by: Marek Vasut Cc: Patrice Chotard Cc: Patrick Delaunay Cc: Sean Anderson Cc: Simon Glass Cc: Steven Lawrance --- test/cmd/pinmux.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/cmd/pinmux.c b/test/cmd/pinmux.c index de3bb0d2f9..df40bb7743 100644 --- a/test/cmd/pinmux.c +++ b/test/cmd/pinmux.c @@ -7,12 +7,17 @@ #include #include +#include #include #include #include static int dm_test_cmd_pinmux_status_pinname(struct unit_test_state *uts) { + struct udevice *dev; + + ut_assertok(uclass_get_device(UCLASS_LED, 2, &dev)); + /* Test that 'pinmux status ' displays the selected pin. */ console_record_reset(); run_command("pinmux status a5", 0); -- 2.39.5