On 12/2/21 2:31 am, [email protected] wrote: > There has been a small typo in the previous patch.
Thank you for the patch. Could you please send it as a git patch to [email protected] or attach it to a ticket in Trac? This may help ... https://docs.rtems.org/branches/master/eng/vc-users.html?highlight=commit#creating-a-patch Thanks Chris > > -----Ursprüngliche Nachricht----- > Von: users <[email protected]> Im Auftrag von [email protected] > Gesendet: Donnerstag, 11. Februar 2021 16:14 > An: [email protected] > Betreff: AW: RTEMS mkimage.py for U-Boot scripts > > Hello, > > after some digging I think I found the problem and at least a workaround. > > As a disclaimer, I do not know if this really counts as a general fix. > I have not invested enough time to dig through the original mkimage U-Boot > source to figure this out. > But I have attached my workaround patch if anyone might face the same > problems. > > The source of the problem are eight bytes between the header and the actual > input file which are missing when using mkimage.py. > Also the input size and input crc are wrong which is a result of the missing > bytes. > > These eight bytes always reflect the actual size of the input file (first > four bytes) with four bytes zeros following. > Within the original mkimage tool these eight bytes are considered part of the > input file section in the output file. > Therefore the calculated input size is eight bytes higher and the input crc > differs. > > As a workaround the mkimage.py script will add these eight bytes to the > output file and the input crc calculation and adjusts the input size. > This only happens when the type script was selected. > > Best regards > André > > -----Ursprüngliche Nachricht----- > Von: users <[email protected]> Im Auftrag von [email protected] > Gesendet: Dienstag, 26. Januar 2021 08:09 > An: [email protected] > Betreff: RTEMS mkimage.py for U-Boot scripts > > Hello, > > in our laboratory setup we use different U-Boot scripts to control the boot > behavior of our development board (Trenz TE0715 [1] on top of Trenz TE0706 > [2]). > > These simple scripts need to be converted into a script image using the > mkimage command for U-Boot. [3] We use the following command which works fine: > > ./mkimage -A arm -T script -C none -n "fancy name" -d bootscripts/rtems > rtems.img > Image Name: fancy name > Created: Tue Jan 26 06:57:50 2021 > Image Type: ARM Linux Script (uncompressed) > Data Size: 324 Bytes = 0.32 KiB = 0.00 MiB > Load Address: 00000000 > Entry Point: 00000000 > Contents: > Image 0: 316 Bytes = 0.31 KiB = 0.00 MiB > > Because our setup also depends on the rtems-zynq-mkimg command and the rtems > environment to be available we wanted to switch to the usage of the > mkimage.py command which comes via RTEMS. > BUT every script image we generate with this tool behaves different than the > one we generated with mkimage. > First of all is the output different, including a different resulting file > size and a missing contents section. > > mkimage.py -A arm -T script -C none -n "fancy name" -d bootscripts/rtems > rtems.img > Image Name: fancy name > Created: Tue Jan 26 08:00:06 2021 > Image Type: none > Data Size: 316 > Load Address: 0 > Entry Point: 0 > > Adding the OS option with linux or u-boot does seem to change something, but > the resulting script image is again not usable. > > I became aware of this because when a script image like this is uploaded to > U-Boot and sourced, no error occurs but also nothing else happens. > Usually it should print some information on what the script is doing and then > well do its intended operations like it does when it is converted via the > mkimage script. > > Has somebody else had the same issue and maybe even overcome it? > Or does anybody have a clue where the problem may originate from? > > Thanks in advance for the answer and help. > > [1] > https://wiki.trenz-electronic.de/display/PD/TE0715+TRM#TE0715TRM-KeyFeatures > [2] > https://wiki.trenz-electronic.de/display/PD/TE0706+TRM#TE0706TRM-KeyFeatures > [3] https://www.denx.de/wiki/DULG/UBootScripts > > Best regards > Andre Nahrwold > -------------------------- > Deutsches Zentrum für Luft- und Raumfahrt e. V. (DLR) German Aerospace Center > Institute for Software Technolog | SRV-OSS BS | Lilienthalpl. 7 | 38108 > Braunschweig | Geb. 112C Raum 001 M.Sc. Andre Nahrwold | Telephone +49 531 > 295-3834 | [email protected] DLR.de > > _______________________________________________ > users mailing list > [email protected] > http://lists.rtems.org/mailman/listinfo/users > > > _______________________________________________ > users mailing list > [email protected] > http://lists.rtems.org/mailman/listinfo/users > _______________________________________________ users mailing list [email protected] http://lists.rtems.org/mailman/listinfo/users
