From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Subject: Re: [PATCH v2 2/7] ARM: tegra: add gpiod_lookup table for paz00 Date: Fri, 22 Nov 2013 11:40:09 -0700 Message-ID: <528FA509.6080907@wwwdotorg.org> References: <1385122474-14926-1-git-send-email-mika.westerberg@linux.intel.com> <1385122474-14926-3-git-send-email-mika.westerberg@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: Received: from avon.wwwdotorg.org ([70.85.31.133]:58839 "EHLO avon.wwwdotorg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755554Ab3KVSkO (ORCPT ); Fri, 22 Nov 2013 13:40:14 -0500 In-Reply-To: <1385122474-14926-3-git-send-email-mika.westerberg@linux.intel.com> Sender: linux-acpi-owner@vger.kernel.org List-Id: linux-acpi@vger.kernel.org To: Mika Westerberg , linux-acpi@vger.kernel.org, Linus Walleij , Alexandre Courbot Cc: "Rafael J. Wysocki" , Chris Ball , Johannes Berg , Rhyland Klein , Adrian Hunter , Mathias Nyman , Rob Landley , Heikki Krogerus , Thierry Reding , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org On 11/22/2013 05:14 AM, Mika Westerberg wrote: > From: Heikki Krogerus >=20 > This makes it possible to request the gpio descriptors in > rfkill-gpio driver regardless of the platform. Patches 1-3, Tested-by: Stephen Warren All the testing I did was to "cat /sys/kernel/debug/gpios" to make sure those two GPIOs had been correctly acquired by the driver, and that the= y changed state as expected via the command-line "rfkill {un,}block" comm= ands. However, please note that I had to apply a couple fixes to the gpiolib core to get this working: 1) To solve the following build warning: > In file included from arch/arm/mach-tegra/board-paz00.c:21:0: > include/linux/gpio/driver.h:102:17: warning: =91struct of_phandle_arg= s=92 declared inside parameter list [enabled by default] > include/linux/gpio/driver.h:102:17: warning: its scope is only this d= efinition or declaration, which is probably not what you want [enabled = by default] I applied: > diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.= h > index 82eac610ce1a..5133cf29803a 100644 > --- a/include/linux/gpio/driver.h > +++ b/include/linux/gpio/driver.h > @@ -5,6 +5,7 @@ > > struct device; > struct gpio_desc; > +struct of_phandle_args; > struct seq_file; > > /** 2) In order to get the GPIO lookups from the rfkill driver working, I appl= ied: > diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c > index ac53a9593662..b73c39f99858 100644 > --- a/drivers/gpio/gpiolib.c > +++ b/drivers/gpio/gpiolib.c > @@ -2368,7 +2368,7 @@ static struct gpio_desc *gpiod_find(struct devi= ce *dev, const char *con_id, > continue; > } > =20 > - if (chip->ngpio >=3D p->chip_hwnum) { > + if (chip->ngpio <=3D p->chip_hwnum) { > dev_warn(dev, "GPIO chip %s has %d GPIOs\n", > chip->label, chip->ngpio); > continue; -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" i= n the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html