Add a --post-flash-cmd command line argument
PATCH v2 1/1 Add a --post-flash-cmd command line argument
This allows a user to specify the u-boot command to run after flashing is complete (e.g 'ums 0 mmc 0'), defaults to 'reset' if not set
Signed-off-by James Thomas <[email protected]>
--- tegra-uboot-flasher | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
tegra-uboot-flasher +6 -1
@@ -218,7 +218,10 @@ def func_flash(): bootcmd += 'echo >>> Flashing OK, rebooting... ; ' # To update the bootloader, reset. # If wanting to run installer, set installer_args.configname in environment, 'run bootcmd' - bootcmd += 'reset' + if args.post_flash_cmd: + bootcmd += args.post_flash_cmd + else: + bootcmd += 'reset' print 'bootcmd:', bootcmd cmd = ['fdtput', '-p', '-t', 's', u_boot_dtb_runflash, '/config', 'bootcmd', bootcmd] run(workdir, cmd)
@@ -307,6 +310,8 @@ parser_flash.add_argument('--env', type=str, nargs=2, action='append', metavar=("VAR", "VALUE"), help='Set a U-Boot environment variable after flashing. This option ' + 'may be given multiple times') +parser_flash.add_argument('--post-flash-cmd', type=str, + help='The U-Boot command to run after flashing, defaults to \'reset\'') parser_exec = subparsers.add_parser('exec', help='Download and execute an unmodified bootloader binary, named ' +
Signature · 1 line
1.9.3
A message that is not in the archive (sent off-list or not yet received): 1417694039-13060-1-git-send-email-james.thomas-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org
Stephen Warren
AppliedQuoted 2 lines · James Thomas
This allows a user to specify the u-boot command to run after flashing is complete (e.g 'ums 0 mmc 0'), defaults to 'reset' if not set
I've applied this. Thanks.