From patchwork Fri Mar 18 12:46:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Berg X-Patchwork-Id: 552987 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2A0FEC433EF for ; Fri, 18 Mar 2022 12:47:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236295AbiCRMsW (ORCPT ); Fri, 18 Mar 2022 08:48:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56674 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230247AbiCRMsW (ORCPT ); Fri, 18 Mar 2022 08:48:22 -0400 Received: from sipsolutions.net (s3.sipsolutions.net [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1816F2E415F for ; Fri, 18 Mar 2022 05:47:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sipsolutions.net; s=mail; h=Content-Transfer-Encoding:MIME-Version: Message-Id:Date:Subject:Cc:To:From:Content-Type:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-To:Resent-Cc: Resent-Message-ID:In-Reply-To:References; bh=er26jgQqqWIkeiYung6sP9Xm4srJZgmxOHOKKqOmBtg=; t=1647607623; x=1648817223; b=okHx03aD5yBx/a+i512FVpA/dQ0GvQPyc12CCJbILaYr61f1UPbGj/VD5XvRQfOD/94gWZtHIFm /kI8KksO0akXK0BeM/sRVun6sJl+jbyWPKtjQp5lWXJpYNwOeP+z5vv9zyHfZU+Hphstz6n3D6Q8L /rAYdWIU1xeYWQtda8JTjNlMr9z7e2Y/IkI7DqP+peYbGZaCk1QOBp2dS+9DjAIOjnUCOwJvU99gd xSh60bfVIzd4t3zEciQ9yDdv/LKT2d632p6HQn3e2Ef5whUC2WPbKqNnqloFOun/EuH/q8zdKm9Sm ENVmB1/pvBhYkmLgybewlr1WQX7M+Hxet2Pw==; Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.95) (envelope-from ) id 1nVC0S-00ErVU-Mx; Fri, 18 Mar 2022 13:47:00 +0100 From: Johannes Berg To: linux-wireless@vger.kernel.org Cc: Johannes Berg Subject: [PATCH] nl80211: show SSID for P2P_GO interfaces Date: Fri, 18 Mar 2022 13:46:57 +0100 Message-Id: <20220318134656.14354ae223f0.Ia25e85a512281b92e1645d4160766a4b1a471597@changeid> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Johannes Berg There's no real reason not to send the SSID to userspace when it requests information about P2P_GO, it is, in that respect, exactly the same as AP interfaces. Fix that. Fixes: 44905265bc15 ("nl80211: don't expose wdev->ssid for most interfaces") Signed-off-by: Johannes Berg --- net/wireless/nl80211.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index ee1c2b6b6971..711061cd02d1 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -3709,6 +3709,7 @@ static int nl80211_send_iface(struct sk_buff *msg, u32 portid, u32 seq, int flag wdev_lock(wdev); switch (wdev->iftype) { case NL80211_IFTYPE_AP: + case NL80211_IFTYPE_P2P_GO: if (wdev->ssid_len && nla_put(msg, NL80211_ATTR_SSID, wdev->ssid_len, wdev->ssid)) goto nla_put_failure_locked;