| Age | Commit message (Collapse) | Author |
|
Function log_has_file() is not used externally. Make it static.
Rename the function to log_has_member() as we can reuse for filtering
other strings.
Signed-off-by: Heinrich Schuchardt <[email protected]>
|
|
When logging running an image, e.g. `bootefi hello` the indent is not
correctly reset.
Signed-off-by: Heinrich Schuchardt <[email protected]>
|
|
Simon Glass <[email protected]> says:
The current method of running unit tests relies on subcommands of the
ut command. Only the code in each subcommand knows how to find the tests
related to that subcomand.
This is not ideal and we now have quite a few subcommands which do
nothing but locate the relevant tests in a linker list, then call a
common function to run them.
This series adds a list of test suites, so that these subcommands can be
removed.
An issue with 'ut all' is that it doesn't record how many tests failed
overall, so it is necessary to examine copious amounts of output to look
for failures. This series adds a new 'total' feature allow recording the
total number of failed tests.
To help with 'ut all' a new pytest is created which runs it (as well as
'ut info') and makes sure that all is well. Due to the 'ut all' failures
this does not pass, so the test is disabled for now. It is here because
it provides security against misnaming a test suite and causing it not
to run.
Future work may:
- get 'ut all' passing
- enable test_suite() in CL, to ensure that 'ut all' keeps passing
- record duration of each suite
- allow running the tests in random order to tease out dependencies
- tweak the output to remove common prefixes
- getting rid of bootstd, optee and seame 'ut' subcommands
Link: https://lore.kernel.org/r/[email protected]
|
|
With 'ut all' multiple test suites are run. Add a way to collect totals
and show them at the end.
Signed-off-by: Simon Glass <[email protected]>
|
|
Add a function to show the stats, so we can decide when to print it.
This slightly adjusts the output, so that any 'test not found' message
appears on its own line after all other output.
The 'failures' message now appears in lower case so update pytest
accordingly.
Signed-off-by: Simon Glass <[email protected]>
|
|
This is useful information and is not always the same as the 'count' arg
to ut_run_list() so add it as a separate stat.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use a struct to hold the stats, since we also want to have the same
stats for all runs as we have for each suite.
Signed-off-by: Simon Glass <[email protected]>
|
|
Update this function to access a unit-test state, so that the caller can
collect results from running multiple suites.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
It is not clear that these actually work, since they are not enabled on
sandbox for some reason.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
It is not clear that these actually work, since they are not enabled on
sandbox for some reason.
Signed-off-by: Simon Glass <[email protected]>
Acked-by: Linus Walleij <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
Use the new suite-runner to run these tests instead.
Signed-off-by: Simon Glass <[email protected]>
|
|
The current cmd_ut_sub[] array was fine when there were only a few test
suites. But is quite unwieldy now:
- it requires a separate do_ut_xxx for each suite, even though the code
for most is almost identical
- running more than one suite requires running multiple commands, and
there is no record of which suites passed or failed
- 'ut all' runs all suites but reports their results individually
- we need lots of #ifdefs in the array, mirroring those in the makefile
but maintained in a separate place
In fact the tests are all in the same linker list. The suites are
grouped, so it is possible to access the information without a command.
Introduce a 'suite' array, which holds the cmd_ut_...() function to
call, but can also support running a suite without that function. This
means that the array of struct cmd_tbl is transformed into an array of
'struct suite'.
This will allow removal of many of the functions, particularly those
without test-specific init.
Signed-off-by: Simon Glass <[email protected]>
|
|
Most test suites have a _test suffix. This is not necessary as there is
also a ut_ prefix.
Drop the suffix so that (with future work) the suite name can be used as
the linker-list name.
Remove the suffix from the pytest regex as well, moving it to the top of
the file, as it is a constant.
Signed-off-by: Simon Glass <[email protected]>
|
|
Some suites have a different name from that used in the linker list.
That makes it hard to programmatically match the name printed when the
suite runs to the linker-list name it has.
Update the names so they are the same.
Signed-off-by: Simon Glass <[email protected]>
|
|
A limitation of most linker_list macros is that they cannot easily be
used in data structures. This is because they include code inside their
expressions.
Provide a way to support this, with new ll_start_decl() and
ll_end_decl() macros.
Signed-off-by: Simon Glass <[email protected]>
|
|
Pass this into the function so that callers can inspect the state
afterwards.
Signed-off-by: Simon Glass <[email protected]>
|
|
Rename this function and test_set_state() so use the same ut_ prefix as
other functions in ut.h
Signed-off-by: Simon Glass <[email protected]>
|
|
Drop some the prototypes for functions which were removed in earlier
series.
Signed-off-by: Simon Glass <[email protected]>
|
|
Simon Glass <[email protected]> says:
The current UPL spec[1] has been tidied up and improved over the last
year, since U-Boot's original UPL support was written.
This series includes some prerequisite patches needed for the real UPL
patches. It is split from [2]
[1] https://github.com/UniversalPayload/spec/tree/3f1450d
[2] https://patchwork.ozlabs.org/project/uboot/list/?series=438574&state=*
Link: https://lore.kernel.org/r/[email protected]
|
|
The ofnode_find_subnode() function currently processes things two
different ways, so the treatment of unit addresses differs depending on
whether OF_LIVE is enabled or not.
Add a new version which uses the ofnode API and add a test to check that
unit addresses can be matched correctly. Leave the old function in place
for the !OF_LIVE case, to avoid a code-size increase, e.g. on
firefly-rk3288
Signed-off-by: Simon Glass <[email protected]>
|
|
When a unit-address is provided, use it to match against the node
name.
Since this increases code size, put it into a separate function.
Signed-off-by: Simon Glass <[email protected]>
|
|
This function is somewhat ambiguous, so expand the comments and add a
test for the undefined behaviour.
Signed-off-by: Simon Glass <[email protected]>
|
|
Add this information to the handoff structure so that it is available to
U-Boot proper. Update bochs and the video handoff.
Signed-off-by: Simon Glass <[email protected]>
|
|
This function is really just getting the data. The size comes along for
the ride. In fact this function is only reliable way to obtain the data
for an image in a FIT, since the FIT may use external data.
Rename it to fit_image_get_data()
Signed-off-by: Simon Glass <[email protected]>
|
|
This function can only be used with FITs that use embedded data. Rename
it so this is clear.
Signed-off-by: Simon Glass <[email protected]>
Acked-by: Heinrich Schuchardt <[email protected]>
|
|
This function allocates memory for the node name, so mention this in the
function comment.
Signed-off-by: Simon Glass <[email protected]>
|
|
This concept exists on x86. Declare it as a generic function so that the
value can be accessed by UPL.
Signed-off-by: Simon Glass <[email protected]>
|
|
Add a new initialiser which can accept a constant pointer.
Signed-off-by: Simon Glass <[email protected]>
|
|
Some header files included on the host are moving to use abuf, so adjust
the header-inclusion to bring in size_t correctly.
Signed-off-by: Simon Glass <[email protected]>
|
|
In many cases it is useful to get the address of a buffer, e.g. when
booting from it. Add a function to handle this.
Signed-off-by: Simon Glass <[email protected]>
|
|
The highlights are:
* Fixed boot regression due to broken memory parsing
* Enable HW RNG and KASLR on all platforms
* Add support for Snapdragon X1 Elite hardware (clk/pinctrl)
* Add support for QCS9100 ride automotive development platform (clk/ufs)
* Add support for PCIe on SM8550, SM8650 and X1E
* Implement software debounce for PMIC buttons
Additionally, some minor improvements to "ufetch" have been pulled in:
* Show CPU architecture (arm/mips/etc)
* Make CONFIG_BLK optional
* Fix 32-bit support
|