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=-15.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=ham 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 F39FEC43381 for ; Wed, 13 Jan 2021 14:37:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id AD46723434 for ; Wed, 13 Jan 2021 14:37:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727256AbhAMOhd (ORCPT ); Wed, 13 Jan 2021 09:37:33 -0500 Received: from hostingweb31-40.netsons.net ([89.40.174.40]:58913 "EHLO hostingweb31-40.netsons.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726433AbhAMOhc (ORCPT ); Wed, 13 Jan 2021 09:37:32 -0500 Received: from [185.56.157.72] (port=39770 helo=[192.168.101.73]) by hostingweb31.netsons.net with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1kzhGT-00E4X8-5N; Wed, 13 Jan 2021 15:36:49 +0100 Subject: Re: [RFC 1/2] dt-bindings: clk: versaclock5: Add load capacitance properties To: Adam Ford , Rob Herring Cc: linux-clk , Adam Ford-BE , Michael Turquette , Stephen Boyd , devicetree , Linux Kernel Mailing List References: <20210106173900.388758-1-aford173@gmail.com> <20210113031602.GA1443816@robh.at.kernel.org> From: Luca Ceresoli Message-ID: <8f896ca0-d270-787c-74c9-2bca91ccf7f2@lucaceresoli.net> Date: Wed, 13 Jan 2021 15:36:48 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - hostingweb31.netsons.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lucaceresoli.net X-Get-Message-Sender-Via: hostingweb31.netsons.net: authenticated_id: luca+lucaceresoli.net/only user confirmed/virtual account not confirmed X-Authenticated-Sender: hostingweb31.netsons.net: luca@lucaceresoli.net X-Source: X-Source-Args: X-Source-Dir: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Adam, On 13/01/21 13:31, Adam Ford wrote: > On Tue, Jan 12, 2021 at 9:16 PM Rob Herring wrote: >> >> On Wed, Jan 06, 2021 at 11:38:59AM -0600, Adam Ford wrote: >>> There are two registers which can set the load capacitance for >>> XTAL1 and XTAL2. These are optional registers when using an >>> external crystal. Update the bindings to support them. >>> >>> Signed-off-by: Adam Ford >>> --- >>> .../devicetree/bindings/clock/idt,versaclock5.yaml | 12 ++++++++++++ >>> 1 file changed, 12 insertions(+) >>> >>> diff --git a/Documentation/devicetree/bindings/clock/idt,versaclock5.yaml b/Documentation/devicetree/bindings/clock/idt,versaclock5.yaml >>> index 2ac1131fd922..e5e55ffb266e 100644 >>> --- a/Documentation/devicetree/bindings/clock/idt,versaclock5.yaml >>> +++ b/Documentation/devicetree/bindings/clock/idt,versaclock5.yaml >>> @@ -59,6 +59,18 @@ properties: >>> minItems: 1 >>> maxItems: 2 >>> >>> + idt,xtal1-load-femtofarads: >>> + $ref: /schemas/types.yaml#/definitions/uint32 >> >> Already has a type, so you can drop the $ref. >> >>> + minimum: 9000 >>> + maximum: 25000 > > Luca, > > Do you want the range to the 9000 - 25000 per the datasheet, or should > I use the max value based on the programmer guide? Currently, my > intent was to cap the value to 11111b, so anyone who writes 23000, > 24000, or 25000 will all be the same value based on the feedback I got > from Renesas. DT should describe the HW, so I'd use the same range that can be set in hardware, regardless of driver support. Thus it should be: 9000 - [9000 + 430 * 32] = 9000 - 22760 -- Luca