From ba0e7daeefa1ae9821c9fb3103ea7c3ddd2dd2f8 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Wed, 16 Dec 2020 21:20:11 -0700 Subject: dm: core: Switch binding to use new sequence numbers Update the core logic to use the new approach. For now the old code is left as is. Update one test so it still passes. Signed-off-by: Simon Glass --- test/dm/bus.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test') diff --git a/test/dm/bus.c b/test/dm/bus.c index 9e81b1da1f0..77555e52937 100644 --- a/test/dm/bus.c +++ b/test/dm/bus.c @@ -159,9 +159,10 @@ static int dm_test_bus_children_funcs(struct unit_test_state *uts) ut_asserteq(-ENODEV, device_find_child_by_seq(bus, -1, true, &dev)); ut_assertok(device_find_child_by_seq(bus, 0, true, &dev)); ut_assert(!(dev->flags & DM_FLAG_ACTIVATED)); - ut_asserteq(-ENODEV, device_find_child_by_seq(bus, 0, false, &dev)); + ut_asserteq(0, device_find_child_by_seq(bus, 0, false, &dev)); ut_assertok(device_get_child_by_seq(bus, 0, &dev)); ut_assert(dev->flags & DM_FLAG_ACTIVATED); + ut_asserteq(0, device_find_child_by_seq(bus, 0, false, &dev)); /* There is no device with sequence number 2 */ ut_asserteq(-ENODEV, device_find_child_by_seq(bus, 2, false, &dev)); -- cgit v1.2.3