lkml.org 
[lkml]   [2014]   [Nov]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v3 05/21] backports: keep track of original backported source symbols early on
Date
From: "Luis R. Rodriguez" <mcgrof@suse.com>

We'll later want to do some modifications of symbols we backport
when integrating, but before we do any modification on kconfig
files we should keep track of the original source symbols.

This commit introduces no functional changes right now, it will
become more useful after we start adjusting kconfig entries
for integration.

Signed-off-by: Luis R. Rodriguez <mcgrof@suse.com>
---
gentree.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gentree.py b/gentree.py
index 7a6deef..cb39a3f 100755
--- a/gentree.py
+++ b/gentree.py
@@ -768,6 +768,7 @@ def process(kerneldir, outdir, copy_list_file, git_revision=None,

# some post-processing is required
configtree = kconfig.ConfigTree(os.path.join(args.outdir, 'Kconfig'))
+ orig_symbols = configtree.symbols()
logwrite('Modify Kconfig tree ...')
configtree.prune_sources(ignore=['Kconfig.kernel', 'Kconfig.versions'])
git_debug_snapshot(args, "prune Kconfig tree")
@@ -829,7 +830,7 @@ def process(kerneldir, outdir, copy_list_file, git_revision=None,

# rewrite Makefile and source symbols
regexes = []
- for some_symbols in [symbols[i:i + 50] for i in range(0, len(symbols), 50)]:
+ for some_symbols in [orig_symbols[i:i + 50] for i in range(0, len(orig_symbols), 50)]:
r = 'CONFIG_((' + '|'.join([s + '(_MODULE)?' for s in some_symbols]) + ')([^A-Za-z0-9_]|$))'
regexes.append(re.compile(r, re.MULTILINE))
for root, dirs, files in os.walk(args.outdir):
--
2.1.1


\
 
 \ /
  Last update: 2014-11-11 09:21    [W:0.242 / U:0.620 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site