Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5a2bd464 authored by Lior David's avatar Lior David
Browse files

Revert "cfg80211: reg: remove support for built-in regdb"



This reverts commit c8c240e2.

Restore support for internal regulatory database. It is
needed since Android does not have CRDA.
Fix checker errors related to defconfig files.

Change-Id: Ie60e0f4dd450c6efbbc8643e01c946bc11b557ee
Signed-off-by: default avatarLior David <liord@codeaurora.org>
parent ce7a6222
Loading
Loading
Loading
Loading
+20 −2
Original line number Diff line number Diff line
@@ -200,5 +200,23 @@ Then in some part of your code after your wiphy has been registered:
Statically compiled regulatory database
---------------------------------------

When a database should be fixed into the kernel, it can be provided as a
firmware file at build time that is then linked into the kernel.
In most situations the userland solution using CRDA as described
above is the preferred solution.  However in some cases a set of
rules built into the kernel itself may be desirable.  To account
for this situation, a configuration option has been provided
(i.e. CONFIG_CFG80211_INTERNAL_REGDB).  With this option enabled,
the wireless database information contained in net/wireless/db.txt is
used to generate a data structure encoded in net/wireless/regdb.c.
That option also enables code in net/wireless/reg.c which queries
the data in regdb.c as an alternative to using CRDA.

The file net/wireless/db.txt should be kept up-to-date with the db.txt
file available in the git repository here:

    git://git.kernel.org/pub/scm/linux/kernel/git/sforshee/wireless-regdb.git

Again, most users in most situations should be using the CRDA package
provided with their distribution, and in most other situations users
should be building and using CRDA on their own rather than using
this option.  If you are not absolutely sure that you should be using
CONFIG_CFG80211_INTERNAL_REGDB then _DO_NOT_USE_IT_.
+0 −1
Original line number Diff line number Diff line
@@ -244,7 +244,6 @@ CONFIG_BT=y
CONFIG_MSM_BT_POWER=y
CONFIG_BT_SLIM_QCA6390=y
CONFIG_CFG80211=y
# CONFIG_CFG80211_CRDA_SUPPORT is not set
CONFIG_RFKILL=y
CONFIG_NFC_NQ=y
CONFIG_FW_LOADER_USER_HELPER=y
+0 −1
Original line number Diff line number Diff line
@@ -219,7 +219,6 @@ CONFIG_QRTR=y
CONFIG_QRTR_SMD=y
CONFIG_BT=y
CONFIG_CFG80211=y
# CONFIG_CFG80211_CRDA_SUPPORT is not set
CONFIG_RFKILL=y
CONFIG_FW_LOADER_USER_HELPER=y
CONFIG_FW_LOADER_USER_HELPER_FALLBACK=y
+1 −0
Original line number Diff line number Diff line
regdb.c
shipped-certs.c
extra-certs.c
+23 −1
Original line number Diff line number Diff line
@@ -175,8 +175,30 @@ config CFG80211_DEBUGFS

	  If unsure, say N.

config CFG80211_INTERNAL_REGDB
	bool "use statically compiled regulatory rules database" if EXPERT
	default n
	depends on CFG80211
	---help---
	  This option generates an internal data structure representing
	  the wireless regulatory rules described in net/wireless/db.txt
	  and includes code to query that database. This is an alternative
	  to using CRDA for defining regulatory rules for the kernel.

	  Using this option requires some parsing of the db.txt at build time,
	  the parser will be upkept with the latest wireless-regdb updates but
	  older wireless-regdb formats will be ignored. The parser may later
	  be replaced to avoid issues with conflicts on versions of
	  wireless-regdb.

	  For details see:

	  http://wireless.kernel.org/en/developers/Regulatory

	  Most distributions have a CRDA package. So if unsure, say N.

config CFG80211_CRDA_SUPPORT
	bool "support CRDA" if EXPERT
	bool "support CRDA" if CFG80211_INTERNAL_REGDB
	default y
	help
	  You should enable this option unless you know for sure you have no
Loading