From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752755AbbDEUGC (ORCPT ); Sun, 5 Apr 2015 16:06:02 -0400 Received: from galahad.ideasonboard.com ([185.26.127.97]:37724 "EHLO galahad.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752010AbbDEUGA (ORCPT ); Sun, 5 Apr 2015 16:06:00 -0400 From: Laurent Pinchart To: Geert Uytterhoeven Cc: Geert Uytterhoeven , Greg Kroah-Hartman , Magnus Damm , Arnd Bergmann , Simon Horman , Kuninori Morimoto , Marc Zyngier , driverdevel , Linux-sh list , Linux PM list , "devicetree@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH/RFC 5/6] staging: board: Add support for devices with complex dependencies Date: Sun, 05 Apr 2015 23:06:20 +0300 Message-ID: <2722685.XFRaAHH9GQ@avalon> User-Agent: KMail/4.14.3 (Linux/3.18.7-gentoo; KDE/4.14.3; x86_64; ; ) In-Reply-To: References: <1428064923-24950-1-git-send-email-geert+renesas@glider.be> <34835209.cQQp4PEGGk@avalon> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Geert, On Sunday 05 April 2015 11:00:56 Geert Uytterhoeven wrote: > On Sat, Apr 4, 2015 at 2:46 PM, Laurent Pinchart wrote: > >> + for (i = 0; i < dev->ngpios; i++) > >> + gpio_request_one(dev->gpios[i].gpio, dev->gpios[i].flags, > >> + pdev->name); > > > > Aren't GPIO numbers dynamic too in DT-based systems ? Beside, shouldn't it > > be > > Apparently not, as the old legacy number still works, and it doesn't work > without. I think we're just lucky there that the SoC main GPIO controller gets registered first and starts counting GPIOs with a zero offset. > > the responsibility of the drievr to request the GPIOs it needs ? > > As far as I understand it, on Armadillo this is used more for platform > configuration than for device configuration, as it affects multiple devices > (the comment says DBGMD/LCDC0/FSIA MUX). > > I guess I could use a "gpio-hog" subnode in DT instead, but then we're > already implementing the conversion to DT ;-) But that's the goal :-) I'd rather move GPIO and pinctrl to DT directly as we already have the infrastructure to do so. -- Regards, Laurent Pinchart