summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2021-05-24 16:12:31 -0400
committerTom Rini <trini@konsulko.com>2021-05-24 16:12:31 -0400
commit27c6d9663c3f42059514e47c17652304a1cfcfc9 (patch)
tree15e7a1deb449053a3ffca9b708813cce2da366ec /test
parenteb53b943be2949ca111140a8e05532cd74cda058 (diff)
parent2fc62f2991744dfeec65f8619092c359d8ecbcb0 (diff)
Merge branch '2021-05-24-add-lto-support'
- Add LTO (link time optimization) support to the build system and enable it on a few boards. This is an alternative to using -ffunction-sections/-fdata-sections and --gc-sections at link time to remove unused code. This can result in notable savings, but needs testing on each platform before use as it can expose problems by optimizing away various functionally necessary calls.
Diffstat (limited to 'test')
-rw-r--r--test/dm/regmap.c3
-rw-r--r--test/py/conftest.py2
2 files changed, 2 insertions, 3 deletions
diff --git a/test/dm/regmap.c b/test/dm/regmap.c
index 372a73ca0c3..04bb1645d1b 100644
--- a/test/dm/regmap.c
+++ b/test/dm/regmap.c
@@ -306,9 +306,8 @@ static int dm_test_devm_regmap(struct unit_test_state *uts)
&dev));
priv = dev_get_priv(dev);
- srand(get_ticks() + rand());
for (i = 0; i < REGMAP_TEST_BUF_SZ; i++) {
- pattern[i] = rand();
+ pattern[i] = i * 0x87654321;
ut_assertok(regmap_write(priv->cfg_regmap, i, pattern[i]));
}
for (i = 0; i < REGMAP_TEST_BUF_SZ; i++) {
diff --git a/test/py/conftest.py b/test/py/conftest.py
index 1b909cde9d3..11a3f307ea8 100644
--- a/test/py/conftest.py
+++ b/test/py/conftest.py
@@ -226,7 +226,7 @@ def pytest_configure(config):
import u_boot_console_exec_attach
console = u_boot_console_exec_attach.ConsoleExecAttach(log, ubconfig)
-re_ut_test_list = re.compile(r'_u_boot_list_2_ut_(.*)_test_2_\1_test_(.*)\s*$')
+re_ut_test_list = re.compile(r'[^a-zA-Z0-9_]_u_boot_list_2_ut_(.*)_test_2_\1_test_(.*)\s*$')
def generate_ut_subtest(metafunc, fixture_name, sym_path):
"""Provide parametrization for a ut_subtest fixture.