• Home
  • Raw
  • Download

Lines Matching refs:bus

122 	struct udevice *bus;  in dm_test_bus_children()  local
129 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_children()
145 struct udevice *bus, *dev; in dm_test_bus_children_funcs() local
148 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_children_funcs()
151 ut_assertok(device_get_child(bus, 0, &dev)); in dm_test_bus_children_funcs()
152 ut_asserteq(-ENODEV, device_get_child(bus, 4, &dev)); in dm_test_bus_children_funcs()
153 ut_assertok(device_get_child_by_seq(bus, 5, &dev)); in dm_test_bus_children_funcs()
158 ut_asserteq(-ENODEV, device_find_child_by_seq(bus, -1, true, &dev)); in dm_test_bus_children_funcs()
159 ut_assertok(device_find_child_by_seq(bus, 0, true, &dev)); in dm_test_bus_children_funcs()
161 ut_asserteq(-ENODEV, device_find_child_by_seq(bus, 0, false, &dev)); in dm_test_bus_children_funcs()
162 ut_assertok(device_get_child_by_seq(bus, 0, &dev)); in dm_test_bus_children_funcs()
166 ut_asserteq(-ENODEV, device_find_child_by_seq(bus, 2, false, &dev)); in dm_test_bus_children_funcs()
167 ut_asserteq(-ENODEV, device_find_child_by_seq(bus, 2, true, &dev)); in dm_test_bus_children_funcs()
168 ut_asserteq(-ENODEV, device_get_child_by_seq(bus, 2, &dev)); in dm_test_bus_children_funcs()
172 ut_asserteq(-ENODEV, device_find_child_by_of_offset(bus, node, &dev)); in dm_test_bus_children_funcs()
174 ut_asserteq(-ENODEV, device_find_child_by_of_offset(bus, node, &dev)); in dm_test_bus_children_funcs()
183 struct udevice *bus, *dev; in dm_test_bus_children_of_offset() local
186 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_children_of_offset()
187 ut_assertnonnull(bus); in dm_test_bus_children_of_offset()
192 ut_assertok(device_find_child_by_of_offset(bus, node, &dev)); in dm_test_bus_children_of_offset()
195 ut_assertok(device_get_child_by_of_offset(bus, node, &dev)); in dm_test_bus_children_of_offset()
207 struct udevice *bus, *dev, *child; in dm_test_bus_children_iterators() local
210 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_children_iterators()
211 ut_assertok(device_find_first_child(bus, &dev)); in dm_test_bus_children_iterators()
221 ut_assertok(device_find_child_by_seq(bus, 5, true, &dev)); in dm_test_bus_children_iterators()
239 struct udevice *bus, *dev; in test_bus_parent_data() local
243 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in test_bus_parent_data()
246 ut_assertok(device_find_child_by_seq(bus, 0, true, &dev)); in test_bus_parent_data()
248 ut_assertok(device_get_child_by_seq(bus, 0, &dev)); in test_bus_parent_data()
259 ut_assertok(device_get_child_by_seq(bus, 0, &dev)); in test_bus_parent_data()
270 if (dev->parent != bus) { in test_bus_parent_data()
285 if (dev->parent != bus) in test_bus_parent_data()
306 struct udevice *bus; in dm_test_bus_parent_data_uclass() local
311 ut_assertok(uclass_find_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_parent_data_uclass()
312 drv = (struct driver *)bus->driver; in dm_test_bus_parent_data_uclass()
316 os_mprotect_allow(bus->uclass->uc_drv, sizeof(*bus->uclass->uc_drv)); in dm_test_bus_parent_data_uclass()
319 bus->uclass->uc_drv->per_child_auto_alloc_size = size; in dm_test_bus_parent_data_uclass()
324 bus->uclass->uc_drv->per_child_auto_alloc_size = 0; in dm_test_bus_parent_data_uclass()
337 struct udevice *bus, *dev; in dm_test_bus_parent_ops() local
341 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_parent_ops()
346 if (dev->parent != bus) in dm_test_bus_parent_ops()
357 if (dev->parent != bus) in dm_test_bus_parent_ops()
374 struct udevice *bus, *dev; in test_bus_parent_platdata() local
377 ut_assertok(uclass_find_device(UCLASS_TEST_BUS, 0, &bus)); in test_bus_parent_platdata()
378 device_find_first_child(bus, &dev); in test_bus_parent_platdata()
381 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in test_bus_parent_platdata()
383 for (device_find_first_child(bus, &dev); in test_bus_parent_platdata()
403 ut_asserteq(3, device_get_child_count(bus)); in test_bus_parent_platdata()
406 device_remove(bus, DM_REMOVE_NORMAL); in test_bus_parent_platdata()
407 for (device_find_first_child(bus, &dev); in test_bus_parent_platdata()
415 ut_asserteq(3, device_get_child_count(bus)); in test_bus_parent_platdata()
419 device_find_first_child(bus, &dev); in test_bus_parent_platdata()
425 device_probe(bus); in test_bus_parent_platdata()
426 for (device_find_first_child(bus, &dev); in test_bus_parent_platdata()
434 ut_asserteq(3, device_get_child_count(bus)); in test_bus_parent_platdata()
449 struct udevice *bus; in dm_test_bus_parent_platdata_uclass() local
455 ut_assertok(uclass_find_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_parent_platdata_uclass()
456 drv = (struct driver *)bus->driver; in dm_test_bus_parent_platdata_uclass()
459 os_mprotect_allow(bus->uclass->uc_drv, sizeof(*bus->uclass->uc_drv)); in dm_test_bus_parent_platdata_uclass()
462 bus->uclass->uc_drv->per_child_platdata_auto_alloc_size = size; in dm_test_bus_parent_platdata_uclass()
467 bus->uclass->uc_drv->per_child_platdata_auto_alloc_size = 0; in dm_test_bus_parent_platdata_uclass()
479 struct udevice *bus, *dev; in dm_test_bus_child_post_bind() local
481 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_child_post_bind()
482 for (device_find_first_child(bus, &dev); in dm_test_bus_child_post_bind()
490 ut_asserteq(3, device_get_child_count(bus)); in dm_test_bus_child_post_bind()
500 struct udevice *bus, *dev; in dm_test_bus_child_post_bind_uclass() local
502 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_child_post_bind_uclass()
503 for (device_find_first_child(bus, &dev); in dm_test_bus_child_post_bind_uclass()
511 ut_asserteq(3, device_get_child_count(bus)); in dm_test_bus_child_post_bind_uclass()
524 struct udevice *bus, *dev; in dm_test_bus_child_pre_probe_uclass() local
530 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_child_pre_probe_uclass()
531 for (device_find_first_child(bus, &dev); in dm_test_bus_child_pre_probe_uclass()
545 ut_asserteq(3, device_get_child_count(bus)); in dm_test_bus_child_pre_probe_uclass()
558 struct udevice *bus, *dev; in dm_test_bus_child_post_probe_uclass() local
564 ut_assertok(uclass_get_device(UCLASS_TEST_BUS, 0, &bus)); in dm_test_bus_child_post_probe_uclass()
565 for (device_find_first_child(bus, &dev); in dm_test_bus_child_post_probe_uclass()
578 ut_asserteq(3, device_get_child_count(bus)); in dm_test_bus_child_post_probe_uclass()