Received: by 2002:a05:7412:251c:b0:e2:908c:2ebd with SMTP id w28csp1159512rda; Mon, 23 Oct 2023 04:42:21 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEbstTAnZPqxZRV3ot/9vCO6xrdzzAOD983LS2WOkRLaKShoZ3g4qpozRvDjkSVYL9Z6YuH X-Received: by 2002:a05:6a20:6715:b0:17a:49db:4c0a with SMTP id q21-20020a056a20671500b0017a49db4c0amr5301312pzh.49.1698061341354; Mon, 23 Oct 2023 04:42:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698061341; cv=none; d=google.com; s=arc-20160816; b=A5FZ264YT76iyEDo+1WFmOIAG6Ll13ppATmH6153w5l+Dz+C2C+JGm2sXyASrqEMg6 Bu22LoOmoxvP6EKo8qvvK96vieClIsX2UBe9FTaN78kE1vWfv5JYmWxPq+cyE3WsivHp 3Yy2bl3AWnS2rnhef7xe3hWwBmagScSV5gRwWQfo7ndvdpUkzlCVeBIpajiteD2fxNl3 xUzcxEeO62+BzT/FVbDX1n4vNzPY6DOFCQ2ZNh1iNhZRKXPm/EzvSYiohPmUPKMuTGGb CmtNULktARZjQDtK45mkFLl1XtoSxY2c1edPT1YGHl1RgGpog8/rpaJwUQy0pvsFO6hI 6JqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=pWng4wsdvhQ3yYhP90X+fEaax78WLUNDXvIyDdQRoDY=; fh=qJotNKxq/9J27AySKlDZCVKXUIjdeWpUF8dOMvUIxYc=; b=dOdcsf/+qCk+vFxGpVfQTNVTmXEj0gOlrecfgN0acW3fqgV2AoToJ/nzyXSGzV15kv jeXDk/tQPqK6tmHz9bw5oCdq8SJdQONzJgGHTlWR+GTT5Fhxv4h+g56US7LbITV4+1Wo rPED3M2YYmsaLyqMsHV0hS3UGEZAqL9807Sd5o+ybJ2v58OmFQp+qbOzSWjwA0z8xG7O cDeNnVW26jMvIbNxFPLE0u85t4Ikg5IlLWmhu8rmcgwwwivnzSQvItAy/rQJhPUymN2M e+5rwsfuvGrF6M1xp6JfDsnvqBe3uy77By3s+YaRANFVsmjW/Ugg77jg4ivEo4BumUST ETUQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@dberlin.org header.s=google header.b=EcaeOmUh; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id b9-20020a170903228900b001c61073b06bsi3366986plh.427.2023.10.23.04.42.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Oct 2023 04:42:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; dkim=pass header.i=@dberlin.org header.s=google header.b=EcaeOmUh; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 79E8B8095414; Mon, 23 Oct 2023 04:42:17 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234301AbjJWLmN (ORCPT + 52 others); Mon, 23 Oct 2023 07:42:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52724 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234297AbjJWLmK (ORCPT ); Mon, 23 Oct 2023 07:42:10 -0400 Received: from mail-lj1-x232.google.com (mail-lj1-x232.google.com [IPv6:2a00:1450:4864:20::232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2D22410D3 for ; Mon, 23 Oct 2023 04:41:47 -0700 (PDT) Received: by mail-lj1-x232.google.com with SMTP id 38308e7fff4ca-2c509d5ab43so48494051fa.0 for ; Mon, 23 Oct 2023 04:41:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dberlin.org; s=google; t=1698061294; x=1698666094; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=pWng4wsdvhQ3yYhP90X+fEaax78WLUNDXvIyDdQRoDY=; b=EcaeOmUhQvXhvQ2qETBotdErcvU9+TVjCan2V/BKQUUEuInXUmyoVnwHjgbWh8o/1v o36NWe0m74sDerBTPxNfXGg1gnABiKtAkaETn/v5DeOtnZuQvdRlVFh/0cZfQDDd/H8o 1PinCUJz9LLzhNi9R/aqbM3CFKuG+MPLQAG6gTdAk39XS0Qa5CGGS3ISSD5LR/mwcyPj y4NegjKH9wgz8uUmSEmSPVizzzJb5C6yUdIMLCCQYlyQMIpKcgZm79IV9ofcfNrhD2vG OVAIOFu5zksLfAQsVH8akRpqrHo6jNduS4mWhQuF1/0+p/JDnFUgBFr/0HfZTwyrtatV QCcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698061294; x=1698666094; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=pWng4wsdvhQ3yYhP90X+fEaax78WLUNDXvIyDdQRoDY=; b=NfIYDQv5zkW9WEY6iaFTmHAB0oUMgsn2boQ4bnIIBKbVP2cXPvIjtQ4UQUb+73lD3L 3NKkdcspjvdWKiEnmSuvaK6I8xJEbMrvg8g8QVNxurFVkT+/zVqo6pqWl89GuG0+zmY1 9PJdxqWWLqA+Am20hIi5wY4o8tCA9rG1JCkJ8BGfTzwkiNyuQYMFfl8rjNI0cmP5Z2ut gO/8uJRAEj1oO8Oon2NlEGcVqJzWqFNLqMIQSzAjQ3f9uty3X5CTWJ+GwoP4simQtGCA E4WZiblPDrWuK7fYyhsIGtoXBZreGLpDzZzXqMWBPUzlRc4iPPFLg8FpsusYw8Q2Cg4v JTTQ== X-Gm-Message-State: AOJu0YyzKRAcTaFtwX8EHUDsMtpqu3f62FOWR9GUusaCHUvQrY4iuVMF KoorNN0OQWzibgGT4vY8BIbrqGySP7emOfWfUWXffvI318MkgTdpdGTIfA== X-Received: by 2002:a2e:86c4:0:b0:2c5:25f3:8e1c with SMTP id n4-20020a2e86c4000000b002c525f38e1cmr5732134ljj.21.1698061293768; Mon, 23 Oct 2023 04:41:33 -0700 (PDT) MIME-Version: 1.0 References: <52c993fd93e13ac015be935a5284294c9a74ea8e.1697650207.git.dberlin@dberlin.org> In-Reply-To: From: Daniel Berlin Date: Mon, 23 Oct 2023 07:41:22 -0400 Message-ID: Subject: Re: [PATCH 2/5] [brcmfmac] Add support for 6G bands To: Arend van Spriel Cc: Arend van Spriel , Franky Lin , Hante Meuleman , linux-wireless@vger.kernel.org, brcm80211-dev-list.pdl@broadcom.com, SHA-cyfmac-dev-list@infineon.com, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Mon, 23 Oct 2023 04:42:17 -0700 (PDT) On Fri, Oct 20, 2023 at 12:35=E2=80=AFPM Daniel Berlin wrote: > > > > > > - brcmf_dbg(INFO, "nmode=3D%d, vhtmode=3D%d, bw_cap=3D(%d, %d)\n"= , > > > + brcmf_dbg(INFO, > > > + "nmode=3D%d, vhtmode=3D%d, bw_cap=3D(%d, %d, %d), he_= cap=3D(%d, %d)\n", > > > nmode, vhtmode, bw_cap[NL80211_BAND_2GHZ], > > > - bw_cap[NL80211_BAND_5GHZ]); > > > + bw_cap[NL80211_BAND_5GHZ], bw_cap[NL80211_BAND_6GHZ], > > > + he_cap[0], he_cap[1]); > > > > So are these he mac and phy capabilities? ... > > No, unfortunately, it's either 1 or 0 on these chips, and all chips i tes= ted. > This is the hardware capability iovar. > > In the debug firmware i have access to (not apple's), i do see a > command that looks like it may give the he cap, but i can't find how > it would ever be triggered. > (The iovar code for the iovar above is either always just return 0 or ret= urn 1) > There are no obvious iovars that relate, and the absolute latest > bcmdhd hardcodes the he caps, as do infineon's latest ifx code. > :( > I'l hack around see if i can get the caps out of it. > > I'll double check other ones. So, I reached a conclusion on this piece. This is really an xtlv with subcommands that everyone (including me) is wrongly treating as a non-xtlv. The above is really showing you the enable value. There is also hardware cap value (which is 0/1 as well). In the 4398/4390 firmware, a "defcap" subcommand was added to the firmware which can retrieve the default HE capabilities bytes for the mac and phy and be used to fill them in. However, it is unsupported in the firmware for earlier chips, including these chips (or at least, any firmware i've found for it, apple's or not) As such, at least for these, STA/AP caps will have to be hardcoded. I have updated the code to include the subcommands that exist here, and properly use an xtlv command to retrieve this (it's really a uint8 value).