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.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI,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 B5548C4707A for ; Fri, 21 May 2021 18:25:52 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 3C2CC613E1 for ; Fri, 21 May 2021 18:25:52 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3C2CC613E1 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org 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=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:Cc: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=ILotCkcEmZrxET9JV6kkjS4yoKq4bvqy1FrfFvbk3gA=; b=frEW9dYJxHMxiFvSpqlbfR0B0w MTb2bSPHYlMBI1P1ykRUgfkOKuvNQsM6m3J0q7aaqXyMCkTLq7+N26cmQ6PkTAeUT7nWtLRxhYshS DlfWCFVZj5vnCkRz1JICP2dkAntH2Dvi//XO6/lyEtlO8Yxm+CflaIcHzv3g3qdfFx7LL+vuv5uwZ zej/eOS6Jhxl5NLvfA0qyn0ArFXpu4PQGsNR9wCgwjIxtDE8VRnZoVNbUierCkJoH7Zpu7haF8Pop +a8ZwW26bwEkTDv4NNdmTul+v5rZG2y3g3p1W2onSBS3sqIxg50XH8XdHA/vxW8JiBkwRNRXzSNNo 3YSleh5g==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lk9oj-000hsI-Pa; Fri, 21 May 2021 18:24:13 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lk9og-000hrH-8E for linux-arm-kernel@desiato.infradead.org; Fri, 21 May 2021 18:24:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=M4QX6algtyH9gp6amFadSRByvGetkxKzfRSL1H+K+/U=; b=DDEEDlnpT2NlPw7tf5AyMLTzh4 HYZwoOxYRrxS8Au4obgJ+2pnhw/RfpCDD6pWFX/0VvTmgfRP7l+RvQw3eT1yIUzSKskcOhkmrqaPZ mSgT2auZyD4A4qMf0yghAIyKYSM3lqtetLB9NBf88Ksd09dr8EqWirKBGorjZXoHBnl74Zkvz551C 0MqDEzBtFeKAHVJ8CUx0hppjT0CdWfkqsMx2GcA+qMuX0Vj8F58eP661hG3laRbQolNcb9P9MZS6S 4DllbZvLHY5SYjRgz/mKzb5Le1QBF7tj7Ej5chi7CHgGXgRmtGDQaSOyICR0fCD+E9oqM2X28Xmba OcaJn9TQ==; Received: from mail-ot1-f44.google.com ([209.85.210.44]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lk9od-00HLsa-5C for linux-arm-kernel@lists.infradead.org; Fri, 21 May 2021 18:24:08 +0000 Received: by mail-ot1-f44.google.com with SMTP id d25-20020a0568300459b02902f886f7dd43so18850898otc.6 for ; Fri, 21 May 2021 11:24:06 -0700 (PDT) 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=M4QX6algtyH9gp6amFadSRByvGetkxKzfRSL1H+K+/U=; b=h+iG/3bofHEVGLwhXmS6WWKsCbqWJeiv+LoU+F+Pt2VaFTtuB1uBfz8snE26wt/6TW TmXEu20tPP89V/p08RNmFTZME+bklpB/JydxaJL5esUjHrza5+TAuH4+cpAfukJfkoGw 3tlJ3xyjw8y4OmmTdalWw9D26RZGUG1s8w2wM6X5kF4RKahVKsTKnv59NOVMt6zhm1it MkM6p9fbHstgEPEKkv73X67+8NH1PCNmCt0CjFsPQajokVbxf2t0M9SSlyAsCVj13OTC vHtW8izvcbejRVqVvDrU1T/T07vzZwAVCI69Whyhkjtq/woj8/DlJfu3srBQ9OBjRl6J oYbA== X-Gm-Message-State: AOAM530T1QqXOigdibli1FVuLA7QjwDFtFR6NvonriXPQcH8VtcK6GBQ aaZJeM3iA9sPF1P+I9/npA== X-Google-Smtp-Source: ABdhPJwUvx6WTekj9uYPxR7A/4oGbDYAgyfdI2nVf7dJuc994Lp+MYYuUcF7UyWjvLf9ApJ6oufM3A== X-Received: by 2002:a9d:51c7:: with SMTP id d7mr9244199oth.51.1621621445985; Fri, 21 May 2021 11:24:05 -0700 (PDT) Received: from robh.at.kernel.org (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id t26sm1442453otc.23.2021.05.21.11.24.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 21 May 2021 11:24:05 -0700 (PDT) Received: (nullmailer pid 151912 invoked by uid 1000); Fri, 21 May 2021 18:24:03 -0000 Date: Fri, 21 May 2021 13:24:03 -0500 From: Rob Herring To: Geert Uytterhoeven Cc: Linus Walleij , Laurent Pinchart , Bartosz Golaszewski , =?iso-8859-1?Q?Beno=EEt?= Cousson , Tony Lindgren , Jan Tuerk , Shawn Guo , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , "open list:GPIO SUBSYSTEM" , Linux-OMAP , Linux ARM Subject: Re: [PATCH 3/3] dt-bindings: gpio: pcf857x: Convert to json-schema Message-ID: <20210521182403.GA50332@robh.at.kernel.org> References: <52df0592c81ac000d3f486a9ba5a4d84b0f42c47.1621583562.git.geert+renesas@glider.be> 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-20210521_112407_225235_E45A8C7C X-CRM114-Status: GOOD ( 34.61 ) 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: , 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 Fri, May 21, 2021 at 12:23:47PM +0200, Geert Uytterhoeven wrote: > Hi Linus, > > On Fri, May 21, 2021 at 12:04 PM Linus Walleij wrote: > > On Fri, May 21, 2021 at 9:54 AM Geert Uytterhoeven > > wrote: > > > Convert the PCF857x-compatible I/O expanders Device Tree binding > > > documentation to json-schema. > > > > > > Document missing compatible values, properties, and gpio hogs. > > > > > > Signed-off-by: Geert Uytterhoeven > > > > (...) > > > Perhaps the "ti,pcf8575" construct should be removed, and the few users > > > fixed instead? > > > > You would rather list it as deprecated I think? > > It is ABI... > > All DTS files use the "nxp,pcf8575" fallback, except for > arch/x86/platform/ce4100/falconfalls.dts. > The latter ain't working with Linux, as the Linux driver doesn't > match against "ti,pcf8575"... Perhaps can it just be removed? > > > > + gpio-controller: true > > > > So this is implicitly using the generic schema in > > /dtschema/schemas/gpio/gpio.yaml > > if you leave it out: > > Documentation/devicetree/bindings/gpio/nxp,pcf8575.yaml: ignoring, > error in schema: properties > warning: no schema found in file: > Documentation/devicetree/bindings/gpio/nxp,pcf8575.yaml > Documentation/devicetree/bindings/gpio/nxp,pcf8575.yaml: > properties: 'gpio-controller' is a dependency of '#gpio-cells' > from schema $id: http://devicetree.org/meta-schemas/gpios.yaml# > > > > + lines-initial-states: > > > + $ref: /schemas/types.yaml#/definitions/uint32 > > > + description: > > > + Bitmask that specifies the initial state of each line. > > > + When a bit is set to zero, the corresponding line will be initialized to > > > + the input (pulled-up) state. > > > + When the bit is set to one, the line will be initialized to the > > > + low-level output state. > > > + If the property is not specified all lines will be initialized to the > > > + input state. > > > > Is this something we standardized or something that should > > actually be a custom "nxp," property we just missed it? > > (Looks like the latter... oh well, now it is there.) > > Too late for an "nxp," prefix. > See the NOTE in drivers/gpio/gpio-pcf857x.c: > > /* NOTE: these chips have strange "quasi-bidirectional" I/O pins. > * We can't actually know whether a pin is configured (a) as output > * and driving the signal low, or (b) as input and reporting a low > * value ... without knowing the last value written since the chip > * came out of reset (if any). We can't read the latched output. > * > * In short, the only reliable solution for setting up pin direction > * is to do it explicitly. The setup() method can do that, but it > * may cause transient glitching since it can't know the last value > * written (some pins may need to be driven low). > * > * Using n_latch avoids that trouble. When left initialized to zero, > * our software copy of the "latch" then matches the chip's all-ones > * reset state. Otherwise it flags pins to be driven low. > */ > > > > +patternProperties: > > > + "^(hog-[0-9]+|.+-hog(-[0-9]+)?)$": > > > + type: object > > > > But this is already in > > /dtschema/schemas/gpio/gpio-hog.yaml > > for nodename, isn't that where it properly belongs? > > > > I'm however confused here Rob will know what to do. This one is a bit odd. > If we leave this out, something still has to refer to it? > I see no other binding doing that... It's selected by 'gpio-hog' being present, but here you need to make sure that's the case. And I would hope you could define the node name to be just 1 of the 2 cases. Rob _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel