Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-15 Thread Linus Walleij
On Thu, Feb 14, 2013 at 1:22 PM, Lars Poeschel wrote: > On Wednesday 13 February 2013 at 13:51:12, Linus Walleij wrote: >> Have you considered this [pinctrl] approach? > > No, I haven't. And although this doesn't solve all my problems, I like the > idea very much! Thank you for this! But at the

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-15 Thread Linus Walleij
On Thu, Feb 14, 2013 at 1:22 PM, Lars Poeschel poesc...@lemonage.de wrote: On Wednesday 13 February 2013 at 13:51:12, Linus Walleij wrote: Have you considered this [pinctrl] approach? No, I haven't. And although this doesn't solve all my problems, I like the idea very much! Thank you for

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-14 Thread Lars Poeschel
On Wednesday 13 February 2013 at 13:51:12, Linus Walleij wrote: > On Wed, Feb 13, 2013 at 12:13 PM, Lars Poeschel wrote: > > On Monday 11 February 2013 at 22:25:51, Grant Likely wrote: > >> However, is the pullup selection per-gpio line? If so, then why not > >> encode it into the flags field of

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-14 Thread Lars Poeschel
On Wednesday 13 February 2013 at 13:51:12, Linus Walleij wrote: On Wed, Feb 13, 2013 at 12:13 PM, Lars Poeschel poesc...@lemonage.de wrote: On Monday 11 February 2013 at 22:25:51, Grant Likely wrote: However, is the pullup selection per-gpio line? If so, then why not encode it into the

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-13 Thread Linus Walleij
On Wed, Feb 13, 2013 at 12:13 PM, Lars Poeschel wrote: > On Monday 11 February 2013 at 22:25:51, Grant Likely wrote: >> >> However, is the pullup selection per-gpio line? If so, then why not >> encode it into the flags field of the gpio specifier? > > Yes, the pullup is per-gpio line. I am

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-13 Thread Lars Poeschel
On Monday 11 February 2013 at 22:25:51, Grant Likely wrote: > On Mon, 11 Feb 2013 12:52:42 +0100, Lars Poeschel wrote: > > +Optional device specific properties: > > +- mcp,chips : This is a table with 2 columns and up to 8 entries. The > > first column + is a is_present flag, that makes

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-13 Thread Lars Poeschel
On Monday 11 February 2013 at 22:25:51, Grant Likely wrote: On Mon, 11 Feb 2013 12:52:42 +0100, Lars Poeschel la...@wh2.tu-dresden.de wrote: +Optional device specific properties: +- mcp,chips : This is a table with 2 columns and up to 8 entries. The first column + is a is_present

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-13 Thread Linus Walleij
On Wed, Feb 13, 2013 at 12:13 PM, Lars Poeschel poesc...@lemonage.de wrote: On Monday 11 February 2013 at 22:25:51, Grant Likely wrote: However, is the pullup selection per-gpio line? If so, then why not encode it into the flags field of the gpio specifier? Yes, the pullup is per-gpio line.

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-11 Thread Grant Likely
On Mon, 11 Feb 2013 12:52:42 +0100, Lars Poeschel wrote: > From: Lars Poeschel > > This converts the mcp23s08 driver to be able to be used with device > tree. > Explicitly allow -1 as a legal value for the > mcp23s08_platform_data->base. This is the special value lets the > kernel choose a

[PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-11 Thread Lars Poeschel
From: Lars Poeschel This converts the mcp23s08 driver to be able to be used with device tree. Explicitly allow -1 as a legal value for the mcp23s08_platform_data->base. This is the special value lets the kernel choose a valid global gpio base number. There is a "mcp,chips" device tree property,

[PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-11 Thread Lars Poeschel
From: Lars Poeschel poesc...@lemonage.de This converts the mcp23s08 driver to be able to be used with device tree. Explicitly allow -1 as a legal value for the mcp23s08_platform_data-base. This is the special value lets the kernel choose a valid global gpio base number. There is a mcp,chips

Re: [PATCH v2] gpio: mcp23s08: convert driver to DT

2013-02-11 Thread Grant Likely
On Mon, 11 Feb 2013 12:52:42 +0100, Lars Poeschel la...@wh2.tu-dresden.de wrote: From: Lars Poeschel poesc...@lemonage.de This converts the mcp23s08 driver to be able to be used with device tree. Explicitly allow -1 as a legal value for the mcp23s08_platform_data-base. This is the special