[U-Boot] Bug in load command
Pascal Huerst
pascal.huerst at gmail.com
Fri Feb 24 11:31:24 UTC 2017
Hey everyone,
I just observed the following behavior and I'm not sure, If I missed
something or if there is a BUG in load command: I load a file from usb
to memory and show its content like so:
=> usb start; setenv addr 0x80000000; load usb 0:1 ${addr} testfile
starting USB...
USB0: scanning bus 0 for devices... 1 USB Device(s) found
scanning usb for storage devices... 1 Storage Device(s) found
reading testfile
20029 bytes read in 39 ms (501 KiB/s)
=> md ${addr}
80000000: 204f675c d7c0263c e0875d72 bfbc8c4b \gO <&..r]..K...
80000010: 7ea6702e 492d37bb c9225961 044aa664 .p.~.7-IaY".d.J.
80000020: 5193ee6d 8de34208 f0fac9c0 10e5a814 m..Q.B..........
80000030: db1f823d a2883804 595c0529 b744e8d9 =....8..).\Y..D.
80000040: 5b9bdc92 fd93191a 3b51e8c7 d3baa331 ...[......Q;1...
80000050: fe092431 cf16cd03 aafdfa7f 2c47aa0c 1$............G,
80000060: ffbb67b7 c9856c55 9f9578dc 0f3f7050 .g..Ul...x..Pp?.
80000070: 4bce3a17 0ff738b0 80d0143a 505ee95a .:.K.8..:...Z.^P
80000080: be9237b9 d69cc4d6 90ec7c15 9785f22a .7.......|..*...
80000090: a7ff0f4a fbd37b31 30add2b1 4e97c6c9 J...1{.....0...N
800000a0: 64d980dd 5f5836f4 67183dca 215d5225 ...d.6X_.=.g%R]!
800000b0: dc5f7c4a d738bc6b e075a4a4 137466b4 J|_.k.8...u..ft.
800000c0: 78aefc22 96c672d8 b944b576 bbe0d04f "..x.r..v.D.O...
800000d0: ba5163fe 61732089 59def6a1 77a90f0f .cQ.. sa...Y...w
800000e0: 52549f7d 750da30f f25892ad 92ef75ae }.TR...u..X..u..
800000f0: 6e180a6b 02d92cb4 ada8bf06 8d55c2ca k..n.,........U.
Compared to what I have on my laptop:
hexdump -n $((16*16)) ./testfile
0000000 675c 204f 263c d7c0 5d72 e087 8c4b bfbc
0000010 702e 7ea6 37bb 492d 5961 c922 a664 044a
0000020 ee6d 5193 4208 8de3 c9c0 f0fa a814 10e5
0000030 823d db1f 3804 a288 0529 595c e8d9 b744
0000040 dc92 5b9b 191a fd93 e8c7 3b51 a331 d3ba
0000050 2431 fe09 cd03 cf16 fa7f aafd aa0c 2c47
0000060 67b7 ffbb 6c55 c985 78dc 9f95 7050 0f3f
0000070 3a17 4bce 38b0 0ff7 143a 80d0 e95a 505e
0000080 37b9 be92 c4d6 d69c 7c15 90ec f22a 9785
0000090 0f4a a7ff 7b31 fbd3 d2b1 30ad c6c9 4e97
00000a0 80dd 64d9 36f4 5f58 3dca 6718 5225 215d
00000b0 7c4a dc5f bc6b d738 a4a4 e075 66b4 1374
00000c0 fc22 78ae 72d8 96c6 b576 b944 d04f bbe0
00000d0 63fe ba51 2089 6173 f6a1 59de 0f0f 77a9
00000e0 9f7d 5254 a30f 750d 92ad f258 75ae 92ef
00000f0 0a6b 6e18 2cb4 02d9 bf06 ada8 c2ca 8d55
Looks like the first 4 Bytes (675c) get lost somehow in u-boot. Since
this is a 32 Bit platform, it looks like on off-by-one problem to me.
I'm using: U-Boot 2016.11 on am335x CPU (BeagleBoneBlack)
Regards
Pascal
More information about the U-Boot
mailing list