Received: by 2002:a05:7412:1e0b:b0:fc:a2b0:25d7 with SMTP id kr11csp27509rdb; Wed, 14 Feb 2024 11:32:23 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCViqhzc7bDVI3vCId8A0Tzd1mB19SASsa6IYRlUG0JxqAWuTEfT7xR87cfQzyeLKV5AI3SUXrGTfsET3kSrol09gXGpxFOqde1IadS2vg== X-Google-Smtp-Source: AGHT+IHaYWring2LfavGb0mjHFVapWF/LxLviGNTmkeMn2/HypAylT4pD5ls833g3j2Zv/W/RQSl X-Received: by 2002:aa7:c24c:0:b0:55f:e574:4ea6 with SMTP id y12-20020aa7c24c000000b0055fe5744ea6mr2878309edo.2.1707939143263; Wed, 14 Feb 2024 11:32:23 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707939143; cv=pass; d=google.com; s=arc-20160816; b=OE9zZkndG0ChDYP3JUyK/3SDtg+YFGvnd4YXPwqBCTGcYCF+PQlzf5/xR4UrpAAt4V 4kxLCoRdyMFDp6DFrO1ivI43uH3xRGhJv+c49Wv46QAerOt5vpgkh9TO8uzbXMUcXZUx c4v60JtavfW6RJbv4vcvSDNmC0UKm+jjdoX7AL8dO/6f9DP6FwT0Xu/rqIGByGfUZS9m Igi9I8/x7gjws4l42rMD3NANV9ghsoeYwBzmejaLrLk6vEL4pz6RwwTf4tkucrB0VzhB kQ2wI3Gs7l5SCUlB2MS599z80Ih2droTgwgrkRc1bm1Ihnr8H1XrIJc+E5FX9mbiylHA Jwuw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=37dRbdjhhta4Nsf+Vm376piXGGlZS7AFxFNDj6iKGNI=; fh=kPlaFHZhiR9CX1cOgpqsz19mffgpt2qJOVd7c6IIKeA=; b=eHrTvbuuyu6zNSdtPc2xlLJnXHsSVDtfyFaksIcneDLycupqkHDuTF9mXd2sv8rx2M 6e9YUWjW3zj52ANc6LUlHlFDF28dAse3mMrxECPGDC997FzVyWv1ncofUOs7BWZ4leRp BL8RpNidjYvF+ykRzDxL2LIXX2qApn3guEOyoZv4+/jWUCnrUnMugv1/8C2sUvJpxC5d 8xyzNBhytFuEFuiDkWz2TA5Bj4aoISiqVIQCoi+Ik5f90VCqWrmRxktVVIOHGNdgdVWQ YCQFNmNAg/SCbJknMz5uXw/5VSFeBhWQog8dsXeAS3VIqBL6UkLzehn8BfOVhedMA6Yq J3hA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=KnSgICex; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-wireless+bounces-3599-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-wireless+bounces-3599-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com X-Forwarded-Encrypted: i=2; AJvYcCW7JBUtinyo+gAzuy0Jp4fAkufN5v+027sEYLUI5dWLQQ/SB1vtQwTeGu/CZK1wi1AbSK5+tsboUUzW01B66mmxFWpENu68zFgObRtlxQ== Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id z16-20020a056402275000b00561cc151d38si3027276edd.2.2024.02.14.11.32.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Feb 2024 11:32:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless+bounces-3599-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=KnSgICex; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-wireless+bounces-3599-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-wireless+bounces-3599-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id A27B51F21AF7 for ; Wed, 14 Feb 2024 19:31:16 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1B3CA13A875; Wed, 14 Feb 2024 19:31:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="KnSgICex" X-Original-To: linux-wireless@vger.kernel.org Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 88AD213A86D for ; Wed, 14 Feb 2024 19:31:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.181 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707939073; cv=none; b=fZN8OB37X8N1bFsQzU2f6ViiaVq97CEfANpdE6dWp/4UJwv8NF6ootT2nNsW5p/bsLcqOj2hiwXkNCeDiYQJUd1688R8REGWRVWKfNdF+CRX98EMuul3VYJh2753KdOD5v/hughACijDwJNM7rJLYwbYR8QflGF6aLRS+xEIQeY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707939073; c=relaxed/simple; bh=j9LOf+7gEkfsUKj60LMRpz/7485ryZOmBx3rLv+z59g=; h=Message-ID:Date:MIME-Version:Subject:To:References:From: In-Reply-To:Content-Type; b=Sj5UJNlxbFhcTC1DJ+RxS6egDqCgHA40Tm9i9iDVSfMS9nLTTrWcRmRa4dq3WMcrKW0ysbdIsnPZe55ZM3LhVF+Y7+sZPOW35LQT/M4ztEzvR7E5Nl123xZeTSznr1t+LnRIHk69U15+ax2hm+mbjMSUFQl0W8HfTyXEbtT90HE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=KnSgICex; arc=none smtp.client-ip=209.85.214.181 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pl1-f181.google.com with SMTP id d9443c01a7336-1d9b2400910so1175055ad.0 for ; Wed, 14 Feb 2024 11:31:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1707939071; x=1708543871; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=37dRbdjhhta4Nsf+Vm376piXGGlZS7AFxFNDj6iKGNI=; b=KnSgICex7I4BfhHFvaw6vBVlI5Dt+eA4JwXgAiOJCTdUa95Ux6qn+a4E+RIq0VZDPL 1ZN6BATmK3KzPRfOl/D/DKbdrtONfxNktSX8k/oOZpQgt9E5gYRxKNPpnb0YRw1B0bi8 cvBS71g44yKzl4DedUS3zwCA2eWXWLyvEPJVIJrmGgRxO4rNqFKT9mxn3YLw927aauWX +tG2abUow+9emKmDlNU2W/vlucnz2EcgeJBdDJJSrS/bm1wRgQX7wcht5CEhVy7XpIfJ EO9SgC1NN/cvJBIutaulqybKx7xK11+SlpR1uc0uKtbQovnzgfOL+fu0b6iCa39YDJY0 JI/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707939071; x=1708543871; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=37dRbdjhhta4Nsf+Vm376piXGGlZS7AFxFNDj6iKGNI=; b=tWuz+p97m3J3CpYeLQDXeU7vP16x/p/YWEWvR4JuIwYMr0f92/cPmAUtnsxcAldYrD qxrfA3OmmShnREdJncZ4tIuUHgeZOz6LnV/p2WLL/Tn3AoOfxh05LY4mSmy3RZg7yuyS huccUPK8NnRsRulutMY31heB6NVYPD9BVyrq+tkpeeUCVdKbGgQYvuQc7ExzioZ1WI6u RXAwF5u3xJHtp/JruWmxhy361SKlvsSSOVJsITJTG27ed74knRZq7n4DFMMY2qMz3q1g Zhb7pTCnKtRnl6xXRLZWQuwAn5km1lm1CFh/Bn6+KjlJbcFVd9bZgqxalzIUu4cx8LoQ +yhA== X-Forwarded-Encrypted: i=1; AJvYcCWyg1yXw32eofMnzO1C05n2hL8AY6wshETrngaCzMWXnAtoGhiPY4BGLXPaKqyCE96LUhYNjVYjSOZzeeZRyA7NqDGDImfnGlrwUu2yb50= X-Gm-Message-State: AOJu0Yxvp2A+uVPLffIyVf9WomamebHk4k/R5AO3p0m5NFOpBYzlFtra r4xqwIA3cFmjZbQlvAe70ZmKGvEFJCl6hccPiMopA8DhkXAHdVqI++3wkdV43Yc= X-Received: by 2002:a17:902:ec8b:b0:1db:28c0:3ec4 with SMTP id x11-20020a170902ec8b00b001db28c03ec4mr4394701plg.7.1707939070426; Wed, 14 Feb 2024 11:31:10 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCVFpI31ibNdZ2i5ghZyc4oJIDzQpVpS1Kr+hfq3GeUI7+33xTQG2Ta6Y4wc5yjRVGw8wTqjhbHrd8N8BMaDjoeuCpZ/eDxPJP2dk5nAKxHvBwP233djLrvUQkkyXKctEqHkUA== Received: from [10.102.4.159] ([208.195.13.130]) by smtp.gmail.com with ESMTPSA id k10-20020a170902760a00b001db616fa11dsm1328588pll.238.2024.02.14.11.31.09 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 14 Feb 2024 11:31:10 -0800 (PST) Message-ID: <4eda39b4-3b16-4f01-a241-50409d34ce33@gmail.com> Date: Wed, 14 Feb 2024 11:31:07 -0800 Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: brcmfmac AP mode Content-Language: en-US To: Johannes Berg , KeithG , linux-wireless@vger.kernel.org References: <311c594bddde32bacd45acbfa6f40fa7670e51c6.camel@sipsolutions.net> From: James Prestwood In-Reply-To: <311c594bddde32bacd45acbfa6f40fa7670e51c6.camel@sipsolutions.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Hi Johannes, On 2/14/24 6:34 AM, Johannes Berg wrote: > I have no experience with brcmfmac, but ... > >> I was helping Keith out here and wanted to provide a bit more >> information. I found there were a few differences between IWD and >> wpa_supplicant related to scanning which may aid in figuring out why >> brcmfmac is behaving this way: >> >>  - IWD scans using the wdev ID where wpa_supplicant uses ifindex. Not >> sure if this has anything to do with the difference behavior. > This is not even visible to the driver, it's entirely resolved in > nl80211, so no impact here. > >>  - Passive scans (which IWD prefers) seem to exacerbate the behavior. >> Simple testing using "wpa_cli scan" showed wpa_supplicant was only using >> active scans. I also tested with iw and saw repeatable disconnects when >> passive scanning. Disconnects while using active scans (using iw) were >> much less frequent. > This makes sense, especially if it's __ap rather than __p2p_go type, > since it *has* to be off the channel for some time -- especially for > passive scans it has to be off-channel for more than a typical interval > to even do scanning correctly. > >>  - Scanning with IWD, wpa_supplicant, or iw, passive or active, always >> resulted in beacon loss for clients connected to the AP. This was 100% >> guaranteed. The clients just could recover when active scans were used >> over passive. But either way this does not seem like normal behavior, >> the AP interface should still be beaconing on its active channel during >> a scan right? > That's "normal" in the sense that you have to be off the channel for > scanning, and if you're off the channel you can't transmit beacons on > it? > > For P2P GO rather than AP it should publish NoA descriptors in the > beacon to let clients know there won't be a beacon. > > Now it's perhaps possible to time - especially active - scanning so you > can still beacon somewhat and inbetween, but I suppose the firmware > doesn't do that here. > > In fact even outside of the beaconing, APs aren't expected to be off- > channel, clients can send data to them after all. Again P2P GO solves > that with NoA, but the spec itself has no good way to solve this and I'm > not even sure it would even want to. > > In any case, you could argue that starting AP and client and then > scanning is pretty much _asking_ for trouble. Yes I suspected as much. It seems some firmware is just better at this than others. There is one use case there that I believe Kieth is targeting and that is new device onboarding which I'm sure your familiar with as just about every "smart" device uses it. Where the new devices starts an AP and your phone/App connects and provides credentials to the "real" network. The tricky part is having the new device scan for available networks while it has a client connected. Some drivers support AP scanning which maybe is really what should be used for this? Maybe that is optimized to actually work. I guess I'll also ask, what _is_ the target use case for STA + AP interfaces running concurrently? If scanning is unreliable then connecting would also be most likely? so what can you actually do here? >> If this isn't possible or can't be done reliably then >> should the interface combinations be changed to disallow concurrent sta >> + AP mode interfaces? > Maybe it could restrict it to P2P GO instead of AP? But then people will > anyway just notice that they can use P2P GO and connect arbitrary > clients to it (not just P2P client), then those clients won't honour the > NoA because they're not P2P, and then you're back to the exact same > situation... > johannes