Messages in this thread | | | Date | Thu, 29 Aug 2013 19:45:29 +0200 | Subject | Re: RFC: Bug in error handling in gpiolib.c | From | Linus Walleij <> |
| |
On Tue, Aug 27, 2013 at 9:17 PM, Tim Bird <tbird20d@gmail.com> wrote:
> Hi all, > > There appears to be a bug in the error handling in > drivers/gpi/gpiolib.c In certain error cases > desc_to_gpio() is called to get the gpio number > for an error message, but this may happen on code > paths where desc->chip is NULL. This causes a panic > on my system in gpiod_request(), as follows: (...) > Here's my patch: > Subject: [PATCH] gpio: avoid panic on NULL desc->chip in gpiod_request
Patch applied. Unless we come up with something better, there is some parallel discussion on how to handle NULL descriptors.
Alexandre: OK to apply this?
Yours, Linus Walleij
| |