From patchwork Fri Feb 20 14:35:25 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jouni Malinen X-Patchwork-Id: 5856431 X-Patchwork-Delegate: johannes@sipsolutions.net Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id CCB229F373 for ; Fri, 20 Feb 2015 14:35:46 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0A65420364 for ; Fri, 20 Feb 2015 14:35:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 39805202DD for ; Fri, 20 Feb 2015 14:35:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754442AbbBTOfm (ORCPT ); Fri, 20 Feb 2015 09:35:42 -0500 Received: from wolverine02.qualcomm.com ([199.106.114.251]:2818 "EHLO wolverine02.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754433AbbBTOfm (ORCPT ); Fri, 20 Feb 2015 09:35:42 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qca.qualcomm.com; i=@qca.qualcomm.com; q=dns/txt; s=qcdkim; t=1424442942; x=1455978942; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version; bh=00Qv3FzsFzsdiS2oJSckMU6Z4vXikU+TZfQSWke6sHE=; b=VO8f+cPF60WLRDKyNW74ydtichp42tLOlSBPCSp7z12AJuc8/ZjKmiqv AqqHpwZrkYq7wuquDqldon82FVD2BFFXynVuKDClOim6vitYZdkHTzJ+J Oo1BmS/jgGEc7UeJHU3rS8mvhkIbVFWEeqF1q+a97GYCZnn7DOuCGBMav M=; X-IronPort-AV: E=McAfee;i="5600,1067,7717"; a="196406932" Received: from ironmsg04-r.qualcomm.com ([172.30.46.18]) by wolverine02.qualcomm.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 20 Feb 2015 06:35:41 -0800 X-IronPort-AV: E=Sophos;i="5.09,614,1418112000"; d="scan'208";a="909236171" Received: from nasanexm01e.na.qualcomm.com ([10.85.0.31]) by Ironmsg04-R.qualcomm.com with ESMTP/TLS/RC4-SHA; 20 Feb 2015 06:35:41 -0800 Received: from jouni.qca.qualcomm.com (10.80.80.8) by NASANEXM01E.na.qualcomm.com (10.85.0.31) with Microsoft SMTP Server (TLS) id 15.0.995.29; Fri, 20 Feb 2015 06:35:39 -0800 From: Jouni Malinen To: Johannes Berg CC: , Jouni Malinen Subject: [PATCH 2/2] mac80211_hwsim: Add ifindex to the example vendor event Date: Fri, 20 Feb 2015 16:35:25 +0200 Message-ID: <1424442925-10778-2-git-send-email-jouni@qca.qualcomm.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1424442925-10778-1-git-send-email-jouni@qca.qualcomm.com> References: <1424442925-10778-1-git-send-email-jouni@qca.qualcomm.com> MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: NASANEXM01C.na.qualcomm.com (10.85.0.83) To NASANEXM01E.na.qualcomm.com (10.85.0.31) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-7.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This provides an example of a vendor event that is associated with a single vif and allows user space tools to process it in the context of that specified vif rather than full wiphy. Signed-off-by: Jouni Malinen --- drivers/net/wireless/mac80211_hwsim.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c index d2bba4c..580eaab 100644 --- a/drivers/net/wireless/mac80211_hwsim.c +++ b/drivers/net/wireless/mac80211_hwsim.c @@ -367,7 +367,7 @@ static int mac80211_hwsim_vendor_cmd_test(struct wiphy *wiphy, * * event_idx = 0 (index in mac80211_hwsim_vendor_commands) */ - skb = cfg80211_vendor_event_alloc(wiphy, 100, 0, GFP_KERNEL); + skb = cfg80211_vendor_event_alloc_ext(wiphy, 100, 0, GFP_KERNEL, wdev); if (skb) { /* skb_put() or nla_put() will fill up data within * NL80211_ATTR_VENDOR_DATA.