mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2025-08-10 09:17:00 +02:00
test/cmd/mem_copy.c: Use CONFIG_SYS_LOAD_ADDR for base
When reading/writing to memory we cannot assume that a base address of 0x0 is correct and functional. So use CONFIG_SYS_LOAD_ADDR as the base from which we add a bit more padding and being our tests. Signed-off-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
parent
57ea496c38
commit
15a55dbff6
@ -21,7 +21,7 @@ struct param {
|
|||||||
static int do_test(struct unit_test_state *uts,
|
static int do_test(struct unit_test_state *uts,
|
||||||
const char *suffix, int d, int s, int count)
|
const char *suffix, int d, int s, int count)
|
||||||
{
|
{
|
||||||
const long addr = 0x1000;
|
const long addr = CONFIG_SYS_LOAD_ADDR + 0x1000;
|
||||||
u8 shadow[BUF_SIZE];
|
u8 shadow[BUF_SIZE];
|
||||||
u8 *buf;
|
u8 *buf;
|
||||||
int i, w, bytes;
|
int i, w, bytes;
|
||||||
|
Loading…
Reference in New Issue
Block a user