]> git.ipfire.org Git - thirdparty/iw.git/commitdiff
iw: support reloading the regulatory database
authorSeth Forshee <seth.forshee@canonical.com>
Wed, 9 May 2018 15:36:20 +0000 (10:36 -0500)
committerJohannes Berg <johannes.berg@intel.com>
Fri, 18 May 2018 08:04:24 +0000 (10:04 +0200)
Add a "iw reg reload" command, useful for testing new regulatory
databases.

Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
reg.c

diff --git a/reg.c b/reg.c
index cee0b5e8cedbe09d1908965e8426f5f6c58b33db..cadff3884c041c2a9b615701c939771119854929 100644 (file)
--- a/reg.c
+++ b/reg.c
@@ -259,3 +259,13 @@ COMMAND(reg, get, NULL, NL80211_CMD_GET_REG, 0, CIB_PHY, handle_reg_get,
        "Print out the devices' current regulatory domain information.");
 HIDDEN(reg, dump, NULL, NL80211_CMD_GET_REG, NLM_F_DUMP, CIB_NONE,
        handle_reg_dump);
+
+static int handle_reg_reload(struct nl80211_state *state,
+                            struct nl_msg *msg,
+                            int argc, char **argv,
+                            enum id_input id)
+{
+       return 0;
+}
+COMMAND(reg, reload, NULL, NL80211_CMD_RELOAD_REGDB, 0, CIB_NONE,
+       handle_reg_reload, "Reload the kernel's regulatory database.");