Skip to contentSkip to conversation

cmd_mem: fix cp command

PATCH New Masahiro Yamada 2 participants 2 messages May 21, 2013 – May 24, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 cmd_mem: fix cp command

The "cp" command has not worked since
commit 0628ab8ec59834f98ede267edd21ddb8ba0bb57b, because of the following lines, which set the destination and the source to the same address.

	buf = map_sysmem(addr, bytes);
	src = map_sysmem(addr, bytes);
---
 common/cmd_mem.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
common/cmd_mem.c +1 -1
index 64dd76a..6df00b1 100644
@@ -445,7 +445,7 @@ static int do_mem_cp(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 #endif
 
 	bytes = size * count;
-	buf = map_sysmem(addr, bytes);
+	buf = map_sysmem(dest, bytes);
 	src = map_sysmem(addr, bytes);
 	while (count-- > 0) {
 		if (size == 4)
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/1 cmd_mem: fix cp command

Quoted 9 lines · Masahiro Yamada

The "cp" command has not worked since
commit 0628ab8ec59834f98ede267edd21ddb8ba0bb57b, because of the following lines, which set the destination and the source to the same address.

	buf = map_sysmem(addr, bytes);
	src = map_sysmem(addr, bytes);

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20130524/a4fe0e43/attachment.pgp>