lkml.org 
[lkml]   [2008]   [May]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Latest gpio gumph
David Brownell <david-b@pacbell.net> wrote:
> - an avr32 patch, appended (no response on the avr32 list)

Sorry about the lack of response.

I'm not all that enthusiastic about this patch though...

> From: David Brownell <dbrownell@users.sourceforge.net>
> Subject: AVR32: minor GPIO handling updates
>
> * gpio_direction_output() should disable the pullups just like
> at32_select_gpio(... AT32_GPIOF_OUTPUT) does, for consistency
> between those alternative initialization paths.

But then we need to keep track of whether pullups used to be enabled so
that we can re-enable it in gpio_direction_input(), don't we?

I can't see the harm of keeping the pullup enabled while the port is
configured as output. For consistency, I'd rather honor the pullup flag
in at32_select_gpio() regardless of AT32_GPIOF_OUTPUT.

> * On the odd chance some code uses a pin as a GPIO IRQ without
> calling gpio_request() or gpio_direction_input(), the debug
> dump should still show its pin status.

Hmm. I guess that makes sense, though I would be lying if I said I care
all that much. I think gpiolib is going pretty far to accommodate buggy
drivers that don't call gpio_request() as it is.

Haavard


\
 
 \ /
  Last update: 2008-05-28 10:19    [W:0.039 / U:0.700 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site