From patchwork Wed May 9 15:36:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Seth Forshee X-Patchwork-Id: 10389809 X-Patchwork-Delegate: johannes@sipsolutions.net Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3297760236 for ; Wed, 9 May 2018 15:36:28 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 224101FF60 for ; Wed, 9 May 2018 15:36:28 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1516C1FFEB; Wed, 9 May 2018 15:36:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9A88B1FF60 for ; Wed, 9 May 2018 15:36:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964932AbeEIPgZ (ORCPT ); Wed, 9 May 2018 11:36:25 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:58853 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935346AbeEIPgY (ORCPT ); Wed, 9 May 2018 11:36:24 -0400 Received: from mail-it0-f71.google.com ([209.85.214.71]) by youngberry.canonical.com with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.76) (envelope-from ) id 1fGR8h-0007P3-QC for linux-wireless@vger.kernel.org; Wed, 09 May 2018 15:36:23 +0000 Received: by mail-it0-f71.google.com with SMTP id p12-v6so15167802itc.7 for ; Wed, 09 May 2018 08:36:23 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=8uphhbHdVLeIPeczOAuMq0slBoC1ijNS4reDGkeRvPE=; b=V8kN4i3eDG1KXIn24aLMk4uxufXFGs/1/1lYKHtfx3SSGHynSOCqoZZ/ZuuFxDO41m +QgSP/4AVSngfkRacnJ7OiSx3HDFawi+mIuww5weD6x2B0dIVh6WkawFdP8TyXbMnW9e XmrIVIFAoeXAZVhuELzWD23w8asryXLKV98MJAQLueFAzl1XVTQTv5kgfAySah/X052R fpnKlqhkclCAoaTBMrzlGQizroD/lImT7D/5Zox2ZIwuRzFCeJdYXT4BOAXwU/5ywmsA li8T5H/e+bB5/pLkyCxkE5mBTyw/qjiYwqKD5/yCgti2Znhb7pAgUJVXWLCBzxlZZ79c 9jPA== X-Gm-Message-State: ALQs6tBD6C1JaGP3B/L9oLTahR/1C5zhpWhHi8eFJUnMdrU4OFV6545R kItYEcNEzvp1je95CDsRPbWXisjHb02rqhdZg0p4BbthP/BZGbHPNP1GsyFkU1SMF8Ege/pUF29 td3dyfqpPbz8SLiazB9hkeQcQNGoTGlCi6nJdwh53XEPw X-Received: by 2002:a6b:248e:: with SMTP id k136-v6mr46605468iok.270.1525880182503; Wed, 09 May 2018 08:36:22 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpN7kwOQr9D+7aLP4KxyL2BFFwggdPbZDSaoEkKo78L9ZXnufruFd01PolOpF7VnuBaPbJKwA== X-Received: by 2002:a6b:248e:: with SMTP id k136-v6mr46605444iok.270.1525880182210; Wed, 09 May 2018 08:36:22 -0700 (PDT) Received: from localhost ([2605:a601:ac6:7f20:6c4e:227b:62c4:1894]) by smtp.gmail.com with ESMTPSA id n142-v6sm7013407itn.38.2018.05.09.08.36.21 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 09 May 2018 08:36:21 -0700 (PDT) From: Seth Forshee To: Johannes Berg Cc: linux-wireless@vger.kernel.org Subject: [PATCH] iw: support reloading the regulatory database Date: Wed, 9 May 2018 10:36:20 -0500 Message-Id: <20180509153620.23630-1-seth.forshee@canonical.com> X-Mailer: git-send-email 2.17.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add a "iw reg reload" command, useful for testing new regulatory databases. Signed-off-by: Seth Forshee --- reg.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/reg.c b/reg.c index cee0b5e8cedb..cadff3884c04 100644 --- 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.");