Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-06-12 Thread Linus Walleij
On Tue, Jun 11, 2013 at 11:25 PM, Grant Likely grant.lik...@secretlab.ca wrote: On Fri, 26 Apr 2013 16:31:24 -0500, Jon Hunter jon-hun...@ti.com wrote: On 04/26/2013 02:31 AM, Linus Walleij wrote: On Wed, Apr 17, 2013 at 2:41 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote:

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-06-11 Thread Grant Likely
On Fri, 26 Apr 2013 16:31:24 -0500, Jon Hunter jon-hun...@ti.com wrote: On 04/26/2013 02:31 AM, Linus Walleij wrote: On Wed, Apr 17, 2013 at 2:41 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: So: +static int omap_gpio_irq_domain_xlate(struct irq_domain *d, +

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-05-03 Thread Linus Walleij
On Fri, Apr 26, 2013 at 11:25 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/26/2013 02:27 AM, Linus Walleij wrote: You will just have to give the xlate function information about which GPIOs are used as IRQs only, and only request the GPIO on these. That should not be necessary. The xlate is

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-26 Thread Linus Walleij
On Mon, Apr 15, 2013 at 6:58 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/14/2013 02:53 PM, Linus Walleij wrote: This is a pretty hard design pattern to properly replicate in every such driver is it not? Well, instead of adding .request_irq() to the irqchip, and then making each

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-26 Thread Linus Walleij
On Mon, Apr 15, 2013 at 11:40 PM, Jon Hunter jon-hun...@ti.com wrote: I am still concerned about the case where a driver may have already called gpio_request() and then calls request_irq(). I think that the solution needs to handle cases where the driver may or may not call gpio_request() to

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-26 Thread Linus Walleij
On Wed, Apr 17, 2013 at 5:41 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/16/2013 05:14 PM, Jon Hunter wrote: c) I have the feeling that hooking the of_xlate function for this is a bit of an abuse of the function. I was wondering about that. So I was grep'ing through the various

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-26 Thread Linus Walleij
On Wed, Apr 17, 2013 at 2:41 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: So: +static int omap_gpio_irq_domain_xlate(struct irq_domain *d, + struct device_node *ctrlr, + const u32 *intspec, unsigned int

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-26 Thread Jon Hunter
On 04/26/2013 02:27 AM, Linus Walleij wrote: On Wed, Apr 17, 2013 at 5:41 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/16/2013 05:14 PM, Jon Hunter wrote: c) I have the feeling that hooking the of_xlate function for this is a bit of an abuse of the function. I was wondering about

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-26 Thread Jon Hunter
On 04/26/2013 02:31 AM, Linus Walleij wrote: On Wed, Apr 17, 2013 at 2:41 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: So: +static int omap_gpio_irq_domain_xlate(struct irq_domain *d, + struct device_node *ctrlr, +

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-17 Thread Jon Hunter
On 04/17/2013 02:55 AM, Javier Martinez Canillas wrote: ... There are so many patches flying around in this thread that I missed it :-) Sorry about that... No problem. I was trying to see if we could find a common solution that everyone could use as it seems that ideally we should all

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-17 Thread Javier Martinez Canillas
On Wed, Apr 17, 2013 at 3:25 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/17/2013 02:55 AM, Javier Martinez Canillas wrote: ... There are so many patches flying around in this thread that I missed it :-) Sorry about that... No problem. I was trying to see if we could find a common

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-17 Thread Jon Hunter
On 04/17/2013 08:42 AM, Javier Martinez Canillas wrote: On Wed, Apr 17, 2013 at 3:25 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/17/2013 02:55 AM, Javier Martinez Canillas wrote: ... There are so many patches flying around in this thread that I missed it :-) Sorry about that... No

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-17 Thread Javier Martinez Canillas
On Wed, Apr 17, 2013 at 3:52 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/17/2013 08:42 AM, Javier Martinez Canillas wrote: On Wed, Apr 17, 2013 at 3:25 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/17/2013 02:55 AM, Javier Martinez Canillas wrote: ... There are so many patches flying

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-17 Thread Stephen Warren
On 04/16/2013 05:14 PM, Jon Hunter wrote: On 04/16/2013 05:11 PM, Stephen Warren wrote: On 04/16/2013 01:27 PM, Jon Hunter wrote: On 04/16/2013 01:40 PM, Stephen Warren wrote: On 04/15/2013 05:04 PM, Jon Hunter wrote: ... If some driver is calling gpio_request() directly, then they will

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-17 Thread Javier Martinez Canillas
On Wed, Apr 17, 2013 at 3:52 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/17/2013 08:42 AM, Javier Martinez Canillas wrote: On Wed, Apr 17, 2013 at 3:25 PM, Jon Hunter jon-hun...@ti.com wrote: On 04/17/2013 02:55 AM, Javier Martinez Canillas wrote: ... There are so many patches flying

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-16 Thread Jon Hunter
On 04/16/2013 01:40 PM, Stephen Warren wrote: On 04/15/2013 05:04 PM, Jon Hunter wrote: On 04/15/2013 05:16 PM, Stephen Warren wrote: On 04/15/2013 03:40 PM, Jon Hunter wrote: ... mmc { label = pandaboard::status2; gpios = gpio1 8 0; ... }; But that's a gpio-leds instance,

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-16 Thread Jon Hunter
On 04/16/2013 02:27 PM, Jon Hunter wrote: ... Right. In the DT case though, if someone does provide the IRQ and GPIO IDs then at least they would use a different xlate function. Another option to consider would be defining the #interrupt-cells = 3 where we would have ... cell-#1 -- IRQ

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-16 Thread Stephen Warren
On 04/16/2013 01:27 PM, Jon Hunter wrote: On 04/16/2013 01:40 PM, Stephen Warren wrote: On 04/15/2013 05:04 PM, Jon Hunter wrote: ... If some driver is calling gpio_request() directly, then they will most likely just call gpio_to_irq() when requesting the interrupt and so the xlate function

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-16 Thread Jon Hunter
On 04/16/2013 05:11 PM, Stephen Warren wrote: On 04/16/2013 01:27 PM, Jon Hunter wrote: On 04/16/2013 01:40 PM, Stephen Warren wrote: On 04/15/2013 05:04 PM, Jon Hunter wrote: ... If some driver is calling gpio_request() directly, then they will most likely just call gpio_to_irq() when

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-16 Thread Javier Martinez Canillas
On Wed, Apr 17, 2013 at 1:14 AM, Jon Hunter jon-hun...@ti.com wrote: On 04/16/2013 05:11 PM, Stephen Warren wrote: On 04/16/2013 01:27 PM, Jon Hunter wrote: On 04/16/2013 01:40 PM, Stephen Warren wrote: On 04/15/2013 05:04 PM, Jon Hunter wrote: ... If some driver is calling gpio_request()

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-16 Thread Jon Hunter
On 04/16/2013 07:41 PM, Javier Martinez Canillas wrote: On Wed, Apr 17, 2013 at 1:14 AM, Jon Hunter jon-hun...@ti.com wrote: On 04/16/2013 05:11 PM, Stephen Warren wrote: On 04/16/2013 01:27 PM, Jon Hunter wrote: On 04/16/2013 01:40 PM, Stephen Warren wrote: On 04/15/2013 05:04 PM, Jon

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Javier Martinez Canillas
On Sun, Apr 14, 2013 at 10:53 PM, Linus Walleij linus.wall...@linaro.org wrote: On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following inlined patch [1] what you were thinking that would be the right approach? Hi Linus, thanks a lot for

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Stephen Warren
On 04/13/2013 07:35 PM, Javier Martinez Canillas wrote: ... Is the following inlined patch [1] what you were thinking that would be the right approach? ... diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c ... +static int omap_gpio_irq_request(struct irq_data *d) +{ +

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Stephen Warren
On 04/14/2013 02:53 PM, Linus Walleij wrote: On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following inlined patch [1] what you were thinking that would be the right approach? This looks sort of OK, but I'm still struggling with the

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Jon Hunter
On 04/15/2013 11:53 AM, Stephen Warren wrote: On 04/13/2013 07:35 PM, Javier Martinez Canillas wrote: ... Is the following inlined patch [1] what you were thinking that would be the right approach? ... diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c ... +static int

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Jon Hunter
On 04/15/2013 11:58 AM, Stephen Warren wrote: On 04/14/2013 02:53 PM, Linus Walleij wrote: On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following inlined patch [1] what you were thinking that would be the right approach? This looks sort

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Jon Hunter
On 04/15/2013 04:40 PM, Jon Hunter wrote: On 04/15/2013 11:58 AM, Stephen Warren wrote: On 04/14/2013 02:53 PM, Linus Walleij wrote: On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following inlined patch [1] what you were thinking that

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Stephen Warren
On 04/15/2013 03:40 PM, Jon Hunter wrote: On 04/15/2013 11:58 AM, Stephen Warren wrote: On 04/14/2013 02:53 PM, Linus Walleij wrote: On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following inlined patch [1] what you were thinking that

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-15 Thread Jon Hunter
On 04/15/2013 05:16 PM, Stephen Warren wrote: On 04/15/2013 03:40 PM, Jon Hunter wrote: On 04/15/2013 11:58 AM, Stephen Warren wrote: On 04/14/2013 02:53 PM, Linus Walleij wrote: On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-14 Thread Linus Walleij
On Sun, Apr 14, 2013 at 3:35 AM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: Is the following inlined patch [1] what you were thinking that would be the right approach? This looks sort of OK, but I'm still struggling with the question of what we could do to help other

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-13 Thread Javier Martinez Canillas
On Fri, Apr 12, 2013 at 12:47 AM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/11/2013 04:16 PM, Linus Walleij wrote: On Thu, Apr 11, 2013 at 10:30 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 03:28 PM, Linus Walleij wrote: So the only reason I'm rambing on about this

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-11 Thread Stephen Warren
On 04/10/2013 03:28 PM, Linus Walleij wrote: On Wed, Apr 10, 2013 at 10:29 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 12:12 PM, Linus Walleij wrote: If the information is there, whether to convert from IRQ to GPIO or from GPIO to IRQ is a technicality and any order

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-11 Thread Linus Walleij
On Thu, Apr 11, 2013 at 10:30 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 03:28 PM, Linus Walleij wrote: So the only reason I'm rambing on about this is that it breaks the I'm not sure I understand this paragraph; what is it in the line above. If it is this patch, then

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-11 Thread Javier Martinez Canillas
On Fri, Apr 12, 2013 at 12:16 AM, Linus Walleij linus.wall...@linaro.org wrote: On Thu, Apr 11, 2013 at 10:30 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 03:28 PM, Linus Walleij wrote: So the only reason I'm rambing on about this is that it breaks the I'm not sure I

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-11 Thread Stephen Warren
On 04/11/2013 04:16 PM, Linus Walleij wrote: On Thu, Apr 11, 2013 at 10:30 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 03:28 PM, Linus Walleij wrote: So the only reason I'm rambing on about this is that it breaks the I'm not sure I understand this paragraph; what is it

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-11 Thread Stephen Warren
On 04/11/2013 04:16 PM, Linus Walleij wrote: On Thu, Apr 11, 2013 at 10:30 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 03:28 PM, Linus Walleij wrote: So the only reason I'm rambing on about this is that it breaks the I'm not sure I understand this paragraph; what is it

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-10 Thread Linus Walleij
On Fri, Mar 29, 2013 at 6:01 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 03/27/2013 02:55 PM, Linus Walleij wrote: On Wed, Mar 27, 2013 at 5:09 PM, Stephen Warren swar...@wwwdotorg.org wrote: This is the case for some SMSC911x clients like the snowball routing it to a GPIO, whereas I

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-10 Thread Stephen Warren
On 04/10/2013 12:12 PM, Linus Walleij wrote: On Fri, Mar 29, 2013 at 6:01 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 03/27/2013 02:55 PM, Linus Walleij wrote: On Wed, Mar 27, 2013 at 5:09 PM, Stephen Warren swar...@wwwdotorg.org wrote: This is the case for some SMSC911x clients like

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-10 Thread Linus Walleij
On Wed, Apr 10, 2013 at 10:29 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 04/10/2013 12:12 PM, Linus Walleij wrote: If the information is there, whether to convert from IRQ to GPIO or from GPIO to IRQ is a technicality and any order should be feasible in some way? There isn't always

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-04-10 Thread Arnd Bergmann
On Wednesday 10 April 2013 14:29:17 Stephen Warren wrote: If the information is there, whether to convert from IRQ to GPIO or from GPIO to IRQ is a technicality and any order should be feasible in some way? There isn't always a unique 1:1 mapping between GPIOs and IRQs. Put another

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-29 Thread Stephen Warren
On 03/27/2013 02:55 PM, Linus Walleij wrote: On Wed, Mar 27, 2013 at 5:09 PM, Stephen Warren swar...@wwwdotorg.org wrote: It's simply that if a device emits an IRQ, there's no reason to assume that the IRQ is in fact a GPIO. It might be a dedicated IRQ input pin and not something that

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-27 Thread Linus Walleij
On Fri, Mar 22, 2013 at 11:52 PM, Jon Hunter jon-hun...@ti.com wrote: On 03/22/2013 10:33 AM, Stephen Warren wrote: On 03/22/2013 02:10 AM, Linus Walleij wrote: This is just turning everything on it's head. The normal order of things is this sequence for GPIO 14 something like:

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-27 Thread Stephen Warren
On 03/27/2013 07:52 AM, Linus Walleij wrote: On Fri, Mar 22, 2013 at 11:52 PM, Jon Hunter jon-hun...@ti.com wrote: On 03/22/2013 10:33 AM, Stephen Warren wrote: On 03/22/2013 02:10 AM, Linus Walleij wrote: This is just turning everything on it's head. The normal order of things is this

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-27 Thread Linus Walleij
On Wed, Mar 27, 2013 at 5:09 PM, Stephen Warren swar...@wwwdotorg.org wrote: It's simply that if a device emits an IRQ, there's no reason to assume that the IRQ is in fact a GPIO. It might be a dedicated IRQ input pin and not something that gpiolib (or any other GPIO API) knows about. OK

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-22 Thread Stephen Warren
On 03/22/2013 02:10 AM, Linus Walleij wrote: On Fri, Mar 15, 2013 at 12:21 PM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c index 159f5c5..f5feb43 100644 --- a/drivers/gpio/gpio-omap.c +++

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-22 Thread Jon Hunter
On 03/22/2013 10:33 AM, Stephen Warren wrote: On 03/22/2013 02:10 AM, Linus Walleij wrote: On Fri, Mar 15, 2013 at 12:21 PM, Javier Martinez Canillas martinez.jav...@gmail.com wrote: diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c index 159f5c5..f5feb43 100644 ---

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-15 Thread Javier Martinez Canillas
On Fri, Mar 8, 2013 at 12:14 AM, Jon Hunter jon-hun...@ti.com wrote: On 03/02/2013 02:05 PM, Grant Likely wrote: On Tue, 26 Feb 2013 17:01:22 -0600, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-07 Thread Jon Hunter
On 03/02/2013 02:05 PM, Grant Likely wrote: On Tue, 26 Feb 2013 17:01:22 -0600, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: Are you requesting the gpio

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-03-03 Thread Grant Likely
On Tue, 26 Feb 2013 17:01:22 -0600, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: Are you requesting the gpio anywhere? If not then this is not going to

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-28 Thread Javier Martinez Canillas
On Thu, Feb 28, 2013 at 12:16 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 09:57 PM, Javier Martinez Canillas wrote: [snip] Something like that would definitely solve the GPIO request issue but we still have the issue that the current OMAP GPIO controller binding does not support

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-28 Thread Benoit Cousson
+ Jon who was brave enough to take over the OMAP GPIO driver + New email address for Kevin since he is no longer at TI :-(. - Tarun that left TI but I don't have his new email Hi Linus, On 02/28/2013 12:41 AM, Linus Walleij wrote: On Wed, Feb 15, 2012 at 5:04 PM, Benoit Cousson

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-28 Thread Jon Hunter
On 02/28/2013 06:17 AM, Javier Martinez Canillas wrote: On Thu, Feb 28, 2013 at 12:16 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 09:57 PM, Javier Martinez Canillas wrote: [snip] Something like that would definitely solve the GPIO request issue but we still have the issue that

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-28 Thread Linus Walleij
On Thu, Feb 28, 2013 at 2:04 PM, Benoit Cousson b-cous...@ti.com wrote: On 02/28/2013 12:41 AM, Linus Walleij wrote: On Wed, Feb 15, 2012 at 5:04 PM, Benoit Cousson b-cous...@ti.com wrote: Gosh! That's pretty old stuff :-) Hm yeah, haha :-) I didn't notice that someone was replying in the

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-28 Thread Jon Hunter
On 02/28/2013 06:09 PM, Linus Walleij wrote: On Thu, Feb 28, 2013 at 2:04 PM, Benoit Cousson b-cous...@ti.com wrote: On 02/28/2013 12:41 AM, Linus Walleij wrote: On Wed, Feb 15, 2012 at 5:04 PM, Benoit Cousson b-cous...@ti.com wrote: Gosh! That's pretty old stuff :-) Hm yeah, haha :-)

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Stephen Warren
On 02/26/2013 08:33 PM, Javier Martinez Canillas wrote: ... Yes, I realized that requesting the gpio was necessary so what I did is to use the regulator-fixed optional property gpio and define the GPIO used as an IRQ in a regulator used by the SMSC chip. So, I have this on my board DT:

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Stephen Warren
On 02/26/2013 08:57 PM, Javier Martinez Canillas wrote: On Wed, Feb 27, 2013 at 2:07 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 06:13 PM, Stephen Warren wrote: On 02/26/2013 04:45 PM, Jon Hunter wrote: ... One issue I see is that by not calling gpio_request, then potentially you

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Javier Martinez Canillas
On Wed, Feb 27, 2013 at 6:47 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 02/26/2013 08:33 PM, Javier Martinez Canillas wrote: ... Yes, I realized that requesting the gpio was necessary so what I did is to use the regulator-fixed optional property gpio and define the GPIO used as an IRQ

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Javier Martinez Canillas
On Wed, Feb 27, 2013 at 6:50 PM, Stephen Warren swar...@wwwdotorg.org wrote: On 02/26/2013 08:57 PM, Javier Martinez Canillas wrote: On Wed, Feb 27, 2013 at 2:07 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 06:13 PM, Stephen Warren wrote: On 02/26/2013 04:45 PM, Jon Hunter wrote:

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Jon Hunter
On 02/26/2013 09:47 PM, Javier Martinez Canillas wrote: On Wed, Feb 27, 2013 at 12:08 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Jon Hunter
On 02/26/2013 09:57 PM, Javier Martinez Canillas wrote: [snip] Something like that would definitely solve the GPIO request issue but we still have the issue that the current OMAP GPIO controller binding does not support #interrupt-cells = 2. So, we can't pass the trigger type and level

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-27 Thread Linus Walleij
On Wed, Feb 15, 2012 at 5:04 PM, Benoit Cousson b-cous...@ti.com wrote: @@ -52,7 +55,8 @@ struct gpio_bank { struct list_head node; void __iomem *base; u16 irq; - u16 virtual_irq_start; + int irq_base; + struct irq_domain *domain; This seems

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Javier Martinez Canillas
On Fri, Feb 24, 2012 at 4:30 PM, Cousson, Benoit b-cous...@ti.com wrote: On 2/22/2012 7:29 PM, Stephen Warren wrote: Rob Herring wrote at Wednesday, February 22, 2012 10:23 AM: On 02/22/2012 08:31 AM, Cousson, Benoit wrote: On 2/22/2012 3:23 PM, Rob Herring wrote: On 02/15/2012 10:04 AM,

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Stephen Warren
On 02/26/2013 03:01 AM, Javier Martinez Canillas wrote: ... I was wondering if the level/edge settings for gpios is working on OMAP. ... Reading the gpio-omap.txt documentation it says that #interrupt-cells should be 2 and that a value of 8 is active low level-sensitive. So I tried this:

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Jon Hunter
On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for an SMSC911x ethernet chip connected to the GPMC for an OMAP3 SoC based board. In the smsc911x driver probe function

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Stephen Warren
On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for an SMSC911x ethernet chip connected to the GPMC for an OMAP3 SoC based board. In

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Jon Hunter
On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for an SMSC911x ethernet chip connected to

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Stephen Warren
On 02/26/2013 04:01 PM, Jon Hunter wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Jon Hunter
On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for an SMSC911x ethernet chip connected to the GPMC for an OMAP3 SoC based board. In the smsc911x driver probe function

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Jon Hunter
On 02/26/2013 05:06 PM, Stephen Warren wrote: On 02/26/2013 04:01 PM, Jon Hunter wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Stephen Warren
On 02/26/2013 04:45 PM, Jon Hunter wrote: On 02/26/2013 05:06 PM, Stephen Warren wrote: On 02/26/2013 04:01 PM, Jon Hunter wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Jon Hunter
On 02/26/2013 06:13 PM, Stephen Warren wrote: On 02/26/2013 04:45 PM, Jon Hunter wrote: On 02/26/2013 05:06 PM, Stephen Warren wrote: On 02/26/2013 04:01 PM, Jon Hunter wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote: On 02/26/2013 03:40 PM, Jon Hunter wrote: On 02/26/2013 04:01 AM,

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Javier Martinez Canillas
On Tue, Feb 26, 2013 at 11:40 PM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for an SMSC911x ethernet chip connected to the GPMC for an

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Javier Martinez Canillas
On Wed, Feb 27, 2013 at 12:08 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 04:01 AM, Javier Martinez Canillas wrote: [snip] I was wondering if the level/edge settings for gpios is working on OMAP. I'm adding DT support for an SMSC911x ethernet chip connected to the GPMC for an

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2013-02-26 Thread Javier Martinez Canillas
On Wed, Feb 27, 2013 at 2:07 AM, Jon Hunter jon-hun...@ti.com wrote: On 02/26/2013 06:13 PM, Stephen Warren wrote: On 02/26/2013 04:45 PM, Jon Hunter wrote: On 02/26/2013 05:06 PM, Stephen Warren wrote: On 02/26/2013 04:01 PM, Jon Hunter wrote: On 02/26/2013 04:44 PM, Stephen Warren wrote:

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2012-02-22 Thread Rob Herring
On 02/15/2012 10:04 AM, Benoit Cousson wrote: Adapt the GPIO driver to retrieve information from a DT file. Allocate the irq_base dynamically and rename bank-virtual_irq_start to bank-irq_base. Change irq_base type to int instead of u16 to match irq_alloc_descs output. Add documentation

Re: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2012-02-22 Thread Cousson, Benoit
On 2/22/2012 3:23 PM, Rob Herring wrote: On 02/15/2012 10:04 AM, Benoit Cousson wrote: Adapt the GPIO driver to retrieve information from a DT file. Allocate the irq_base dynamically and rename bank-virtual_irq_start to bank-irq_base. Change irq_base type to int instead of u16 to match

RE: [PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2012-02-22 Thread Stephen Warren
Rob Herring wrote at Wednesday, February 22, 2012 10:23 AM: On 02/22/2012 08:31 AM, Cousson, Benoit wrote: On 2/22/2012 3:23 PM, Rob Herring wrote: On 02/15/2012 10:04 AM, Benoit Cousson wrote: Adapt the GPIO driver to retrieve information from a DT file. Allocate the irq_base

[PATCH 3/5] gpio/omap: Add DT support to GPIO driver

2012-02-15 Thread Benoit Cousson
Adapt the GPIO driver to retrieve information from a DT file. Allocate the irq_base dynamically and rename bank-virtual_irq_start to bank-irq_base. Change irq_base type to int instead of u16 to match irq_alloc_descs output. Add documentation for GPIO properties specific to OMAP. Signed-off-by: