Forum Discussion
Actually I have followed the document from here. The document is also attached here below. ( starts at page 68 ).
Basically What I did is
=> created a preloader image file using bsp-editor
=> build u-boot from git://git.denx.de/u-boot.git (before building I changed the content of file "/u-boot/include/configs/socfpga_cyclone5_socdk.h"
changed #define CONFIG_BOOTCOMMAND value to "run callscript"
and replaced #define CONFIG_EXTRA_ENV_SETTINGS value to
"scriptfile=u-boot.scr" "\0" \
"fpgadata=0x2000000" "\0" \
"callscript=fatload mmc 0:1 $fpgadata $scriptfile;" \
"source $fpgadata" "\0"
It was written in the document ( page 71 ) that it was done to make sure that our custom boot script will run after preloader.
The u-boot.script file is also attacehd here for the reference. starting few lines are ################################################################################
echo --- Resetting Env variables ---
# reset environment variables to default
env default -a
echo --- Setting Env variables ---
# Set the kernel image
setenv bootimage zImage;
but as seen in the logs on putty snapshot below this script is not being executed and some other error occurred. Could you kindly look into it.