Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp14969756rwb; Mon, 28 Nov 2022 06:46:30 -0800 (PST) X-Google-Smtp-Source: AA0mqf6+EE/DsgO7gVPAMowtH4sq8f4Y5t3KzHjIw4BRCSc+43y0VF1CwaZSdVapooMTltUubJ71 X-Received: by 2002:a05:6402:240b:b0:469:9667:704c with SMTP id t11-20020a056402240b00b004699667704cmr34913661eda.318.1669646790283; Mon, 28 Nov 2022 06:46:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669646790; cv=none; d=google.com; s=arc-20160816; b=Sow90L+6Qej5wW3zvfhkwpQIf2oM2bEJZyo+mtSXOaWjvCjDYWIGqKR0qAELSiVmZD /U0KHcFA852NtED9IRfRryqZAMkYV/hOdTwUED7RgcI1IOnIKvE0qAGz995qv4vxzx/V DorvwqJZ1Z+iqUqgkbVyfG4pUgy65j0ECBJYPD2l9xOedPJ74xH8dvE7uy4rg1/C11/u EBhU8qOP1wzwgckYlULQstsjRsZXlRRD5s99A71JfAWSDKm2JoFYtDjRP/JkwG08n6At 3txaAUNOqQxZAJ82uud3sJMMP8Ogt6ifRu8fdzwbipdbWTHzHBNVq2kmfDY+kP4wmZPz 9wtw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=rxl7YrMvA0F9XMtLgK6+hpZFxRBfqgt+eTWoNu6iRo8=; b=aKDOzS/jXgSv5ql6U+AQRTkxqbm7/gBYi5Wl7I9aEtovMrnHQcmTz1A20bLu+Xkbox vfxwgbzgLtViWKhvPiGVirJhGpxilG9haAg8lGhFrsquI6A9XtyaD/6uy/FuN+IvfC2I qgizoJUiDqmpSf4QTa9vGA7KFaMANkpbkg/gFXYFYrRwvL8UeNJe6ghv7NrZtXA2BbSC czrGW6fHv0hBgDxxSYWEvFznzQzjNhU0WmZzktnWHqjFZob1vcCsa3W0feSul8umnWLC tKZDzUtlJV6mcZtUr+hTDj62WHvvY9VXwvp/pAjyagG7dOmbahfFXvOlXt2urHZkwIJm UldQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NF3MUsLO; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gn15-20020a1709070d0f00b007b911ee70cbsi10673132ejc.796.2022.11.28.06.46.10; Mon, 28 Nov 2022 06:46:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NF3MUsLO; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232560AbiK1Okh (ORCPT + 67 others); Mon, 28 Nov 2022 09:40:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33036 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232590AbiK1Okf (ORCPT ); Mon, 28 Nov 2022 09:40:35 -0500 Received: from mail-lj1-x229.google.com (mail-lj1-x229.google.com [IPv6:2a00:1450:4864:20::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D9CB2222A3 for ; Mon, 28 Nov 2022 06:40:32 -0800 (PST) Received: by mail-lj1-x229.google.com with SMTP id d3so13402517ljl.1 for ; Mon, 28 Nov 2022 06:40:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=rxl7YrMvA0F9XMtLgK6+hpZFxRBfqgt+eTWoNu6iRo8=; b=NF3MUsLO+B6UNx8ExIv7IuRKSaM0xTVI3KgPrPUJQrbRqxLFD/3YZjeE6FP35wcoCP YHsCeFThsTdhZLMIOY8ClukFneGUA70nkSiNjcICbs9vVrXf0o6apXuVxh3AVE2wA55h 57XgK4oF1DosZhWCtO12W0hd3mWrhY+jDRm2uvzJSa3FHPF95eB/JkKZ6iOVUIhBpvVM RFsMt4uenAXgLsm72nL8xuWoa9A91tJuHUJ4ioOTGcNZrcLD1YieyWMeWy7Isg+sbjPs /d4VB5tSa6mfjZfOzTeWIV85dBsGVY7Cmd8cZWckqQFZjW2gofi2ESsrLMFt6LKmZU8m tAew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=rxl7YrMvA0F9XMtLgK6+hpZFxRBfqgt+eTWoNu6iRo8=; b=xSLqu9aaT0S5sfStZNtFkyhs26TYxVUD4d/SHSaJz7wuefSyjuSIrOWqY1i2VPJYGe KPx4stqq1oTumEP7YQH8luqR/CQg1DFTZTGEGOCaSzUh4pKcdrOJLJpA6IAMjeTuQ1Hp nH1VynQtAXDNGmn9B9XMrFTM45X/6Ty+hpyNKYxD8lpFzgV564nCUcxkTa8dzzgglThe NVvvamfHJ9KYE+rGzPemLvDPDIrgQ0KfnGpe0N3z2W2U0AnI4ZGP1D/HNaQzhWFgNe7j 5GhfWKnKWXt+i32XqASNpD5wtfAw6nytOwZtxM0xprn49Cik6LkoBsrH8LGRIWnLe2SS fmMg== X-Gm-Message-State: ANoB5pnwQ1OtCo4ArlyMF5unLJ+c6wsvssFqeNzP4mKh/jjy/zwsNsWE 1PMgJtIKJ1LCOXJcj2fSeqiRqw== X-Received: by 2002:a2e:9611:0:b0:276:b134:b04c with SMTP id v17-20020a2e9611000000b00276b134b04cmr11149799ljh.492.1669646431213; Mon, 28 Nov 2022 06:40:31 -0800 (PST) Received: from [192.168.1.101] (95.49.125.236.neoplus.adsl.tpnet.pl. [95.49.125.236]) by smtp.gmail.com with ESMTPSA id q21-20020a05651232b500b004ac980a1ba1sm1754473lfe.24.2022.11.28.06.40.28 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 28 Nov 2022 06:40:30 -0800 (PST) Message-ID: <28991d2d-d917-af47-4f5f-4e8183569bb1@linaro.org> Date: Mon, 28 Nov 2022 15:40:27 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.5.0 Subject: Re: [PATCH v2] brcmfmac: Add support for BCM43596 PCIe Wi-Fi To: Linus Walleij , Kalle Valo Cc: =?UTF-8?Q?Alvin_=c5=a0ipraga?= , Hector Martin , "~postmarketos/upstreaming@lists.sr.ht" <~postmarketos/upstreaming@lists.sr.ht>, "martin.botka@somainline.org" , "angelogioacchino.delregno@somainline.org" , "marijn.suijten@somainline.org" , "jamipkettunen@somainline.org" , Arend van Spriel , Franky Lin , Hante Meuleman , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Marek Vasut , "Zhao, Jiaqing" , "Russell King (Oracle)" , Soon Tak Lee , "linux-wireless@vger.kernel.org" , "brcm80211-dev-list.pdl@broadcom.com" , "SHA-cyfmac-dev-list@infineon.com" , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Krzysztof Kozlowski , Rob Herring References: <20220921001630.56765-1-konrad.dybcio@somainline.org> <83b90478-3974-28e6-cf13-35fc4f62e0db@marcan.st> <13b8c67c-399c-d1a6-4929-61aea27aa57d@somainline.org> <0e65a8b2-0827-af1e-602c-76d9450e3d11@marcan.st> <7fd077c5-83f8-02e2-03c1-900a47f05dc1@somainline.org> <20220922133056.eo26da4npkg6bpf2@bang-olufsen.dk> <87sfke32pc.fsf@kernel.org> <4592f87a-bb61-1c28-13f0-d041a6e7d3bf@linaro.org> <87fse76yig.fsf@kernel.org> <87bkov6x1q.fsf@kernel.org> Content-Language: en-US From: Konrad Dybcio In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, 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 lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On 26.11.2022 22:45, Linus Walleij wrote: > On Fri, Nov 25, 2022 at 1:25 PM Kalle Valo wrote: >> Konrad Dybcio writes: >> >>> On 25.11.2022 12:53, Kalle Valo wrote: >>>> Konrad Dybcio writes: >>>> >>>>> On 21.11.2022 14:56, Linus Walleij wrote: >>>>>> On Fri, Nov 18, 2022 at 5:47 PM Konrad Dybcio wrote: >>>>>> >>>>>>> I can think of a couple of hacky ways to force use of 43596 fw, but I >>>>>>> don't think any would be really upstreamable.. >>>>>> >>>>>> If it is only known to affect the Sony Xperias mentioned then >>>>>> a thing such as: >>>>>> >>>>>> if (of_machine_is_compatible("sony,xyz") || >>>>>> of_machine_is_compatible("sony,zzz")... ) { >>>>>> // Enforce FW version >>>>>> } >>>>>> >>>>>> would be completely acceptable in my book. It hammers the >>>>>> problem from the top instead of trying to figure out itsy witsy >>>>>> details about firmware revisions. >>>>>> >>>>>> Yours, >>>>>> Linus Walleij >>>>> >>>>> Actually, I think I came up with a better approach by pulling a page >>>>> out of Asahi folks' book - please take a look and tell me what you >>>>> think about this: >>>>> >>>>> [1] >>>>> https://github.com/SoMainline/linux/commit/4b6fccc995cd79109b0dae4e4ab2e48db97695e7 >>>>> [2] >>>>> https://github.com/SoMainline/linux/commit/e3ea1dc739634f734104f37fdbed046873921af7 > > Something in this direction works too. > > The upside is that it tells all operating systems how to deal > with the firmware for this hardware. > >>>> Instead of a directory path ("brcm/brcmfmac43596-pcie") why not provide >>>> just the chipset name ("brcmfmac43596-pcie")? IMHO it's unnecessary to >>>> have directory names in Device Tree. >>> >>> I think it's common practice to include a full $FIRMWARE_DIR-relative >>> path when specifying firmware in DT, though here I left out the board >>> name bit as that's assigned dynamically anyway. That said, if you don't >>> like it, I can change it. >> >> It's just that I have understood that Device Tree is supposed to >> describe hardware and to me a firmware directory "brcm/" is a software >> property, not a hardware property. But this is really for the Device >> Tree maintainers to decide, they know this best :) > > I would personally just minimize the amount of information > put into the device tree to be exactly what is needed to find > the right firmware. > > brcm,firmware-compatible = "43596"; > > since the code already knows how to conjure the rest of the string. > > But check with Rob/Krzysztof. > > Yours, > Linus Walleij Krzysztof, Rob [added to CC] - can I have your opinions? Konrad