[PATCH v5 2/3] test: Add PStore command tests
Frédéric Danis
frederic.danis at collabora.com
Tue Oct 13 18:35:51 CEST 2020
Hi Tom,
On 13/10/2020 17:48, Tom Rini wrote:
> On Fri, Mar 20, 2020 at 10:59:23AM +0100, Frédéric Danis wrote:
>
>> Add PStore command to sandbox and sandbox64 defconfigs.
>> Add test checking:
>> - 'pstore display' of all records
>> - 'pstore display' only the 2nd dump record
>> - 'pstore save' of all records
>>
>> Signed-off-by: Frédéric Danis <frederic.danis at collabora.com>
>> Cc: Tom Rini <trini at konsulko.com>
>> Cc: Heinrich Schuchardt <xypron.glpk at gmx.de>
>> Cc: Wolfgang Denk <wd at denx.de>
>> Cc: Heiko Schocher <hs at denx.de>
>> ---
>> Changes in v5:
>> - Fix test_pstore.py license
>>
>> Changes in v4:
>> - Fix PStore memory address in sandbox defconfig files for tests
>>
>> Changes in v3:
>> - Replace 1M test file by 3 * 4K files and build pstore memory during test
>>
>> New in v2:
>> - Add unit tests
>>
>> configs/sandbox64_defconfig | 2 +
>> configs/sandbox_defconfig | 2 +
>> test/py/tests/test_pstore.py | 73 +++++++++++++++++++++
>> test/py/tests/test_pstore_data_console.hex | Bin 0 -> 4096 bytes
>> test/py/tests/test_pstore_data_panic1.hex | Bin 0 -> 4096 bytes
>> test/py/tests/test_pstore_data_panic2.hex | Bin 0 -> 4096 bytes
>> 6 files changed, 77 insertions(+)
>> create mode 100644 test/py/tests/test_pstore.py
>> create mode 100644 test/py/tests/test_pstore_data_console.hex
>> create mode 100644 test/py/tests/test_pstore_data_panic1.hex
>> create mode 100644 test/py/tests/test_pstore_data_panic2.hex
> Sorry for the delay here. When I run the tests I see:
> ------------------------------------ Captured stdout call -------------------------------------
> =>
> => => host load hostfs - 0x3000000 test/py/tests/test_pstore_data_panic1.hex
> 4096 bytes read in 0 ms
> => => host load hostfs - 0x3001000 test/py/tests/test_pstore_data_panic2.hex
> 0 bytes read in 0 ms
> => => host load hostfs - 0x30fd000 test/py/tests/test_pstore_data_console.hex
> 4096 bytes read in 0 ms
> => => pstore set 0x3000000 0x100000
> => => pstore save hostfs - /tmp/tmp1xx0rahx
> 3798 bytes written in 1 ms (3.6 MiB/s)
> 4084 bytes written in 0 ms
> => => load hostfs - 1000008 /tmp/tmp1xx0rahx/dmesg-ramoops-0
> 3798 bytes read in 0 ms
> => => printenv filesize
> filesize=ed6
> => => md5sum 1000008 $filesize
> md5 for 01000008 ... 01000edd ==> 8059335ab4cfa62c77324c491659c503
> => => setenv filesize
> => => load hostfs - 1000008 /tmp/tmp1xx0rahx/dmesg-ramoops-1
> Failed to load '/tmp/tmp1xx0rahx/dmesg-ramoops-1'
> => => printenv filesize
> ## Error: "file
> =================================== short test summary info ===================================
>
> So I'm not sure why the second one fails to load.
>
It seems that the "test_pstore_data_panic2.hex" test file was not loaded
correctly in memory, so the "dmesg-ramoops-1" was not generated
Regards,
Fred
More information about the U-Boot
mailing list