From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jon Hunter Subject: Re: [PATCH 6/7] pinctrl: tegra: Add DT binding for io pads control Date: Wed, 13 Apr 2016 10:31:05 +0100 Message-ID: <570E11D9.6070708@nvidia.com> References: <1460473007-11535-1-git-send-email-ldewangan@nvidia.com> <1460473007-11535-7-git-send-email-ldewangan@nvidia.com> <570E0BAE.8090404@nvidia.com> <570E0C8C.4070600@nvidia.com> Mime-Version: 1.0 Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <570E0C8C.4070600@nvidia.com> Sender: linux-gpio-owner@vger.kernel.org To: Laxman Dewangan , swarren@wwwdotorg.org, thierry.reding@gmail.com, linus.walleij@linaro.org, gnurou@gmail.com, robh+dt@kernel.org, mark.rutland@arm.com Cc: linux-tegra@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org List-Id: linux-tegra@vger.kernel.org On 13/04/16 10:08, Laxman Dewangan wrote: [snip] > For T210, 64 bit, it is > tegra210.dtsi: pmc: pmc@0,7000e400 { Yes and this is wrong [0]. >>> +Required properties: >>> +- compatible: "nvidia,tegra210-io-pad" >> I think you have have "Must be ..." here. I am also wondering if the >> pinctrl device should be registered by the pmc driver and so not a >> separate driver to the PMC driver. In other words, the PMC driver calls >> pinctrl_register() directly. > > I like to keep the pmc driver as main interface and other sub > functionalities like pad control for voltage and power states, no > iopower control etc as sub drivers. This will help in modular approach > of the driver. OK, let's see what Thierry thinks about this. >>> +The voltage supported on the pads are 1.8V and 3.3V. The enums are >>> defined as: >>> + For 1.8V, use TEGRA210_IO_RAIL_1800000UV >>> + For 3.3V, use TEGRA210_IO_RAIL_3300000UV >> You may consider just using integer values here like we do for >> regulators. > > We just support two values 1.8V and 3.3V only. I am fine with either way > also. > >> >>> + TEGRA210_IO_PAD_DEEP_POWER_DOWN_DISABLE for >>> + disable. >>> + TEGRA210_IO_PAD_DEEP_POWER_DOWN_ENABLE for >>> + enable. >> Sounds like a boolean parameter. So may consider that if the property >> 'nvidia,io-pad-deep-power-down' is present then it means enable >> deep-power-down and if not present then don't. Then you do not need to >> assign a value to it. > > Three states, enable, disable and left default. So absent will be left > default. Fine with me. Cheers Jon [0] http://marc.info/?l=linux-tegra&m=146038329109871&w=2 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934725AbcDMJbP (ORCPT ); Wed, 13 Apr 2016 05:31:15 -0400 Received: from hqemgate14.nvidia.com ([216.228.121.143]:6196 "EHLO hqemgate14.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932614AbcDMJbM (ORCPT ); Wed, 13 Apr 2016 05:31:12 -0400 X-PGP-Universal: processed; by hqnvupgp07.nvidia.com on Wed, 13 Apr 2016 02:28:40 -0700 Subject: Re: [PATCH 6/7] pinctrl: tegra: Add DT binding for io pads control To: Laxman Dewangan , , , , , , References: <1460473007-11535-1-git-send-email-ldewangan@nvidia.com> <1460473007-11535-7-git-send-email-ldewangan@nvidia.com> <570E0BAE.8090404@nvidia.com> <570E0C8C.4070600@nvidia.com> CC: , , , From: Jon Hunter Message-ID: <570E11D9.6070708@nvidia.com> Date: Wed, 13 Apr 2016 10:31:05 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <570E0C8C.4070600@nvidia.com> X-Originating-IP: [10.21.132.108] X-ClientProxiedBy: UKMAIL101.nvidia.com (10.26.138.13) To UKMAIL101.nvidia.com (10.26.138.13) Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 13/04/16 10:08, Laxman Dewangan wrote: [snip] > For T210, 64 bit, it is > tegra210.dtsi: pmc: pmc@0,7000e400 { Yes and this is wrong [0]. >>> +Required properties: >>> +- compatible: "nvidia,tegra210-io-pad" >> I think you have have "Must be ..." here. I am also wondering if the >> pinctrl device should be registered by the pmc driver and so not a >> separate driver to the PMC driver. In other words, the PMC driver calls >> pinctrl_register() directly. > > I like to keep the pmc driver as main interface and other sub > functionalities like pad control for voltage and power states, no > iopower control etc as sub drivers. This will help in modular approach > of the driver. OK, let's see what Thierry thinks about this. >>> +The voltage supported on the pads are 1.8V and 3.3V. The enums are >>> defined as: >>> + For 1.8V, use TEGRA210_IO_RAIL_1800000UV >>> + For 3.3V, use TEGRA210_IO_RAIL_3300000UV >> You may consider just using integer values here like we do for >> regulators. > > We just support two values 1.8V and 3.3V only. I am fine with either way > also. > >> >>> + TEGRA210_IO_PAD_DEEP_POWER_DOWN_DISABLE for >>> + disable. >>> + TEGRA210_IO_PAD_DEEP_POWER_DOWN_ENABLE for >>> + enable. >> Sounds like a boolean parameter. So may consider that if the property >> 'nvidia,io-pad-deep-power-down' is present then it means enable >> deep-power-down and if not present then don't. Then you do not need to >> assign a value to it. > > Three states, enable, disable and left default. So absent will be left > default. Fine with me. Cheers Jon [0] http://marc.info/?l=linux-tegra&m=146038329109871&w=2