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 X-Spam-Level: X-Spam-Status: No, score=-9.5 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4DFB3C388F7 for ; Tue, 10 Nov 2020 23:08:00 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CA1FE20679 for ; Tue, 10 Nov 2020 23:07:59 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="xDtQklfp"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="jgGYW95o" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CA1FE20679 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=yE7rDPqix7GtQeJkJIT5eU0c8nOu/ZIpz0GbTW4xH+U=; b=xDtQklfpKQ81ykOx6tihRKyXt 2kjm/Loh+k9oMg9SvJOzVxrVXFjB7qvCDrYdYmSRU4sT1JJs20+YCO3ptklbRCkSeGqURPXV77Dep rZN9HNdD+Kl19aNjaAdHwUmQrKtFCeJDmasBs8feS8N/sinaK1w+sv6eol/i1NSR8ODR+UCpDEi38 3pglrE+7y89G+FpwVcj+/abYrYxajRvA63uZtf37jn73Pao7YH3M3kegKWLKr/nlDWaXEW5k84Qpn SJzhmDRY0+UQI2G7z9j/rMzbiREZTAt1DOO8VIYkbUrT6azhU1Umy5SDMY80IqHlguKmVdFS8r4AA HCSuo9M8w==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kcciq-0006x7-Ml; Tue, 10 Nov 2020 23:06:44 +0000 Received: from mail-ej1-x642.google.com ([2a00:1450:4864:20::642]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kccin-0006wd-Sx for linux-arm-kernel@lists.infradead.org; Tue, 10 Nov 2020 23:06:43 +0000 Received: by mail-ej1-x642.google.com with SMTP id o21so133889ejb.3 for ; Tue, 10 Nov 2020 15:06:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=SmORY5VYIbu+3sCJt6w8Nrmhwl2bckCo6RS1zo++7Sw=; b=jgGYW95ou/hRhqgwdufoUaNm8PBkg2U97a6aRBnyMFHIjpOQ/kwxQ5pqAN28rZgbVv p5vUlvfkpWFaCxRv3VNk/xkJDzkIVLl/FJlc99MZ/nxsiM3DPx4Svw+vZKHIklUgW3xi uRwal5DXgFkL57kG1zgXJKCC57cOcEA0YsPdsmycraMYLoDfqljJYCZiyXHP1QgqbDGL fRlRtSDoSkRsCF61Nq0NAKeCe6CIYsHVOwTVFJSWX30oip7IY8VgKzV5MCUAx0uCZ4lW vlxrG3vxLEt4mTPYfYTKMWg47JA2trHYttF58+APohAmhn4e5HAa9rZ40PP3omgH7tAm qKaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=SmORY5VYIbu+3sCJt6w8Nrmhwl2bckCo6RS1zo++7Sw=; b=ChqeZA/JuvVw5Az3Vveg5KdhMDQ7uWUfkhNC4weujFbKsyhQrPdvGtkEqgC4HskaxY qx+UfkkSRMp0gSnZ4LrWem2tdNWA3OpUmQln2CuQN4LPb58Z/BURLc3red5H44dPmENG Bb+Iwy6L4YGKbkB9g5DL9w+oBiO+8t8QKZ3YqKosjgCACqPSkBSgyCGYDOpFNiT8lkit K2xD1bad9r6JfELsuBrEg232XydhW1jkfjJVed7YIZR4QkJKT8c+rbbF53Gimegcg5Hi vYgYALJ0jVJlgC3aPHejsvElmg+/xZuGwkrTZZxOIMZ/pWcgu0CokbhqkVYd+UDoMcyl Ra4A== X-Gm-Message-State: AOAM533eXlVurbZdQdUUoKmu27FA6B81o3+s+Uddmn/U7HAu92R0d8O6 nNYWSp/KfdCQCcjLeynFxlY= X-Google-Smtp-Source: ABdhPJw4dSSVXa5gQV5aoC/yeC49D1O0Er+XuqWl7AgeBZ0WjL9K+L/3v9Iy5r+StoBv4H2pwOB4HA== X-Received: by 2002:a17:906:60c8:: with SMTP id f8mr23196957ejk.14.1605049600712; Tue, 10 Nov 2020 15:06:40 -0800 (PST) Received: from skbuf ([188.25.2.177]) by smtp.gmail.com with ESMTPSA id h23sm48382edv.69.2020.11.10.15.06.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Nov 2020 15:06:40 -0800 (PST) Date: Wed, 11 Nov 2020 01:06:38 +0200 From: Vladimir Oltean To: Florian Fainelli Subject: Re: [PATCH 08/10] ARM: dts: NSP: Add a default compatible for switch node Message-ID: <20201110230638.6vlq55zsd3s36t3i@skbuf> References: <20201110033113.31090-1-f.fainelli@gmail.com> <20201110033113.31090-9-f.fainelli@gmail.com> <20201110223709.vca534wynwgfkz77@skbuf> <20201110224820.gbz3tcl6lzjbe3zo@skbuf> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201110_180642_046838_3855D232 X-CRM114-Status: GOOD ( 37.58 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrew Lunn , Scott Branden , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , netdev@vger.kernel.org, =?utf-8?B?UmFmYcWCIE1pxYJlY2tp?= , open list , Vivien Didelot , Rob Herring , "maintainer:BROADCOM IPROC ARM ARCHITECTURE" , Hauke Mehrtens , Ray Jui , Jakub Kicinski , Kurt Kanzenbach , "David S. Miller" , "moderated list:BROADCOM IPROC ARM ARCHITECTURE" Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Nov 10, 2020 at 02:52:57PM -0800, Florian Fainelli wrote: > On 11/10/20 2:48 PM, Vladimir Oltean wrote: > > On Tue, Nov 10, 2020 at 02:40:43PM -0800, Florian Fainelli wrote: > >> On 11/10/20 2:37 PM, Vladimir Oltean wrote: > >>> On Mon, Nov 09, 2020 at 07:31:11PM -0800, Florian Fainelli wrote: > >>>> Provide a default compatible string which is based on the 58522 SRAB > >>>> compatible, this allows us to have sane defaults and silences the > >>>> following warnings: > >>>> > >>>> arch/arm/boot/dts/bcm958522er.dt.yaml: > >>>> ethernet-switch@36000: compatible: 'oneOf' conditional failed, > >>>> one > >>>> must be fixed: > >>>> ['brcm,bcm5301x-srab'] is too short > >>>> 'brcm,bcm5325' was expected > >>>> 'brcm,bcm53115' was expected > >>>> 'brcm,bcm53125' was expected > >>>> 'brcm,bcm53128' was expected > >>>> 'brcm,bcm5365' was expected > >>>> 'brcm,bcm5395' was expected > >>>> 'brcm,bcm5389' was expected > >>>> 'brcm,bcm5397' was expected > >>>> 'brcm,bcm5398' was expected > >>>> 'brcm,bcm11360-srab' was expected > >>>> 'brcm,bcm5301x-srab' is not one of ['brcm,bcm53010-srab', > >>>> 'brcm,bcm53011-srab', 'brcm,bcm53012-srab', 'brcm,bcm53018-srab', > >>>> 'brcm,bcm53019-srab'] > >>>> 'brcm,bcm5301x-srab' is not one of ['brcm,bcm11404-srab', > >>>> 'brcm,bcm11407-srab', 'brcm,bcm11409-srab', 'brcm,bcm58310-srab', > >>>> 'brcm,bcm58311-srab', 'brcm,bcm58313-srab'] > >>>> 'brcm,bcm5301x-srab' is not one of ['brcm,bcm58522-srab', > >>>> 'brcm,bcm58523-srab', 'brcm,bcm58525-srab', 'brcm,bcm58622-srab', > >>>> 'brcm,bcm58623-srab', 'brcm,bcm58625-srab', 'brcm,bcm88312-srab'] > >>>> 'brcm,bcm5301x-srab' is not one of ['brcm,bcm3384-switch', > >>>> 'brcm,bcm6328-switch', 'brcm,bcm6368-switch'] > >>>> From schema: > >>>> Documentation/devicetree/bindings/net/dsa/b53.yaml > >>>> > >>>> Signed-off-by: Florian Fainelli > >>>> --- > >>>> arch/arm/boot/dts/bcm-nsp.dtsi | 2 +- > >>>> 1 file changed, 1 insertion(+), 1 deletion(-) > >>>> > >>>> diff --git a/arch/arm/boot/dts/bcm-nsp.dtsi b/arch/arm/boot/dts/bcm-nsp.dtsi > >>>> index 09fd7e55c069..8453865d1439 100644 > >>>> --- a/arch/arm/boot/dts/bcm-nsp.dtsi > >>>> +++ b/arch/arm/boot/dts/bcm-nsp.dtsi > >>>> @@ -386,7 +386,7 @@ ccbtimer1: timer@35000 { > >>>> }; > >>>> > >>>> srab: ethernet-switch@36000 { > >>>> - compatible = "brcm,nsp-srab"; > >>>> + compatible = "brcm,bcm58522-srab", "brcm,nsp-srab"; > >>>> reg = <0x36000 0x1000>, > >>>> <0x3f308 0x8>, > >>>> <0x3f410 0xc>; > >>>> -- > >>>> 2.25.1 > >>>> > >>> > >>> I am not getting this. > >>> The line: > >>> #include "bcm-nsp.dtsi" > >>> > >>> can be found in: > >>> > >>> arch/arm/boot/dts/bcm988312hr.dts > >>> arch/arm/boot/dts/bcm958625hr.dts > >>> arch/arm/boot/dts/bcm958622hr.dts > >>> arch/arm/boot/dts/bcm958625k.dts > >>> arch/arm/boot/dts/bcm958522er.dts > >>> arch/arm/boot/dts/bcm958525er.dts > >>> arch/arm/boot/dts/bcm958623hr.dts > >>> arch/arm/boot/dts/bcm958525xmc.dts > >>> > >>> > >>> The pattern for the other DTS files that include this seems to be to > >>> overwrite the compatible locally in bcm958522er.dts, like this: > >>> > >>> &srab { > >>> compatible = "brcm,bcm58522-srab", "brcm,nsp-srab"; > >>> }; > >>> > >>> Is there a reason why you are choosing to put an SoC specific compatible > >>> in the common bcm-nsp.dtsi? > >> > >> It is necessary to silence the warnings provided in the commit message > >> even when the srab node is disabled, since the dt_binding_check rule > >> will check all of the nodes matching the pattern. If there is a better > >> way to do this, I would gladly do it differently. > >> -- > >> Florian > > > > I am still not getting it. The exact 3 lines from above will not change > > the "status" property from "disabled" to "okay", so I don't understand > > why it matters whether it's enabled or not. The dt_binding_check error > > isn't in the DTSI, it's in bcm958522er.dts. All that needs to be done is > > that the bcm958522er.dts needs to override the compatible from the DTSI > > and only the compatible, I believe. With no occurrence of an incomplete > > list of compatibles in any final DTS, the dt_binding_check should not > > complain about that single occurrence in the DTSI as far as I know (and > > I did not test this). > > There is not a switch being enabled in > arch/arm/boot/dts/bcm958522er.dts, so sure, I could add the 3 lines you > quote above and that would silence the warning, but that does not scale > at all across DTS files including bcm5301x.dtsi for instance, it sort of > does for those including bcm-nsp.dtsi. > -- > Florian I see only bcm47081.dtsi and bcm4708.dtsi to include bcm5301x.dtsi, and you did point out in the other email that the BCM4708* SoCs always contain a BCM53010 switch, so that would make the other patch not wrong. Either way, it's up to you and Rafal. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel