diff options
author | Heinrich Schuchardt <heinrich.schuchardt@canonical.com> | 2024-11-02 07:32:26 +0100 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2024-11-14 18:14:05 -0600 |
commit | 1f66c0e1f4ffb2f9f0fea8fcb7118028039e76a2 (patch) | |
tree | 84dfed375fb2b9e4d8d476bc4f51a7058c43545a /test/py/tests/test_source.py | |
parent | 1b99c15d73c10a7f5953e7cd69264754f5f604ba (diff) |
lmb: do not panic in lmb_print_region_flags
Commit c3cf0dc64f1c ("lmb: add a check to prevent memory overrun")
addressed a possible buffer overrun using assert_noisy().
Resetting via panic() in lmb_print_region() while allowing invalid
lmb flags elsewhere is not reasonable.
Instead of panicking print a message indicating the problem.
fls() returns an int. Using a u64 for bitpos does not match.
Use int instead.
fls() takes an int as argument. Using 1ull << bitpos generates a u64.
Use 1u << bitpos instead.
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Acked-by: Sughosh Ganu <sughosh.ganu@linaro.org>
Diffstat (limited to 'test/py/tests/test_source.py')
0 files changed, 0 insertions, 0 deletions