Openembedded Devel Discussions
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: openembedded-devel@lists.openembedded.org
Subject: [meta-networking][PATCH v5 2/3] wireless-regdb: Add wireless-regdb-static package with static regulatory data
Date: Thu,  5 Jul 2018 20:58:11 +0200	[thread overview]
Message-ID: <20180705185812.23209-3-krzk@kernel.org> (raw)
In-Reply-To: <20180705185812.23209-1-krzk@kernel.org>

Small embedded systems might:
1. Want to get rid of daemons as much as possible (therefore be built
   without CRDA),
2. Not receive user-space incremental updates but an entire system
   upgrade (with kernel).

Linux kernel since v4.15 allows loading static regulatory data from
/lib/firmware/regulatory.db.

Add additional package to wireless-regdb recipe which provides such
static data.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 .../wireless-regdb/wireless-regdb_2018.05.31.bb             | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb b/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb
index 8bb866ff1281..2ae9e85427bc 100644
--- a/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb
+++ b/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb
@@ -15,6 +15,19 @@ do_install() {
     install -d -m0755 ${D}${sysconfdir}/wireless-regdb/pubkeys
     install -m 0644 regulatory.bin ${D}${libdir}/crda/regulatory.bin
     install -m 0644 sforshee.key.pub.pem ${D}${sysconfdir}/wireless-regdb/pubkeys/sforshee.key.pub.pem
+
+    install -m 0644 -D regulatory.db ${D}${nonarch_base_libdir}/firmware/regulatory.db
+    install -m 0644 regulatory.db.p7s ${D}${nonarch_base_libdir}/firmware/regulatory.db.p7s
 }
 
+# Install static regulatory DB in /lib/firmware for kernel to load.
+# This requires Linux kernel >= v4.15.
+PACKAGES =+ "${PN}-static"
+RCONFLICTS_${PN} = "${PN}-static"
+
+FILES_${PN}-static = " \
+    ${nonarch_base_libdir}/firmware/regulatory.db \
+    ${nonarch_base_libdir}/firmware/regulatory.db.p7s \
+"
+
 RSUGGESTS_${PN} = "crda"
-- 
2.14.1



  parent reply	other threads:[~2018-07-05 18:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-05 18:58 [meta-networking][PATCH v5 0/3] Add static/embedded wireless regulatory data Krzysztof Kozlowski
2018-07-05 18:58 ` [meta-networking][PATCH v5 1/3] wireless-regdb: Bump version to latest upstream 2018.05.31 Krzysztof Kozlowski
2018-07-05 18:58 ` Krzysztof Kozlowski [this message]
2018-07-05 18:58 ` [meta-networking][PATCH v5 3/3] kernel_wireless_regdb: Add class for embedding regulatory data into older kernel Krzysztof Kozlowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180705185812.23209-3-krzk@kernel.org \
    --to=krzk@kernel.org \
    --cc=openembedded-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox