All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] Add support for tegrarcm's --usb-port-path cmdline option
@ 2015-12-08 17:47 Stephen Warren
       [not found] ` <1449596849-27393-1-git-send-email-swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Stephen Warren @ 2015-12-08 17:47 UTC (permalink / raw)
  To: swarren-3lzwWm7+Weoh9ZMKESR00Q
  Cc: linux-tegra-u79uwXL29TY76Z2rM5mHXA, Stephen Warren

From: Stephen Warren <swarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>

This allows the user to specify which USB device to operate on. See
the related tegrarcm commit for a full description of this option and
how to calculate the required option value. An example is:

    ./tegra-uboot-flasher exec --usb-port-path 3-10.5 jetson-tk1

Signed-off-by: Stephen Warren <swarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
---
 tegra-uboot-flasher | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/tegra-uboot-flasher b/tegra-uboot-flasher
index d20e3ad413ef..3a77a8be9e6b 100755
--- a/tegra-uboot-flasher
+++ b/tegra-uboot-flasher
@@ -93,7 +93,10 @@ def get_loadaddr():
 def gen_tegrarcm_cmd(bootloader, loadaddr):
     if type(loadaddr) != str:
         loadaddr = "0x%08x" % loadaddr
-    return ['tegrarcm', '--bct=' + bct, '--bootloader=' + bootloader , '--loadaddr=' + loadaddr]
+    cmd = ['tegrarcm', '--bct=' + bct, '--bootloader=' + bootloader , '--loadaddr=' + loadaddr]
+    if args.usb_port_path:
+        cmd.extend(['--usb-port-path', args.usb_port_path])
+    return cmd
 
 def find_config_dir():
     if not configs.has_key(args.configname):
@@ -326,6 +329,8 @@ parser_exec.add_argument('--loadaddr', type=str,
     help='Load address for the bootloader binary')
 
 for p in (parser_flash, parser_exec):
+    p.add_argument('--usb-port-path', metavar='USBPORTPATH', type=str,
+        help='The USB port path of the Tegra device')
     p.add_argument('configname', metavar='CONFIG', type=str,
         help='The configuration name of the board')
 
-- 
2.6.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-12-09 23:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-08 17:47 [PATCH 1/2] Add support for tegrarcm's --usb-port-path cmdline option Stephen Warren
     [not found] ` <1449596849-27393-1-git-send-email-swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
2015-12-08 17:47   ` [PATCH 2/2] Determine SPL entry-point automatically Stephen Warren
2015-12-09 23:49   ` [PATCH 1/2] Add support for tegrarcm's --usb-port-path cmdline option Stephen Warren

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.