From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D475818FDAB; Tue, 20 Aug 2024 15:36:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724168194; cv=none; b=ZbSyvY4B7GJ/ZGjEX1LWk8GkIi4m6ZfTz1Ast3gwmRWJ5Z0dNCCMP8KV1yRfO0cgKzqRuY0bcga/KL6sIrwqIBbTtiP16vSiX9uZqAKWzxIJIvE4/w4K7QWuADTcQd1HRhMh3PshBZ2HHaajBzMEvHe9+tquoA6yVghqvY0xGjE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724168194; c=relaxed/simple; bh=//L2My3Xu7jix4e3xSRB1Agqzokv5wZYx6F2RIQLhBY=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=d3Mill6GoCpLJ5j8GeD/odfTj6b05aB3VI9SaA6CHUEPt9/a1cKsJT1htmZ5GFBC2HQ1hD+CAkJJq1o/N+5qCkaN8IfzIVnHy6Q77JBOXoIviA+/mYFZPO5NVFGGkIWaE/Y9f6da3682Xb5VguCWYCwFbbStyKkrwW6RzhYEGaE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=SO18IOyX; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="SO18IOyX" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C5909C4AF0C; Tue, 20 Aug 2024 15:36:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1724168191; bh=//L2My3Xu7jix4e3xSRB1Agqzokv5wZYx6F2RIQLhBY=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=SO18IOyXzcyclVdGaO89sf5tH9ASPFYjNIpXrY+u4PCOtORP4M8NcB/j/vBzacykw n5YraaXu4GZss8hOAV5oJS6/+IXWuKLgRW5dFMEQBFxAApxIv/5qRTn1edPBofRvdC 2z8H1p9TureKYjsk9nReLl9DyeVNhz/XVl/XOCQbHDqiO7bo9rFN0DL+Iszp5UzdU5 Xhz+dcR7nDAbso/UknMxiHVIO/M+oHuq+MYyrPJQfprzWslggvNC7G0GPAnzzk8WSZ gIGI29npWtn2SyXR0xdSah11+Pyu1O+7s0gFPQ7LWjc5bBZXbYwoA6FDRvAnZBWWj5 CF14jwXsXCI4A== Message-ID: <0b639d04-af33-44b0-a556-40decff683c5@kernel.org> Date: Tue, 20 Aug 2024 17:36:26 +0200 Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 1/2] dt-bindings: wireless: restore constraint for brcm,bcm4329-fmac compatible property To: Arend van Spriel Cc: Kalle Valo , Hector Martin , Krzysztof Kozlowski , devicetree@vger.kernel.org, linux-wireless@vger.kernel.org, brcm80211@lists.linux.dev, asahi@lists.linux.dev References: <20240820101216.355012-1-arend.vanspriel@broadcom.com> <20240820101216.355012-2-arend.vanspriel@broadcom.com> <7881c303-bef1-403a-aa70-30d33558f57f@kernel.org> <6777d425-b27f-43d0-ba81-b36ac0b8f929@broadcom.com> From: Krzysztof Kozlowski Content-Language: en-US Autocrypt: addr=krzk@kernel.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xe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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: <6777d425-b27f-43d0-ba81-b36ac0b8f929@broadcom.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 20/08/2024 14:50, Arend van Spriel wrote: > On 8/20/2024 1:39 PM, Krzysztof Kozlowski wrote: >> On 20/08/2024 13:27, Krzysztof Kozlowski wrote: >>> On Tue, Aug 20, 2024 at 12:12:15PM +0200, Arend van Spriel wrote: >>>> When extending the bindings for Apple PCIe devices the compatible property >>>> specification was changed. However, it was changed such that for these >>>> devices it was no longer necessary to have "brcm,bcm4329-fmac" listed as >>>> string in the compatible list property as it was before that extension. >>> >>> Apart that this was never tested... That statement is not true. Look at >>> "fixed" commit - it is not doing like that at all. >>> >>> I don't understand the reasoning. >>> >>>> This patch restores that constraint. >>>> >>>> Fixes: e2e37224e8b3 ("dt-bindings: net: bcm4329-fmac: Add Apple properties & chips") >>>> Signed-off-by: Arend van Spriel >>>> --- >>>> .../net/wireless/brcm,bcm4329-fmac.yaml | 19 ++++++++++--------- >>>> 1 file changed, 10 insertions(+), 9 deletions(-) >>>> >>>> diff --git a/Documentation/devicetree/bindings/net/wireless/brcm,bcm4329-fmac.yaml b/Documentation/devicetree/bindings/net/wireless/brcm,bcm4329-fmac.yaml >>>> index e564f20d8f41..47f90446322f 100644 >>>> --- a/Documentation/devicetree/bindings/net/wireless/brcm,bcm4329-fmac.yaml >>>> +++ b/Documentation/devicetree/bindings/net/wireless/brcm,bcm4329-fmac.yaml >>>> @@ -7,7 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml# >>>> title: Broadcom BCM4329 family fullmac wireless SDIO/PCIE devices >>>> >>>> maintainers: >>>> - - Arend van Spriel >>>> + - Arend van Spriel >>>> >>>> description: >>>> The Broadcom Single chip MAC part for the BCM4329 family and >>>> @@ -27,7 +27,6 @@ properties: >>>> - brcm,bcm4341b0-fmac >>>> - brcm,bcm4341b4-fmac >>>> - brcm,bcm4341b5-fmac >>>> - - brcm,bcm4329-fmac >>>> - brcm,bcm4330-fmac >>>> - brcm,bcm4334-fmac >>>> - brcm,bcm43340-fmac >>>> @@ -46,13 +45,15 @@ properties: >>>> - cypress,cyw43012-fmac >>>> - infineon,cyw43439-fmac >>>> - const: brcm,bcm4329-fmac >>>> - - enum: >>>> - - brcm,bcm4329-fmac >>>> - - pci14e4,43dc # BCM4355 >>>> - - pci14e4,4464 # BCM4364 >>>> - - pci14e4,4488 # BCM4377 >>>> - - pci14e4,4425 # BCM4378 >>>> - - pci14e4,4433 # BCM4387 >>>> + - items: >>>> + - enum: >>>> + - pci14e4,43dc # BCM4355 >>>> + - pci14e4,4464 # BCM4364 >>>> + - pci14e4,4488 # BCM4377 >>>> + - pci14e4,4425 # BCM4378 >>>> + - pci14e4,4433 # BCM4387 >>>> + - const: brcm,bcm4329-fmac >>>> + - const: brcm,bcm4329-fmac >>> >>> And this does not make sense... You claim that some constrained was >>> droppped and you re-add it, but in fact you still add the same code as >>> it was before. >>> >>> NAK. >> >> Ah, the last "const" actually makes sense, I missed that. >> >> Commit still however lacks rationale why these devices are compatible. >> Plus existing rationale that e2e37224e8b3 changed something is entirely >> WRONG. It changed nothing. ZERO. It only added new devices, which was >> claimed are not compatible with brcm,bcm4329-fmac. > > So is that claim true? What does it mean that these new devices are not > compatible. If they are they should be in a separate binding or the Whether binding is separate or not, is just way of organizing things. > applicable properties for these devices should be made conditional. Could be if they are not applicable. > >> Now if you claim that original commit which said "these devices are not >> compatible with brcm,bcm4329-fmac", then please provide arguments, not >> just say "other commit did something". It did nothing... > > Not entirely true. Indeed new devices were added for which no > "brcm,bcm4329-fmac" string is required in the compatible property. Also > the commit added new properties for these new devices. Now in my opinion > a driver should not use these properties without a "compatible" check. > Hope we can agree to that. However, the driver patch for supporting the Sorry, I don't follow. Why the driver would need to check for compatible? > binding change does no such thing. So if we leave the binding as it > currently is the driver will have to check if compatible has any of the > listed PCI IDs before processing the properties. As all properties old Why driver needs to check it? Are these properties not valid? > and new are marked as optional I can not come up with an argument that > these new devices are *not* compatible with brcm,bcm4329-fmac. Compatibility is expressed by implementing same programming interfasce (or its subset) thus being able to bind via fallback and correctly operate in given SW. I don't know whether that's the case here, so rephrasing my earlier comments - the commit msg should focus on this aspect and tell that devices are fully compatible, thus they should use fallback. Quick look at drivers told me that not - they are not compatible... Best regards, Krzysztof