Re: question on generic gpio interface

2007-04-19 Thread David Brownell
On Thursday 19 April 2007 1:05 am, Francis Moreau wrote: > On 4/17/07, David Brownell <[EMAIL PROTECTED]> wrote: With regards to a userspace interface to GPIOs (rather than to devices such as leds or switches they control): > > In this case I'm not entirely sure how it'd work. I've seen a few >

Re: question on generic gpio interface

2007-04-19 Thread Francis Moreau
On 4/17/07, David Brownell <[EMAIL PROTECTED]> wrote: In this case I'm not entirely sure how it'd work. I've seen a few drivers which let userspace peek and poke at GPIO signals -- like one for Gumstix boards -- but generalizing the model isn't simple. Sub-problems include: - Configuring the r

Re: question on generic gpio interface

2007-04-17 Thread David Brownell
On Tuesday 17 April 2007 12:04 am, Francis Moreau wrote: > BTW, are there any plan to make gpio usable from userspace ? I don't > know if it makes sense but I saw some patches on LKML that did that. Only the usual plan: someone who wants that feature provides a driver, which can be merged after

Re: question on generic gpio interface

2007-04-17 Thread Francis Moreau
On 4/16/07, David Brownell <[EMAIL PROTECTED]> wrote: No, all of those need to be done. (Plus maybe a few more things, I wasn't trying to be exhaustive.) That last point is what makes the other ones take effect ... without it, the top level IRQ will never get dispatched to the GPIO-specific IRQ

Re: question on generic gpio interface

2007-04-16 Thread David Brownell
On Monday 16 April 2007 3:03 am, Francis Moreau wrote: > > Good .. this is more like an IRQ question though. > > ... > > > IRQ logic on that platform must do a few things, like: > > > > - NR_IRQS includes the N interrupts triggered from that chip, > >and their numbers probably fit right som

Re: question on generic gpio interface

2007-04-16 Thread Francis Moreau
Hi David, Thanks for your detailed answer, it helps a lot ! On 4/14/07, David Brownell <[EMAIL PROTECTED]> wrote: On Friday 13 April 2007 1:51 pm, Francis Moreau wrote: > Hi, > > I'm trying to port my old gpio code to the generic one to see if it > can fit my needs. Good .. this is more like a

Re: question on generic gpio interface

2007-04-13 Thread David Brownell
On Friday 13 April 2007 1:51 pm, Francis Moreau wrote: > Hi, > > I'm trying to port my old gpio code to the generic one to see if it > can fit my needs. Good .. this is more like an IRQ question though. > The gpio controller is a home made one and has a really weird > interface. It has several

question on generic gpio interface

2007-04-13 Thread Francis Moreau
Hi, I'm trying to port my old gpio code to the generic one to see if it can fit my needs. The gpio controller is a home made one and has a really weird interface. It has several registers to read the gpio status, to configure gpio directions, or to configure if a gpio can trigger an interrupt an