* [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio
@ 2011-06-15 19:37 Grant Likely
2011-06-15 19:38 ` [PATCH 2/2] gpio/tegra: add devicetree support Grant Likely
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Grant Likely @ 2011-06-15 19:37 UTC (permalink / raw)
To: linux-arm-kernel
As part of the gpio driver consolidation, this patch moves the Tegra driver
into drivers/gpio
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---
If there are no objections, I'll merge this via gpio/next
g.
arch/arm/mach-tegra/Makefile | 1 -
drivers/gpio/Makefile | 1 +
drivers/gpio/gpio-tegra.c | 0
3 files changed, 1 insertions(+), 1 deletions(-)
rename arch/arm/mach-tegra/gpio.c => drivers/gpio/gpio-tegra.c (100%)
diff --git a/arch/arm/mach-tegra/Makefile b/arch/arm/mach-tegra/Makefile
index 823c703..ed58ef9 100644
--- a/arch/arm/mach-tegra/Makefile
+++ b/arch/arm/mach-tegra/Makefile
@@ -4,7 +4,6 @@ obj-y += io.o
obj-y += irq.o
obj-y += clock.o
obj-y += timer.o
-obj-y += gpio.o
obj-y += pinmux.o
obj-y += powergate.o
obj-y += fuse.o
diff --git a/drivers/gpio/Makefile b/drivers/gpio/Makefile
index 68e3bfd..0fbdd75 100644
--- a/drivers/gpio/Makefile
+++ b/drivers/gpio/Makefile
@@ -43,6 +43,7 @@ obj-$(CONFIG_GPIO_SCH) += gpio-sch.o
obj-$(CONFIG_GPIO_STMPE) += gpio-stmpe.o
obj-$(CONFIG_GPIO_SX150X) += gpio-sx150x.o
obj-$(CONFIG_GPIO_TC3589X) += gpio-tc3589x.o
+obj-$(CONFIG_ARCH_TEGRA) += gpio-tegra.o
obj-$(CONFIG_GPIO_TIMBERDALE) += gpio-timberdale.o
obj-$(CONFIG_GPIO_TPS65910) += gpio-tps65910.o
obj-$(CONFIG_GPIO_TWL4030) += gpio-twl4030.o
diff --git a/arch/arm/mach-tegra/gpio.c b/drivers/gpio/gpio-tegra.c
similarity index 100%
rename from arch/arm/mach-tegra/gpio.c
rename to drivers/gpio/gpio-tegra.c
^ permalink raw reply related [flat|nested] 8+ messages in thread* [PATCH 2/2] gpio/tegra: add devicetree support 2011-06-15 19:37 [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Grant Likely @ 2011-06-15 19:38 ` Grant Likely 2011-06-15 20:09 ` Olof Johansson 2011-06-15 20:11 ` [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Olof Johansson 2011-06-15 20:21 ` Colin Cross 2 siblings, 1 reply; 8+ messages in thread From: Grant Likely @ 2011-06-15 19:38 UTC (permalink / raw) To: linux-arm-kernel Add support for decoding gpios from the device tree Signed-off-by: Grant Likely <grant.likely@secretlab.ca> --- .../devicetree/bindings/gpio/gpio_nvidia.txt | 7 +++++++ drivers/gpio/gpio-tegra.c | 10 ++++++++++ 2 files changed, 17 insertions(+), 0 deletions(-) create mode 100644 Documentation/devicetree/bindings/gpio/gpio_nvidia.txt diff --git a/Documentation/devicetree/bindings/gpio/gpio_nvidia.txt b/Documentation/devicetree/bindings/gpio/gpio_nvidia.txt new file mode 100644 index 0000000..afb3ff3 --- /dev/null +++ b/Documentation/devicetree/bindings/gpio/gpio_nvidia.txt @@ -0,0 +1,7 @@ +NVIDIA Tegra 2 GPIO controller + +Required properties: +- compatible : "nvidia,tegra250-gpio" +- #gpio-cells : Should be two. The first cell is the pin number and the + second cell is used to specify optional parameters (currently unused). +- gpio-controller : Marks the device node as a GPIO controller. diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index 919d638..13afb88 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -23,6 +23,7 @@ #include <linux/io.h> #include <linux/gpio.h> +#include <linux/of.h> #include <asm/mach/irq.h> @@ -340,6 +341,15 @@ static int __init tegra_gpio_init(void) } } +#ifdef CONFIG_OF_GPIO + /* + * This isn't ideal, but it gets things hooked up until this + * driver is converted into a platform_device + */ + tegra_gpio_chip.of_node = of_find_compatible_node(NULL, NULL, + "nvidia,tegra250-gpio"); +#endif /* CONFIG_OF_GPIO */ + gpiochip_add(&tegra_gpio_chip); for (i = INT_GPIO_BASE; i < (INT_GPIO_BASE + TEGRA_NR_GPIOS); i++) { ^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 2/2] gpio/tegra: add devicetree support 2011-06-15 19:38 ` [PATCH 2/2] gpio/tegra: add devicetree support Grant Likely @ 2011-06-15 20:09 ` Olof Johansson 0 siblings, 0 replies; 8+ messages in thread From: Olof Johansson @ 2011-06-15 20:09 UTC (permalink / raw) To: linux-arm-kernel On Wed, Jun 15, 2011 at 12:38 PM, Grant Likely <grant.likely@secretlab.ca> wrote: > Add support for decoding gpios from the device tree > > Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: Olof Johansson <olof@lixom.net> ^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio 2011-06-15 19:37 [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Grant Likely 2011-06-15 19:38 ` [PATCH 2/2] gpio/tegra: add devicetree support Grant Likely @ 2011-06-15 20:11 ` Olof Johansson 2011-06-15 20:21 ` Colin Cross 2 siblings, 0 replies; 8+ messages in thread From: Olof Johansson @ 2011-06-15 20:11 UTC (permalink / raw) To: linux-arm-kernel On Wed, Jun 15, 2011 at 12:37 PM, Grant Likely <grant.likely@secretlab.ca> wrote: > As part of the gpio driver consolidation, this patch moves the Tegra driver > into drivers/gpio > > Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: Olof Johansson <olof@lixom.net> Colin said he had plans to do it, or I would already have sent this out. Thanks for doing it! :) -Olof ^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio 2011-06-15 19:37 [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Grant Likely 2011-06-15 19:38 ` [PATCH 2/2] gpio/tegra: add devicetree support Grant Likely 2011-06-15 20:11 ` [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Olof Johansson @ 2011-06-15 20:21 ` Colin Cross 2011-06-15 20:48 ` Grant Likely 2 siblings, 1 reply; 8+ messages in thread From: Colin Cross @ 2011-06-15 20:21 UTC (permalink / raw) To: linux-arm-kernel On Wed, Jun 15, 2011 at 12:37 PM, Grant Likely <grant.likely@secretlab.ca> wrote: > As part of the gpio driver consolidation, this patch moves the Tegra driver > into drivers/gpio > > Signed-off-by: Grant Likely <grant.likely@secretlab.ca> > --- > > If there are no objections, I'll merge this via gpio/next I have this patch as part of a series that should get posted later this week, as well as a patch on top of it that depends on this change and another change in my tree, but I'm pessimistic that my series will get in to 3.1 since it depends on some common consolidation that hasn't been agreed upon yet. So, Acked-by: Colin Cross <ccross@android.com> Put it in gpio/next, and I'll make sure any other Tegra patches with dependencies get pulled after yours. ^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio 2011-06-15 20:21 ` Colin Cross @ 2011-06-15 20:48 ` Grant Likely 2011-06-15 21:00 ` Grant Likely 0 siblings, 1 reply; 8+ messages in thread From: Grant Likely @ 2011-06-15 20:48 UTC (permalink / raw) To: linux-arm-kernel On Wed, Jun 15, 2011 at 2:21 PM, Colin Cross <ccross@android.com> wrote: > On Wed, Jun 15, 2011 at 12:37 PM, Grant Likely > <grant.likely@secretlab.ca> wrote: >> As part of the gpio driver consolidation, this patch moves the Tegra driver >> into drivers/gpio >> >> Signed-off-by: Grant Likely <grant.likely@secretlab.ca> >> --- >> >> If there are no objections, I'll merge this via gpio/next > > I have this patch as part of a series that should get posted later > this week, as well as a patch on top of it that depends on this change > and another change in my tree, but I'm pessimistic that my series will > get in to 3.1 since it depends on some common consolidation that > hasn't been agreed upon yet. ?So, > Acked-by: Colin Cross <ccross@android.com> > > Put it in gpio/next, and I'll make sure any other Tegra patches with > dependencies get pulled after yours. How about I put it in a separate branch so that if you need to pull it for dependencies then you can do so without pulling in all the gpio/next commits. g. -- Grant Likely, B.Sc., P.Eng. Secret Lab Technologies Ltd. ^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio 2011-06-15 20:48 ` Grant Likely @ 2011-06-15 21:00 ` Grant Likely 2011-06-15 21:02 ` Colin Cross 0 siblings, 1 reply; 8+ messages in thread From: Grant Likely @ 2011-06-15 21:00 UTC (permalink / raw) To: linux-arm-kernel On Wed, Jun 15, 2011 at 2:48 PM, Grant Likely <grant.likely@secretlab.ca> wrote: > On Wed, Jun 15, 2011 at 2:21 PM, Colin Cross <ccross@android.com> wrote: >> On Wed, Jun 15, 2011 at 12:37 PM, Grant Likely >> <grant.likely@secretlab.ca> wrote: >>> As part of the gpio driver consolidation, this patch moves the Tegra driver >>> into drivers/gpio >>> >>> Signed-off-by: Grant Likely <grant.likely@secretlab.ca> >>> --- >>> >>> If there are no objections, I'll merge this via gpio/next >> >> I have this patch as part of a series that should get posted later >> this week, as well as a patch on top of it that depends on this change >> and another change in my tree, but I'm pessimistic that my series will >> get in to 3.1 since it depends on some common consolidation that >> hasn't been agreed upon yet. ?So, >> Acked-by: Colin Cross <ccross@android.com> >> >> Put it in gpio/next, and I'll make sure any other Tegra patches with >> dependencies get pulled after yours. > > How about I put it in a separate branch so that if you need to pull it > for dependencies then you can do so without pulling in all the > gpio/next commits. I've pushed it out to the following branch. If everything looks okay to you, then I'll merge it into gpio/next and push it out. The following changes since commit 2c53b436a30867eb6b47dd7bab23ba638d1fb0d2: Linux 3.0-rc3 (2011-06-13 15:29:59 -0700) are available in the git repository at: git://git.secretlab.ca/git/linux-2.6 gpio/next-tegra Grant Likely (2): gpio/tegra: Move Tegra gpio driver to drivers/gpio gpio/tegra: add devicetree support .../devicetree/bindings/gpio/gpio_nvidia.txt | 7 +++++++ arch/arm/mach-tegra/Makefile | 1 - drivers/gpio/Makefile | 1 + .../mach-tegra/gpio.c => drivers/gpio/gpio-tegra.c | 10 ++++++++++ 4 files changed, 18 insertions(+), 1 deletions(-) create mode 100644 Documentation/devicetree/bindings/gpio/gpio_nvidia.txt rename arch/arm/mach-tegra/gpio.c => drivers/gpio/gpio-tegra.c (97%) ^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio 2011-06-15 21:00 ` Grant Likely @ 2011-06-15 21:02 ` Colin Cross 0 siblings, 0 replies; 8+ messages in thread From: Colin Cross @ 2011-06-15 21:02 UTC (permalink / raw) To: linux-arm-kernel On Wed, Jun 15, 2011 at 2:00 PM, Grant Likely <grant.likely@secretlab.ca> wrote: > On Wed, Jun 15, 2011 at 2:48 PM, Grant Likely <grant.likely@secretlab.ca> wrote: >> On Wed, Jun 15, 2011 at 2:21 PM, Colin Cross <ccross@android.com> wrote: >>> On Wed, Jun 15, 2011 at 12:37 PM, Grant Likely >>> <grant.likely@secretlab.ca> wrote: >>>> As part of the gpio driver consolidation, this patch moves the Tegra driver >>>> into drivers/gpio >>>> >>>> Signed-off-by: Grant Likely <grant.likely@secretlab.ca> >>>> --- >>>> >>>> If there are no objections, I'll merge this via gpio/next >>> >>> I have this patch as part of a series that should get posted later >>> this week, as well as a patch on top of it that depends on this change >>> and another change in my tree, but I'm pessimistic that my series will >>> get in to 3.1 since it depends on some common consolidation that >>> hasn't been agreed upon yet. ?So, >>> Acked-by: Colin Cross <ccross@android.com> >>> >>> Put it in gpio/next, and I'll make sure any other Tegra patches with >>> dependencies get pulled after yours. >> >> How about I put it in a separate branch so that if you need to pull it >> for dependencies then you can do so without pulling in all the >> gpio/next commits. > > I've pushed it out to the following branch. ?If everything looks okay > to you, then I'll merge it into gpio/next and push it out. > > The following changes since commit 2c53b436a30867eb6b47dd7bab23ba638d1fb0d2: > > ?Linux 3.0-rc3 (2011-06-13 15:29:59 -0700) > > are available in the git repository at: > ?git://git.secretlab.ca/git/linux-2.6 gpio/next-tegra > > Grant Likely (2): > ? ? ?gpio/tegra: Move Tegra gpio driver to drivers/gpio > ? ? ?gpio/tegra: add devicetree support > > ?.../devicetree/bindings/gpio/gpio_nvidia.txt ? ? ? | ? ?7 +++++++ > ?arch/arm/mach-tegra/Makefile ? ? ? ? ? ? ? ? ? ? ? | ? ?1 - > ?drivers/gpio/Makefile ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ?1 + > ?.../mach-tegra/gpio.c => drivers/gpio/gpio-tegra.c | ? 10 ++++++++++ > ?4 files changed, 18 insertions(+), 1 deletions(-) > ?create mode 100644 Documentation/devicetree/bindings/gpio/gpio_nvidia.txt > ?rename arch/arm/mach-tegra/gpio.c => drivers/gpio/gpio-tegra.c (97%) > Thanks, that sounds good. ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2011-06-15 21:02 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-06-15 19:37 [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Grant Likely 2011-06-15 19:38 ` [PATCH 2/2] gpio/tegra: add devicetree support Grant Likely 2011-06-15 20:09 ` Olof Johansson 2011-06-15 20:11 ` [PATCH 1/2] gpio/tegra: Move Tegra gpio driver to drivers/gpio Olof Johansson 2011-06-15 20:21 ` Colin Cross 2011-06-15 20:48 ` Grant Likely 2011-06-15 21:00 ` Grant Likely 2011-06-15 21:02 ` Colin Cross
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox