Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp2679692iog; Mon, 27 Jun 2022 00:04:57 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uuAm6JEVTO8eYAXv1Uuq7K8t7lhEyyuuxvvgZLzbw/UmAmwMjWKsFZ8CqwU8dqK82phb05 X-Received: by 2002:a17:902:d48c:b0:16a:629e:2f21 with SMTP id c12-20020a170902d48c00b0016a629e2f21mr13617998plg.148.1656313497197; Mon, 27 Jun 2022 00:04:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656313497; cv=none; d=google.com; s=arc-20160816; b=gfX4vy24i0eehRkNtiyVTQ5O3mypGwyWZRQ02ZG3O3G6AjqWLOvd77o6aE7tcREh7l 0Smm5G5ue0uMLw/ZHVTo0KeisvlZ8ubf1jyumjSvuo2+GqeWhiDHw9GMaq8q39T1JTAa F0UIJaQzVWGKnw8YuE6RS+1U2JrhxZqQKegFhzHkodkGOudIZVlQ/eqXnNVg+wn4CyY2 8V+k3aoUJfxA0nUFdUtnyj+ZPf1KEHAFlYWECNUvzIYuGE4Xikmg58owFuKOVYlkQxAv Wml56sYy1sS+PFDY6V3ag2x8WrZ2t6iJGTZaTVOaSfC+WjRZXpV4+ZrvT2FT+gbOuD69 UkcQ== 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 :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=l8DLyJeTvw1xggLYIHIAs8lG/FP9YwAC/H3QcrJQQbM=; b=k/FypwLL10b/fElQMB+jh9fGxal6kb5ym/KHrOXgoLVqIPNPNGnuukmqQ0KY1o3cXC SGk+AtrrPVi7QE7kpVdUsJSU4zZF2GobXSh0qpLT5IAk/tk+BMRbG/fJM0ZzQgR9AyHP 20r9CFgzx2LqoqI8e1Dgq7NfKoL4MhJEmpY0dPh1ZCqiyYnb2ES/7GvgpTmOY8QEGlgs V5xbM6AMI3V+wvO48U+P1PW3neuvXFUQXG7171uANXhv7SPOnoinLAS9F+XoJC24dkUf BKkg0cvQTqL0GvprvlOrOSO98BakJ2xaxBVPOI5LTODUXD8D02aica7wLurt5YxDJf9J Fzkg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=lfgBG6Bc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 nu16-20020a17090b1b1000b001eaf4d29385si8792176pjb.127.2022.06.27.00.04.45; Mon, 27 Jun 2022 00:04:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=lfgBG6Bc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 S232066AbiF0Gz1 (ORCPT + 99 others); Mon, 27 Jun 2022 02:55:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46062 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229974AbiF0GzZ (ORCPT ); Mon, 27 Jun 2022 02:55:25 -0400 Received: from mail-ej1-x62f.google.com (mail-ej1-x62f.google.com [IPv6:2a00:1450:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C0902DDA for ; Sun, 26 Jun 2022 23:55:24 -0700 (PDT) Received: by mail-ej1-x62f.google.com with SMTP id pk21so17085739ejb.2 for ; Sun, 26 Jun 2022 23:55:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=l8DLyJeTvw1xggLYIHIAs8lG/FP9YwAC/H3QcrJQQbM=; b=lfgBG6BcegbTxn3oISBf4RsaDUKM1nhVWAfcGq0zhvN4IJqH7WSK7JFr5tCQyT4LhR d3gzqK1269FOcBTTQRj6VW3qzmmFI2wXSc64Nt2UxGUePVjixulD3AFbREgmAsN+lFeL HwiLI3JD9ln4Ucm/7OFwUSa0edTyKBYwXARd8flIWAl5vo19z4kdrlu7947/py5QeJYl 5geBx1o7hjeEa6/y+BjqBlLbb00NtPWXQVfDgYXenyBSH+m2KPcW22e8FAmdWrrzn1Kk jK5n1XfVEc+py+OgSpy6lqVFDccn0L+WAbGo6nrf6yeJtVi6tgZY/qojyRLDyAWyox7c /g5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=l8DLyJeTvw1xggLYIHIAs8lG/FP9YwAC/H3QcrJQQbM=; b=gCIcwpXnICC9kPaqaHmr4256ZLAtkj4SFGlIW3BDdDl0H1r3kmOztYjWeleFa4s0Qg n6imb359zVGpcvDPsSDiRRfRDJMT+rgndaii04EPFyHspR+f9iTvyw9/d3VaGgjOmtl/ roXb3sn5EApDCgGuoKp+VKngKQ7xIwqoGJoeVf5QVg7RjAQoSeMPzFAcklv0epK2TZjw wI4hLFU+CESPJFabhrPbC614KE6jfBkEAbB6MhriT41Zg9LYa526RK2T7JXrc5jWgW+N DyrGfg6kUEcbNFgT012uzDjjsw/Ax8xNx65Na44Ryel0/UtA510zSssgXZIpkL6D7fZN lxSQ== X-Gm-Message-State: AJIora9Ki9U/ojjnGnUizGn7ja7mizUE5nJdyORgjg2Mcei0C2LnulXg iNreGjWSdqm1Di+mJp7I/i/Zpg== X-Received: by 2002:a17:907:60d2:b0:725:5611:cea6 with SMTP id hv18-20020a17090760d200b007255611cea6mr11136755ejc.60.1656312922947; Sun, 26 Jun 2022 23:55:22 -0700 (PDT) Received: from [192.168.0.246] (xdsl-188-155-176-92.adslplus.ch. [188.155.176.92]) by smtp.gmail.com with ESMTPSA id e17-20020a170906505100b006fece722508sm4615390ejk.135.2022.06.26.23.55.21 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 26 Jun 2022 23:55:22 -0700 (PDT) Message-ID: <70cd0066-9aa7-ca41-ad61-898d491328aa@linaro.org> Date: Mon, 27 Jun 2022 08:55:20 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.10.0 Subject: Re: [PATCH 07/14] riscv: dts: canaan: fix the k210's memory node Content-Language: en-US To: Conor.Dooley@microchip.com, damien.lemoal@opensource.wdc.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org Cc: fancer.lancer@gmail.com, tglx@linutronix.de, sam@ravnborg.org, mail@conchuod.ie, Eugeniy.Paltsev@synopsys.com, daniel.lezcano@linaro.org, paul.walmsley@sifive.com, aou@eecs.berkeley.edu, masahiroy@kernel.org, geert@linux-m68k.org, lgirdwood@gmail.com, niklas.cassel@wdc.com, dillon.minfei@gmail.com, jee.heng.sia@intel.com, thierry.reding@gmail.com, joabreu@synopsys.com, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, airlied@linux.ie, linux-kernel@vger.kernel.org, vkoul@kernel.org, palmer@dabbelt.com, broonie@kernel.org, dmaengine@vger.kernel.org, alsa-devel@alsa-project.org, linux-spi@vger.kernel.org, linux-riscv@lists.infradead.org, palmer@rivosinc.com, daniel@ffwll.ch References: <20220618123035.563070-1-mail@conchuod.ie> <20220618123035.563070-8-mail@conchuod.ie> <9cd60b3b-44fe-62ac-9874-80ae2223d078@opensource.wdc.com> <891cf74c-ac0a-b380-1d5f-dd7ce5aeda9d@opensource.wdc.com> <6c9de242-6ccf-49a2-8422-e6949c5169ff@microchip.com> From: Krzysztof Kozlowski In-Reply-To: <6c9de242-6ccf-49a2-8422-e6949c5169ff@microchip.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.1 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,T_SCC_BODY_TEXT_LINE autolearn=ham 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-kernel@vger.kernel.org On 21/06/2022 11:49, Conor.Dooley@microchip.com wrote: > On 20/06/2022 01:25, Damien Le Moal wrote: >> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe >> >> On 6/20/22 08:54, Conor.Dooley@microchip.com wrote: >>> On 20/06/2022 00:38, Damien Le Moal wrote: >>>> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe >>>> >>>> On 6/18/22 21:30, Conor Dooley wrote: >>>>> From: Conor Dooley >>>>> >>>>> The k210 memory node has a compatible string that does not match with >>>>> any driver or dt-binding & has several non standard properties. >>>>> Replace the reg names with a comment and delete the rest. >>>>> >>>>> Signed-off-by: Conor Dooley >>>>> --- >>>>> --- >>>>> arch/riscv/boot/dts/canaan/k210.dtsi | 6 ------ >>>>> 1 file changed, 6 deletions(-) >>>>> >>>>> diff --git a/arch/riscv/boot/dts/canaan/k210.dtsi b/arch/riscv/boot/dts/canaan/k210.dtsi >>>>> index 44d338514761..287ea6eebe47 100644 >>>>> --- a/arch/riscv/boot/dts/canaan/k210.dtsi >>>>> +++ b/arch/riscv/boot/dts/canaan/k210.dtsi >>>>> @@ -69,15 +69,9 @@ cpu1_intc: interrupt-controller { >>>>> >>>>> sram: memory@80000000 { >>>>> device_type = "memory"; >>>>> - compatible = "canaan,k210-sram"; >>>>> reg = <0x80000000 0x400000>, >>>>> <0x80400000 0x200000>, >>>>> <0x80600000 0x200000>; >>>>> - reg-names = "sram0", "sram1", "aisram"; >>>>> - clocks = <&sysclk K210_CLK_SRAM0>, >>>>> - <&sysclk K210_CLK_SRAM1>, >>>>> - <&sysclk K210_CLK_AI>; >>>>> - clock-names = "sram0", "sram1", "aisram"; >>>>> }; >>>> >>>> These are used by u-boot to setup the memory clocks and initialize the >>>> aisram. Sure the kernel actually does not use this, but to be in sync with >>>> u-boot DT, I would prefer keeping this as is. Right now, u-boot *and* the >>>> kernel work fine with both u-boot internal DT and the kernel DT. >>> >>> Right, but unfortunately that desire alone doesn't do anything about >>> the dtbs_check complaints. >>> >>> I guess the alternative approach of actually documenting the compatible >>> would be more palatable? >> >> Yes, I think so. That would allow keeping the fields without the DTB build >> warnings. > > Hmm looks like that approach contradicts the dt-schema; > https://github.com/devicetree-org/dt-schema/blob/main/dtschema/schemas/memory.yaml > > @Rob,Krzysztof what is one meant to do here? Why do you think it contradict bindings? Bindings for memory allow additional properties, so you just need to create binding for this one. And make it a correct binding, IOW, be sure that these clocks are real etc. Although usually we had separate bindings (and device drivers) for memory controllers, instead of including them in the "memory" node. Best regards, Krzysztof