Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932667AbcKYRf4 (ORCPT ); Fri, 25 Nov 2016 12:35:56 -0500 Received: from hqemgate14.nvidia.com ([216.228.121.143]:15445 "EHLO hqemgate14.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753052AbcKYRfr (ORCPT ); Fri, 25 Nov 2016 12:35:47 -0500 X-PGP-Universal: processed; by hqpgpgate101.nvidia.com on Fri, 25 Nov 2016 09:33:15 -0800 Subject: Re: [PATCH V4 2/2] pinctrl: tegra: Add driver to configure voltage and power of io pads To: Laxman Dewangan , Thierry Reding References: <1479976734-30498-1-git-send-email-ldewangan@nvidia.com> <1479976734-30498-3-git-send-email-ldewangan@nvidia.com> <20161125095744.GB11512@ulmo.ba.sec> <583828D5.5060507@nvidia.com> CC: , , , , , , , , , , From: Jon Hunter Message-ID: Date: Fri, 25 Nov 2016 17:29:31 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <583828D5.5060507@nvidia.com> X-Originating-IP: [10.26.11.151] X-ClientProxiedBy: DRUKMAIL101.nvidia.com (10.25.59.19) 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 Content-Length: 1836 Lines: 47 On 25/11/16 12:04, Laxman Dewangan wrote: > Thanks Thierry for review. > > On Friday 25 November 2016 03:27 PM, Thierry Reding wrote: >> * PGP Signed by an unknown key >> >> On Thu, Nov 24, 2016 at 02:08:54PM +0530, Laxman Dewangan wrote: >>> + NVIDIA Tegra124/210 SoC has IO pads which supports multi-voltage >>> + level of interfacing and deep power down mode of IO pads. The >>> + voltage of IO pads are SW configurable based on IO rail of that >>> + pads on T210. This driver provides the interface to change IO pad >>> + voltage and power state via pincontrol interface. >> This has a lot of chip-specific text. Will all of that have to be >> updated if support for new chips is added? > > Then saying that Tegra124 and later.. > Hoping, people know our chip releasing sequence as numbering are not in > sequence. > >> >>> +#include >>> +#include >> Have you considered moving this code into the PMC driver? It seems a >> little over the top to go through all of the platform device creation >> and driver registration dance only to call into a public API later on. > > Yes, we had discussion on this and suggestion came to use the pinctrl > framework. > If we do in the pmc driver then we will need lots of DT processing for > getting information from DT which we can directly get from the pinctrl > core framework. > Also client driver may need to have the control dynamically and get the > IO pads from DT. So implementing all in pmc will be huge duplication > over already existing framework. I don't follow. We already did something similar for the Tegra DPAUX driver [0]. Cheers Jon [0] http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/drivers/gpu/drm/tegra/dpaux.c?id=0751bb5c44fe1aa9494ce259d974c3d249b73a84 -- nvpublic