Re: [PATCH] gpiolib: Don't return -EPROBE_DEFER to sysfs, or forinvalid gpios

From: Mark Brown
Date: Sat Oct 27 2012 - 17:37:37 EST


On Fri, Oct 26, 2012 at 09:26:33AM +0200, Linus Walleij wrote:
> On Thu, Oct 25, 2012 at 1:03 PM, Mathias Nyman

> > gpios requested with invalid numbers, or gpios requested from userspace via sysfs
> > should not try to be deferred on failure.

> Very good catch. I applied this to my fixes branch and also
> put the stable tag on this thing, it goes way back to the introduction
> of deffered probe.

> Mark: OK with this?

The invalid numbers thing I'm a bit meh on. It came up before and I
personally wasn't sure if the issue wasn't with gpio_is_valid() only
checking for "this number could possibly ever be a GPIO" and not doing
any checking against the GPIOs that have actually been registered. If
it's the former then ideally at some point in the future we'll remove
the big table and gpio_is_valid() will always be true.

Attachment: signature.asc
Description: Digital signature