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 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C4C0DC433F5 for ; Thu, 30 Sep 2021 08:04:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A9C1E615E0 for ; Thu, 30 Sep 2021 08:04:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1348923AbhI3IDF (ORCPT ); Thu, 30 Sep 2021 04:03:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:60410 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348840AbhI3ICe (ORCPT ); Thu, 30 Sep 2021 04:02:34 -0400 Received: from disco-boy.misterjones.org (disco-boy.misterjones.org [51.254.78.96]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 28AF7615E0; Thu, 30 Sep 2021 08:00:52 +0000 (UTC) Received: from sofa.misterjones.org ([185.219.108.64] helo=why.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1mVqzq-00DuHm-4a; Thu, 30 Sep 2021 09:00:50 +0100 Date: Thu, 30 Sep 2021 09:00:49 +0100 Message-ID: <87fstmtrv2.wl-maz@kernel.org> From: Marc Zyngier To: Linus Walleij Cc: "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , linux-kernel , linux-pci , Bjorn Helgaas , Rob Herring , Lorenzo Pieralisi , Krzysztof =?UTF-8?B?V2lsY3p5xYRza2k=?= , Alyssa Rosenzweig , Stan Skowronek , Mark Kettenis , Sven Peter , Hector Martin , Robin Murphy , Joey Gouly , Joerg Roedel , Android Kernel Team Subject: Re: [PATCH v5 10/14] arm64: apple: Add pinctrl nodes In-Reply-To: References: <20210929163847.2807812-1-maz@kernel.org> <20210929163847.2807812-11-maz@kernel.org> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/27.1 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-SA-Exim-Connect-IP: 185.219.108.64 X-SA-Exim-Rcpt-To: linus.walleij@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, bhelgaas@google.com, robh+dt@kernel.org, lorenzo.pieralisi@arm.com, kw@linux.com, alyssa@rosenzweig.io, stan@corellium.com, kettenis@openbsd.org, sven@svenpeter.dev, marcan@marcan.st, Robin.Murphy@arm.com, joey.gouly@arm.com, joro@8bytes.org, kernel-team@android.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 29 Sep 2021 20:05:42 +0100, Linus Walleij wrote: > > On Wed, Sep 29, 2021 at 6:56 PM Marc Zyngier wrote: > > > From: Mark Kettenis > > > > Add pinctrl nodes corresponding to the gpio,t8101 nodes in the > > Apple device tree for the Mac mini (M1, 2020). > > > > Clock references are left out at the moment and will be added once > > the appropriate bindings have been settled upon. > > > > Signed-off-by: Mark Kettenis > > Reviewed-by: Linus Walleij > > Signed-off-by: Marc Zyngier > > Link: https://lore.kernel.org/r/20210520171310.772-3-mark.kettenis@xs4all.nl > (...) > > + pinctrl_ap: pinctrl@23c100000 { > > + compatible = "apple,t8103-pinctrl", "apple,pinctrl"; > > + reg = <0x2 0x3c100000 0x0 0x100000>; > > + > > + gpio-controller; > > + #gpio-cells = <2>; > > + gpio-ranges = <&pinctrl_ap 0 0 212>; > > In other discussions it turns out that the driver is abusing these gpio-ranges > to find out how many pins are in each pinctrl instance. This is not the > idea with gpio-ranges, these can be multiple and map different sets, > so we need something like > > apple,npins = <212>; > (+ bindings) > > or so... Is it the driver that needs updating? Or the binding? I don't really care about the former, but the latter is more disruptive as it has impacts over both u-boot and at least OpenBSD. How is that solved on other pinctrl blocks? I can't see anyone having a similar a similar property. Thanks, M. -- Without deviation from the norm, progress is not possible.