Cannot Fully Execute mkimg Script

Chris Johns chrisj at rtems.org
Sun Sep 11 21:37:37 UTC 2016


On 12/09/2016 01:42, Spencer Deevy wrote:
> Hello everyone, it's Spencer again. I have successfully compiled and
> built RTEMS for my desired board (Xilinx Zedboard), but I've run into an
> issue with trying to convert the ticker.exe program to an image that
> U-Boot can load it. I am using the following script:
>
> #! /bin/sh
>
> OBJCOPY_FOR_TARGET=~/development/rtems/compiler/4.12/bin/arm-rtems4.12-objcopy
> OBJCOPY="$OBJCOPY_FOR_TARGET"
>
> EXE_NAME=$1
>
> START_ADDR=0x00104000
> ENTRY_ADDR=0x00104000
>
> ${OBJCOPY} -R -S --strip-debug -O binary "$EXE_NAME" "$EXE_NAME.bin" ||
> exit 1
> cat "$EXE_NAME.bin" | gzip -9 >"$EXE_NAME.gz"
> mkimage \
>    -A arm -O rtems -T kernel -a $START_ADDR -e $ENTRY_ADDR -n "RTEMS" \
>    -d "$EXE_NAME.gz" "$EXE_NAME.img"
>
> OBJCOPY_FOR_TARGET is the path for the objcopy program used to create
> the flat binary
> EXE_NAME is where I pass in the path for the ticker.exe program to be
> converted
>
> I've tested it a few times and this is what I've determined thus far:
>
> - The program fails when it tries to make the flat binary
> - The error I'm getting is 'bus error (core dumped)'
>
> I've checked that the paths are all correct, and I don't think it's a
> permission issue.
>  From googling around a bit it looks like it's an issue with trying to
> access memory that is unavailable...
>
> If anyone has any insight into this, I would greatly appreciate the help.
>

Which command in the script is causing the bus error?

Chris



More information about the users mailing list