Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp1267390rdb; Wed, 24 Jan 2024 09:37:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IGzopBGRBKuyL+XMyBN+qIIBP7muHnlVFpzRfsNr8vqWyKtJvaJHpo3WV5AUISY4ESDC5o+ X-Received: by 2002:a05:6a20:3ca5:b0:19c:65c2:45ff with SMTP id b37-20020a056a203ca500b0019c65c245ffmr1226814pzj.33.1706117826527; Wed, 24 Jan 2024 09:37:06 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706117826; cv=pass; d=google.com; s=arc-20160816; b=XoLriAZUtJ7IGKfBk8aLr6n8eo3tMst5bGrqKJKSnIQJBf5W29vgzYBpUaiB5n7XBO hm4DVvi8kovi1g99jEK63roywI59uvJcRk4f+Okx6ReF9NUZm/WdC8rUVS2aIigkylxS DH9m6lwdtG2AG+FA4ssSXMO9kAcI5iPDTbNUXJCH/shDx7pPfGFbh2nErPPM+FEUJhOM GQHrmeNoLLOFKvSTkvHAmCg63T9ICByYYxC/655d6WAr6aYvARaISAjXx3YbcpsAj+nU KupqGYahHT5ga/wsH2kvZMjo1USj/8NXup8kgPG51U4kuxCdVsnnbSAvKCCzKmP2Ttg6 GXvg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:references:subject:from:to:cc:message-id:date :content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:dkim-signature; bh=FAy7AHDWICCoITFYxoF5yUyISVpdkZcGB4MmMxueyRw=; fh=0xqtyUqvd860RcblEPPoZttzlcgGFEZ5Vk/yy8MyLnQ=; b=wlxYSyTqAknqekqsS2dxlncT5MoDgZyhREupmYVmK8T7s0aSBlPhdwGz0tvypVkFdM 0U1qR6IzSJTT1XezXwDFDG9QuT9FrkvwWZBp75nlt6X29jPhwNRCAn8tylfxImNWmBAS UXg4WaAt53w+e9KyXbS3cT50WQKcpxwQQmPXmOoImQGx8NwOLA2ArY9pV6Ot1HPU4wjV E+uxiYMI9bqANhhENRuwEFc/dZv94IenrEueMnl7zfuYRxtkTWNPR3mk1ICotCyVtwje Hr4q5uH5NPc3LfFaGlf6sb2HMIyUhjQxuZ75oTlibiOE4Dz4KEuKDelaxkZUP4xLGehn qSyw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=Uhh3Cyxd; arc=pass (i=1 spf=pass spfdomain=bootlin.com dkim=pass dkdomain=bootlin.com dmarc=pass fromdomain=bootlin.com); spf=pass (google.com: domain of linux-kernel+bounces-37437-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-37437-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id fe17-20020a056a002f1100b006dd8483edc4si2195326pfb.157.2024.01.24.09.37.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Jan 2024 09:37:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-37437-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=Uhh3Cyxd; arc=pass (i=1 spf=pass spfdomain=bootlin.com dkim=pass dkdomain=bootlin.com dmarc=pass fromdomain=bootlin.com); spf=pass (google.com: domain of linux-kernel+bounces-37437-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-37437-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id A0EBA28D082 for ; Wed, 24 Jan 2024 17:33:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 80D971292D7; Wed, 24 Jan 2024 17:31:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="Uhh3Cyxd" Received: from relay1-d.mail.gandi.net (relay1-d.mail.gandi.net [217.70.183.193]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A12AA128395; Wed, 24 Jan 2024 17:31:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.193 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706117505; cv=none; b=amH58QwokYuoIOcvHZnbH6jVb3NRFGKsDr0jDdrKQ3IdNSLHuE0szdh947d02h43Zr6+cywK3+FjNHd47KYCah3jWMG+7Za5VhbU+026DT2s/VEq4nEoUhFioxgndflG8G3CdkLPJcDwctPovXc6/QGjq+gsNeuJ93PI131vUd8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706117505; c=relaxed/simple; bh=LyF+uGG8rthtsLAGU6JwLDXQ2xY38jRfZIJ/nE/+i4U=; h=Mime-Version:Content-Type:Date:Message-Id:Cc:To:From:Subject: References:In-Reply-To; b=TLuypNU1rl9PKEDR2UPCVFSvic62fUgJcfk0aDwH1+Hdfvvm6WEq/cLCiUV0DQsJbDQbHw/tjN0YE1xiMy/WQjca2bVpInQsjOYyp7aON+Ebgh1GYwXzzSfkoQgnqpj2FhUuh/XBsNpYmRXvvTpK6HQcRxoTBXZvXxkqvKqjbhw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=Uhh3Cyxd; arc=none smtp.client-ip=217.70.183.193 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Received: by mail.gandi.net (Postfix) with ESMTPSA id AC82B240005; Wed, 24 Jan 2024 17:31:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1706117500; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=FAy7AHDWICCoITFYxoF5yUyISVpdkZcGB4MmMxueyRw=; b=Uhh3CyxddNadp3bKW19Bu/aCIlFIQepSAUY9rIKbk4eMy3+Hsd6tC2BF0Ckv+XHavn6JXm fRDgh7zMogbFUGlEnTsJaCM1frdY/nxfTYmpI88kf8dAvxgG8qmJkn294h+KYxlHXcpYzG 9bYIDnIzycyT/FUtIJkoXPFXXJgk5KuPSXKJOybcNST3/sp5MOkX3S8LFqpkKIbfRTeuoP P5NkAOHxlPlC+d2kMsmmx6Bm+HRdQzaojyr4FGCEXjre6A77llIpsjUO8DnbeXnsd5damr VkrM0a0f+mzrn2F1tzM/bX95x99sl13FNSWD3aSaHsmy0PHd4yC5orLxj9ES6w== Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Wed, 24 Jan 2024 18:31:39 +0100 Message-Id: Cc: "Gregory CLEMENT" , "Michael Turquette" , "Stephen Boyd" , "Krzysztof Kozlowski" , "Conor Dooley" , "Thomas Bogendoerfer" , "Linus Walleij" , =?utf-8?q?Rafa=C5=82_Mi=C5=82ecki?= , "Philipp Zabel" , "Vladimir Kondratiev" , , , , , "Thomas Petazzoni" , "Tawfik Bayouk" , To: "Rob Herring" From: =?utf-8?q?Th=C3=A9o_Lebrun?= Subject: Re: [PATCH v3 10/17] pinctrl: eyeq5: add platform driver X-Mailer: aerc 0.15.2 References: <20240123-mbly-clk-v3-0-392b010b8281@bootlin.com> <20240123-mbly-clk-v3-10-392b010b8281@bootlin.com> <20240124151949.GB930997-robh@kernel.org> In-Reply-To: <20240124151949.GB930997-robh@kernel.org> X-GND-Sasl: theo.lebrun@bootlin.com Hello, On Wed Jan 24, 2024 at 4:19 PM CET, Rob Herring wrote: > On Tue, Jan 23, 2024 at 07:46:55PM +0100, Th=C3=A9o Lebrun wrote: > > Add the Mobileye EyeQ5 pin controller driver. It might grow to add late= r > > support of other platforms from Mobileye. It belongs to a syscon region > > called OLB. > >=20 > > Existing pins and their function live statically in the driver code > > rather than in the devicetree, see compatible match data. > > > > Signed-off-by: Th=C3=A9o Lebrun > > --- [...] > > diff --git a/drivers/pinctrl/pinctrl-eyeq5.c b/drivers/pinctrl/pinctrl-= eyeq5.c [...] > > +static const struct eq5p_match eq5p_match_a =3D { > > + .regs =3D { > > + [EQ5P_PD] =3D 0x0C0, > > + [EQ5P_PU] =3D 0x0C4, > > + [EQ5P_DS_LOW] =3D 0x0D0, > > + [EQ5P_DS_HIGH] =3D 0x0D4, > > + [EQ5P_IOCR] =3D 0x0B0, > > + }, > > + .pins =3D eq5p_pins_a, > > + .npins =3D ARRAY_SIZE(eq5p_pins_a), > > + .funcs =3D eq5p_functions_a, > > + .nfuncs =3D ARRAY_SIZE(eq5p_functions_a), > > +}; > > + > > +static const struct eq5p_match eq5p_match_b =3D { > > + .regs =3D { > > + [EQ5P_PD] =3D 0x0C8, > > + [EQ5P_PU] =3D 0x0CC, > > + [EQ5P_DS_LOW] =3D 0x0D8, > > + [EQ5P_DS_HIGH] =3D 0x0DC, > > + [EQ5P_IOCR] =3D 0x0B4, > > + }, > > These are all the same relative offsets, so you really only need to=20 > store the base offset. Indeed, and I don't think I had even noticed. Thanks. > The use of 2 compatibles is a bit questionable as the programming model= =20 > appears to be the same and only which pins differ. Surely there are=20 > some other pinctrl drivers handling mutiple instances. I can confirm the programming model is the same across both banks. I've addressed your comment in my answer to yours on [PATCH v3 04/17]. Thanks, -- Th=C3=A9o Lebrun, Bootlin Embedded Linux and Kernel engineering https://bootlin.com