git.openpandora.org
/
pandora-u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
62fe870
)
test/py: spi: prevent overwriting relocation memory
author
Padmarao Begari
<padmarao.begari@amd.com>
Tue, 29 Oct 2024 11:47:09 +0000
(17:17 +0530)
committer
Tom Rini
<trini@konsulko.com>
Fri, 1 Nov 2024 19:37:19 +0000
(13:37 -0600)
Update spi negative test case to prevent SF command
from overwriting relocation memory area.
Signed-off-by: Padmarao Begari <padmarao.begari@amd.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Love Kumar <love.kumar@amd.com>
test/py/tests/test_spi.py
patch
|
blob
|
history
diff --git
a/test/py/tests/test_spi.py
b/test/py/tests/test_spi.py
index
3160d58
..
caca930
100644
(file)
--- a/
test/py/tests/test_spi.py
+++ b/
test/py/tests/test_spi.py
@@
-693,4
+693,16
@@
def test_spi_negative(u_boot_console):
u_boot_console, 'read', offset, size, addr, 1, error_msg, EXPECTED_READ
)
+ # Read to relocation address
+ output = u_boot_console.run_command('bdinfo')
+ m = re.search('relocaddr\s*= (.+)', output)
+ res_area = int(m.group(1), 16)
+
+ start = 0
+ size = 0x2000
+ error_msg = 'ERROR: trying to overwrite reserved memory'
+ flash_ops(
+ u_boot_console, 'read', start, size, res_area, 1, error_msg, EXPECTED_READ
+ )
+
i = i + 1