Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757725AbbLCAGz (ORCPT ); Wed, 2 Dec 2015 19:06:55 -0500 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:58291 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754181AbbLCAGx (ORCPT ); Wed, 2 Dec 2015 19:06:53 -0500 Date: Thu, 3 Dec 2015 00:06:31 +0000 From: Mark Brown To: Simon Arlott Cc: devicetree@vger.kernel.org, Liam Girdwood , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , Kumar Gala , linux-kernel@vger.kernel.org, Florian Fainelli , Jonas Gorski Message-ID: <20151203000631.GM1929@sirena.org.uk> References: <565A18DD.60108@simon.arlott.org.uk> <20151130121043.GX1929@sirena.org.uk> <565CB1CF.5040306@simon.arlott.org.uk> <20151201221615.GY1929@sirena.org.uk> <20151202125325.GI1929@sirena.org.uk> <565F53FC.5080309@simon.arlott.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="iZbCgRUW+AWDD03y" Content-Disposition: inline In-Reply-To: <565F53FC.5080309@simon.arlott.org.uk> X-Cookie: A beer delayed is a beer denied. User-Agent: Mutt/1.5.24 (2015-08-30) X-SA-Exim-Connect-IP: 94.175.94.161 X-SA-Exim-Mail-From: broonie@sirena.org.uk Subject: Re: [PATCH 1/2] regulator: Add brcm,bcm63xx-regulator device tree binding X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on mezzanine.sirena.org.uk) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2579 Lines: 64 --iZbCgRUW+AWDD03y Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Dec 02, 2015 at 08:26:36PM +0000, Simon Arlott wrote: > On 02/12/15 12:53, Mark Brown wrote: > > This is the sort of thing you can pick up from the SoC compatible > > strings. As things stand there is zero content in this driver that > > relates to this SoC. > There's always going to be very little content in the driver that > relates to this SoC, given that a single bit flip enables/disables > power. > All other device tree drivers allow a register address to be specified > for the device, how is an offset in the regmap any different? It's not that it's an offset in regmap, it's that you're trying to make a device driver with literally *no* content that is specific to the actual device. If you're making a driver for a specific device like this it should know at least something about how to control the device =66rom the compatible string. If you're making a generic driver it should not make reference to specific devices. In general I would prefer to have a driver with a SoC specific compatible string and the data tables in the kernel, that way we keep the device trees stable and our ABI more robust. > >> The mask is used as there's one bit per regulator in the register, but > >> there's more than one way to express this in the DT: > > I wouldn't expect to see it in the device tree at all for a device > > specific driver. > If there isn't an individual entry in DT for each regulator, how is it > supposed to work? There's no #regulator-cells property. There could be one if it would help, but we do normally manage to do this without - look at how other regulator drivers work. --iZbCgRUW+AWDD03y Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJWX4eGAAoJECTWi3JdVIfQpCAH/0J/ovtd52QiQgJeDjqsPc9B VmWe2aEoe3WNseajWbIgqZJvbN6CH/xuDHkroz+mBIslJQTBbFqYogF4xrBS54i2 KhnTVJuw5dAXwxrCsGqHtEIbSb0x1L7pI9+PJnUiFWf3YcefMAKXoBBjaK/2le1t toQoQvYkn5SiR6wKxLW4ZGD7lFdDy3tUwAEENH5oIGvH8EG+j86Nlz5gpaK23TjW PuZJmdhKbH9wVDqeQn7BxgD4Uptfc1yzPAhkHcU+3HTWv1aoz2dsX+xNQBzOKgS6 tNaA+ck8H1Pkxw7idu1iAsY52XOtVweOrgH4K3FJYRZMkZIVz+Sb2iATyvIlnQU= =emdl -----END PGP SIGNATURE----- --iZbCgRUW+AWDD03y-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/