summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2013-04-04 01:28:47 +0200
committerJohannes Berg <johannes@sipsolutions.net>2013-04-04 01:38:17 +0200
commitf9227077fe2908f189e4da88bfa8bc1ac17e02a4 (patch)
treeace66774c8b02cffeeb974f8a50ea0a7f4993a0e
parentb7b470b7df1d946d9c6e655f3c6f1837bac5a949 (diff)
build: add defconfig files
This enables users to more easily select the driver that they need, and us to ship default configurations that we prefer for that driver. Add iwlwifi as the first example. Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
-rw-r--r--backport/Makefile.real12
-rw-r--r--backport/defconfigs/iwlwifi17
-rwxr-xr-xgentree.py7
3 files changed, 30 insertions, 6 deletions
diff --git a/backport/Makefile.real b/backport/Makefile.real
index c419772a..07eb8fc4 100644
--- a/backport/Makefile.real
+++ b/backport/Makefile.real
@@ -27,13 +27,23 @@ usedefconfig:
@$(MAKE) -C kconfig conf
@./kconfig/conf --defconfig=defconfig Kconfig
+defconfig-%::
+ @$(MAKE) -C kconfig conf
+ @./kconfig/conf --defconfig=defconfigs/$(@:defconfig-%=%) Kconfig
+
.config:
@test -f defconfig && (yes '' | $(MAKE) usedefconfig) || ( \
echo "/--------------" ;\
echo "| Your backport package isn't configured, please configure it" ;\
echo "| using one of the following options:" ;\
+ echo "| To configure manually:" ;\
+ echo "| make oldconfig" ;\
echo "| make menuconfig" ;\
- echo "| make allyesconfig" ;\
+ echo "|" ;\
+ echo "| To get defaults for certain drivers:" ;\
+ (cd defconfigs ; for f in $$(ls) ; do \
+ echo "| make defconfig-$$f" ;\
+ done ) ;\
echo "\--" ;\
false )
diff --git a/backport/defconfigs/iwlwifi b/backport/defconfigs/iwlwifi
new file mode 100644
index 00000000..6a5f4bae
--- /dev/null
+++ b/backport/defconfigs/iwlwifi
@@ -0,0 +1,17 @@
+CPTCFG_CFG80211=m
+CPTCFG_CFG80211_DEFAULT_PS=y
+CPTCFG_CFG80211_DEBUGFS=y
+CPTCFG_MAC80211=m
+# CPTCFG_MAC80211_RC_PID is not set
+# CPTCFG_MAC80211_RC_MINSTREL is not set
+# CPTCFG_MAC80211_RC_DEFAULT_MINSTREL is not set
+CPTCFG_MAC80211_DEBUGFS=y
+CPTCFG_MAC80211_MESSAGE_TRACING=y
+CPTCFG_WLAN=y
+CPTCFG_IWLWIFI=m
+CPTCFG_IWLDVM=m
+CPTCFG_IWLMVM=m
+CPTCFG_IWLWIFI_DEBUG=y
+CPTCFG_IWLWIFI_DEBUGFS=y
+CPTCFG_IWLWIFI_DEVICE_TRACING=y
+CPTCFG_IWLWIFI_P2P=y
diff --git a/gentree.py b/gentree.py
index 696a960c..375479d0 100755
--- a/gentree.py
+++ b/gentree.py
@@ -137,10 +137,7 @@ def copy_files(srcpath, copy_list, outdir):
def copy_ignore(dir, entries):
r = []
for i in entries:
- if (not i[-1] in ('c', 'h') and
- i[-4:] != '.awk' and
- not i in ('Kconfig', 'Makefile') and
- not os.path.isdir(os.path.join(dir, i))):
+ if i[-1] in ('o', '~'):
r.append(i)
return r
copytree(os.path.join(srcpath, srcitem),
@@ -267,7 +264,7 @@ def process(kerneldir, outdir, copy_list_file, git_revision=None,
# do the copy
backport_files = [(x, x) for x in [
'Kconfig', 'Makefile', 'Makefile.build', 'Makefile.kernel',
- 'Makefile.real', 'compat/', 'include/', 'kconfig/',
+ 'Makefile.real', 'compat/', 'include/', 'kconfig/', 'defconfigs/',
]]
if not args.git_revision:
logwrite('Copy original source files ...')