[U-Boot] [PATCH] net, cmd: fix misaligned cache operation warning
Heiko Schocher
hs at denx.de
Mon Aug 29 07:46:47 CEST 2016
when using tftp on the smartweb board, it prints, when
using the tftp command:
Using ethernet at fffc4000 device
TFTP from server 192.168.1.1; our IP address is 192.168.20.80
Filename '/tftpboot/smartweb_hw/tbot/u-boot.bin'.
Load address: 0x21000000
Loading: ###########################
73.2 KiB/s
done
Bytes transferred = 391560 (5f988 hex)
CACHE: Misaligned operation at range [21000000, 2105f988]
U-Boot#
Fixing this.
Signed-off-by: Heiko Schocher <hs at denx.de>
---
cmd/net.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cmd/net.c b/cmd/net.c
index b2f3c7b..540daeb 100644
--- a/cmd/net.c
+++ b/cmd/net.c
@@ -244,7 +244,7 @@ static int netboot_common(enum proto_t proto, cmd_tbl_t *cmdtp, int argc,
}
/* flush cache */
- flush_cache(load_addr, size);
+ flush_cache(load_addr, ALIGN(size, CONFIG_SYS_CACHELINE_SIZE));
bootstage_mark(BOOTSTAGE_ID_NET_LOADED);
--
2.5.5
More information about the U-Boot
mailing list