From de6e57ff6dd4bab3d2a78f8d01b2bfecbd663fc4 Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Mon, 6 Nov 2017 03:34:35 +0100 Subject: Simplify allyesconfig.py Can be implemented in a simpler/better way with Choice.assignable. Also rename 'conf' to 'kconf' in allnoconfig.py for consistency. --- examples/allnoconfig.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'examples/allnoconfig.py') diff --git a/examples/allnoconfig.py b/examples/allnoconfig.py index 47a8026..127c60d 100644 --- a/examples/allnoconfig.py +++ b/examples/allnoconfig.py @@ -38,10 +38,11 @@ def do_allnoconfig(node): node = node.next -conf = Kconfig(sys.argv[1]) +# Parse the Kconfig files +kconf = Kconfig(sys.argv[1]) -# Do an initial pass to set 'option allnoconfig_y' symbols to 'y' -for sym in conf.defined_syms: +# Do an initial pass to set 'option allnoconfig_y' symbols to y +for sym in kconf.defined_syms: if sym.is_allnoconfig_y: sym.set_value(2) @@ -52,10 +53,10 @@ while 1: # until we're no longer able to change the value of any symbol in a pass. changed = False - do_allnoconfig(conf.top_node) + do_allnoconfig(kconf.top_node) # Did the pass change any symbols? if not changed: break -conf.write_config(".config") +kconf.write_config(".config") -- cgit v1.2.3