test: Drop struct dm_test_state
Driver model is a core part of U-Boot. We don't really need to have a separate test structure for the driver model tests and it makes it harder to write a test if you have to think about which type of test it is. Subsume the fields from struct dm_test_state into struct unit_test_state and delete the former. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -116,10 +116,8 @@ static int test_manual_bind(struct udevice *dev)
|
||||
|
||||
static int test_manual_probe(struct udevice *dev)
|
||||
{
|
||||
struct dm_test_state *dms = uts->priv;
|
||||
|
||||
dm_testdrv_op_count[DM_TEST_OP_PROBE]++;
|
||||
if (!dms->force_fail_alloc)
|
||||
if (!uts->force_fail_alloc)
|
||||
dev_set_priv(dev, calloc(1, sizeof(struct dm_test_priv)));
|
||||
if (!dev_get_priv(dev))
|
||||
return -ENOMEM;
|
||||
|
||||
Reference in New Issue
Block a user