diff --git a/fpga/fpgactl b/fpga/fpgactl index 1b8bf44..2e0ac2c 100755 --- a/fpga/fpgactl +++ b/fpga/fpgactl @@ -264,14 +264,16 @@ function load_bitstream() # {{{ bitstream= bootloader= -kernelfile= -reloadfs= +kernel= +initrd= +rootfs= resetcpu= verbose= bootloader_addr=0x80000000 kernel_addr=0x84000000 initrd_addr=0x8c300000 +rootfs_addr=0x180000000 function usage() { @@ -286,18 +288,20 @@ function usage() echo " -b bootloader Load the bootloader file in $bootloader_addr" >&2 echo " -k kernel Load the kernel file in $kernel_addr" >&2 echo " -i initrd Load the initrd file in $initrd_addr" >&2 + echo " -r rootfs Load the rootfs file in $rootfs_addr" >&2 echo " -v Be verbose" >&2 echo "" >&2 exit 1 } -while getopts "hvw:b:k:i:" opt; do +while getopts "hvw:b:k:i:r:" opt; do case "${opt}" in v) verbose=1 ;; w) bitstream="${OPTARG}" ;; b) bootloader="${OPTARG}"; resetcpu=1 ;; k) kernel="${OPTARG}"; resetcpu=1 ;; i) initrd="${OPTARG}"; resetcpu=1 ;; + r) rootfs="${OPTARG}"; resetcpu=1 ;; h) usage ;; *) usage ;; esac @@ -312,6 +316,7 @@ test "$resetcpu" && do_system_reset test "$bootloader" && load_file_in_memory "$bootloader" $bootloader_addr test "$kernel" && load_file_in_memory "$kernel" $kernel_addr test "$initrd" && load_file_in_memory "$initrd" $initrd_addr +test "$rootfs" && load_file_in_memory "$rootfs" $rootfs_addr test "$resetcpu" && do_system_release # vim:ts=2:sw=2:ai:foldmethod=marker:foldlevel=0: