From: Stephen Warren <[email protected]>

This moves towards each sub-command being a separate function

Signed-off-by: Stephen Warren <[email protected]>
---
 tegra-uboot-flasher | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/tegra-uboot-flasher b/tegra-uboot-flasher
index ef73e2f..390ae0e 100755
--- a/tegra-uboot-flasher
+++ b/tegra-uboot-flasher
@@ -86,6 +86,10 @@ def find_config_dir():
     socname = boards[boardname]['soc']
     out_board_dir = os.path.join(args.data_dir, boardname)
 
+def func_list_configs():
+    for configname in sorted(configs.keys()):
+        print configname
+
 parser = argparse.ArgumentParser(description='Write an image to a Tegra 
board\'s flash')
 parser.add_argument('--debug', action='store_true',
                    help='Turn on debugging prints')
@@ -129,8 +133,7 @@ if not args.data_dir:
 load_configs(os.path.join(args.data_dir, 'configs'))
 
 if args.list_confignames:
-    for configname in sorted(configs.keys()):
-        print configname
+    func_list_configs()
     sys.exit(0)
 
 find_config_dir()
-- 
1.8.1.5

--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to