diff options
author | Simon Glass <sjg@chromium.org> | 2019-12-29 21:19:25 -0700 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2020-01-07 16:02:39 -0700 |
commit | dc12ebbbdb765153805d2b17d18edf5fe0813d5a (patch) | |
tree | 8f0872ad4ec567e7b5cda4422762289ea904e5ba /include/test | |
parent | cce61fc428700a782f2f76b0f32b6112eeb99dfb (diff) | |
download | u-boot-dc12ebbbdb765153805d2b17d18edf5fe0813d5a.tar.gz |
dm: test: Add a test driver for devres
Add a driver which does devres allocations so that we can write tests for
devres.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/test')
-rw-r--r-- | include/test/test.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/test/test.h b/include/test/test.h index 98fbcd11f6..5977c59d3f 100644 --- a/include/test/test.h +++ b/include/test/test.h @@ -46,5 +46,14 @@ struct unit_test { .func = _name, \ } +/* Sizes for devres tests */ +enum { + TEST_DEVRES_SIZE = 100, + TEST_DEVRES_COUNT = 10, + TEST_DEVRES_TOTAL = TEST_DEVRES_SIZE * TEST_DEVRES_COUNT, + + /* A different size */ + TEST_DEVRES_SIZE2 = 15, +}; #endif /* __TEST_TEST_H */ |