From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 399F1C02198 for ; Fri, 14 Feb 2025 07:53:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: Content-Transfer-Encoding:Content-Type:In-Reply-To:From:References:To:Subject :MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=iTbQLAgpjANr9FF26MbTNiTflsGKq1/SNVTlqX2eGXE=; b=hwlSFe6xGTDAL9 vctTiUSuTRqvOdahg+GADcJdWJlQorddhL69Qajcjqfc81a6gD4nya070qfibRGkFitzyBe5WJIGD 45NgMgqss7RkYfVXPTaBXxznV0VXjVYQsW7Dcj9vsFxXF0W0zMuvxAnA2g1vlVnz9kzB4QgepB8Oc 4Cu5Y0H1qg80mq55PKEpCht+Ln9s5VNKtxpOSNKbMu7NyF5Lr18X+10j6W9Tk2EjzqjeIQ+Y440/n wi0UykIypJzlOfmhqUHu/Mcb47JWNzNArqLN/nfQ68qI44nh74kezBDXhqdSjdCfT+ObGOaloliCZ AiR12baxyAFeDCw1vQew==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tiqVk-0000000E16e-0KFr; Fri, 14 Feb 2025 07:53:20 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tiqQ9-0000000E0JO-0leD for linux-arm-kernel@lists.infradead.org; Fri, 14 Feb 2025 07:47:34 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id A85AA5C58E7; Fri, 14 Feb 2025 07:46:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F25D4C4CED1; Fri, 14 Feb 2025 07:47:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1739519251; bh=EYmxegMfAeOmf9WfPU0zoAyXDFaCcyLf0boT+xp9GzI=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=N07Gl9aocIzC5I04HiGdP03Mws1B5tWvZQNa4Hft8/45j5cB4ALd3qcnGufrUYktk artWM/ChcL+6uQrP21lToDMsM7U1LBJdCHQDBr9IuyXbqbPSdYChWrUSgUymQrFRJj mhC2CMfArzPXVjYnx5OiOwK4erS6A1QqkT721cz/08yJPSkfk5T1BDKnwzUwRc0AKg 91vpDWQYaxb27HZ7N0Aruobkc1i34nyEeLXFqbdq7m0mozQEscMPbWTAoEU5rSzc7/ qOfnKb4GiHGzzOWzBIaXRtHfJldYj6ZKq7m0utxtmr2F69AvYxXKjV9rEspNzXtPTQ th/UIPJNgrw8A== Message-ID: <826ded05-6ea8-420c-8bd9-97dcf9b18ccc@kernel.org> Date: Fri, 14 Feb 2025 08:47:23 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 01/12] dt-bindings: bluetooth: describe wilc 3000 bluetooth chip To: =?UTF-8?Q?Alexis_Lothor=C3=A9?= References: <20250212-wilc3000_bt-v1-0-9609b784874e@bootlin.com> <20250212-wilc3000_bt-v1-1-9609b784874e@bootlin.com> <20250213-chamois-of-unexpected-glory-dd3eab@krzk-bin> <99247019-bb41-4fd9-bc0c-d31e5688533b@bootlin.com> From: Krzysztof Kozlowski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Tg2hYnLFJI4Xjg+AX1hHFVKmvl3VBHIsBv0oDcsQWXqY+NaFahT0lRPjYtrTa1v3tem/ JoFzZ4B0p27K+qQCF2R96hVvuEyjzBmdq2esyE6zIqftdo4MOJho8uctOiWbwNNq2U9pPWmu 4vXVFBYIGmpyNPYzRm0QPwARAQABwsF8BBgBCgAmAhsMFiEEm9B+DgxR+NWWd7dUG5NDfTtB YpsFAmA872oFCRRflLYACgkQG5NDfTtBYpvScw/9GrqBrVLuJoJ52qBBKUBDo4E+5fU1bjt0 Gv0nh/hNJuecuRY6aemU6HOPNc2t8QHMSvwbSF+Vp9ZkOvrM36yUOufctoqON+wXrliEY0J4 ksR89ZILRRAold9Mh0YDqEJc1HmuxYLJ7lnbLYH1oui8bLbMBM8S2Uo9RKqV2GROLi44enVt vdrDvo+CxKj2K+d4cleCNiz5qbTxPUW/cgkwG0lJc4I4sso7l4XMDKn95c7JtNsuzqKvhEVS oic5by3fbUnuI0cemeizF4QdtX2uQxrP7RwHFBd+YUia7zCcz0//rv6FZmAxWZGy5arNl6Vm lQqNo7/Poh8WWfRS+xegBxc6hBXahpyUKphAKYkah+m+I0QToCfnGKnPqyYIMDEHCS/RfqA5 t8F+O56+oyLBAeWX7XcmyM6TGeVfb+OZVMJnZzK0s2VYAuI0Rl87FBFYgULdgqKV7R7WHzwD uZwJCLykjad45hsWcOGk3OcaAGQS6NDlfhM6O9aYNwGL6tGt/6BkRikNOs7VDEa4/HlbaSJo 7FgndGw1kWmkeL6oQh7wBvYll2buKod4qYntmNKEicoHGU+x91Gcan8mCoqhJkbqrL7+nXG2 5Q/GS5M9RFWS+nYyJh+c3OcfKqVcZQNANItt7+ULzdNJuhvTRRdC3g9hmCEuNSr+CLMdnRBY fv0= In-Reply-To: <99247019-bb41-4fd9-bc0c-d31e5688533b@bootlin.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250213_234733_338338_15CA0417 X-CRM114-Status: GOOD ( 36.54 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Alexandre Belloni , Eric Dumazet , Thomas Petazzoni , Claudiu Beznea , Marek Vasut , Rob Herring , Ajay Singh , Jakub Kicinski , Paolo Abeni , Kalle Valo , devicetree@vger.kernel.org, Conor Dooley , Marcel Holtmann , Luiz Augusto von Dentz , linux-arm-kernel@lists.infradead.org, netdev@vger.kernel.org, linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, linux-bluetooth@vger.kernel.org, Simon Horman , Krzysztof Kozlowski , "David S. Miller" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 13/02/2025 16:25, Alexis Lothoré wrote: > Hi Krzysztof, > > On 2/13/25 10:25, Krzysztof Kozlowski wrote: >>> + wlan: >>> + $ref: /schemas/types.yaml#/definitions/phandle >>> + description: >>> + Phandle to the wlan part of the combo chip >> >> No resources here and judging by the driver everything is part of wifi. >> Either you wrote it to match driver or indeed hardware is like that. In >> the first case, why this cannot be part of WiFi with phandle to serial >> bus? In the second case, this needs to be proper hardware description > > First, I'd like to reclarify what the chip exactly is, to make sure that we are > talking about the same thing. The wilc3000 ([1]) is a single physical device > packaging two different discrete modules inside (one for 802.11, one for > bluetooth). The WLAN part has its own binding integrated in upstream kernel > ([2]) and is based on a similar chip in the same family (wilc1000, which only > have 802.11, and so only SPI/SDIO, no UART). > > Now that it is said, no, I did not write this binding only aiming to match the > new driver. I tried to base this description on how similar WLAN/BT combo chips > are usually described (based on those which have existing bindings), and they > seem to describe distinctly the two internal parts of those chips as well. For Yes, because BT part is isolated enough that you datasheet tells which resources belong to it and DT describes these resources. You do not have any resources here. > those who use HCI commands over uart for the bluetooth part, they expose a > dedicated child node of a serial controller (distinct from the wlan part, > described as another node on PCI/SDIO/SPI/etc). The hardware architecture for > wilc3000 is similar to those, so since the serial bus is the primary interface > to operate the bluetooth part inside the chip, doesn't it makes sense to have it > under a serial controller node (and then to refer to wlan for the additional > operations needed on sdio/spi), than the other way around ? There is little benefit in describing one device in two places. This even lead to probe ordering issues and power sequencing problems, for example being explicitly addressed by recent power sequencing work from Bartosz by creating *third* node... You have no resources here, so I cannot even imagine inventing something in that third (PMU) node. But anyway in case of WCN devices, the reason of power sequencing patches, BT and WiFi are separate, can be enabled separately, can be even shipped one without another (I think). Not your case. Your BT needs WiFi to load firmware. > > About the lack of other resources in the new node: there are indeed additional > resources that affect bluetooth, but I am not sure how it should be handled: You sent us then incomplete hardware description. So you got review like this. > there are for example a reset input and a chip enable input exposed by this > chip, which in fact do not only affect the WLAN part but the two parts inside > the chip. But those are currently described and handled by the WLAN part. I So everything is already defined in WiFi part and this node is not really necessary. > guess that an improvement regarding this point could then be to move those out > of the wlan binding, and find a way to describe it as shared resources between > those two parts of the chip, but how should it be handled ? Is it ok to remove > those from an existing binding (and if so, where to put those ? It is not > bluetooth specific neither) ? Is the issue rather about current WILC3000 binding > kind of mixing overall chip description and internal wlan part description ? Datasheet shows this as one device, not two, not three. Reset and chip enable, based on datasheet, are not specific to BT. They reset/enable entire chip, I assume, so it is even better proof that your HW description is not correct. How this device is supposed to work if you do not enable WiFi - do not deassert reset from Wifi driver? BT will stay in reset. Really, and that's correct hardware representation? This is exactly the power sequencing problem one more time and you keep asking exactly the same questions and repeating exactly the same mistakes. This is incomplete and, IMO, incorrect hardware description. Read all previous discussions, read/listen/watch the talks about power sequencing (there were two on LPCs - one with Abel to describe the problem, year later to solve it). Best regards, Krzysztof