Re: [PATCH] gpio: Remove impossible checks on container_of() result

2017-01-11 Thread Linus Walleij
On Mon, Jan 9, 2017 at 8:47 PM, Stephen Boyd wrote: > container_of() does pointer math on the pointer that's passed in. > If it were to return a NULL pointer the value passed in would > need to be perfectly offset from 0 to make that so. Remove these > checks because they don't make sense. > > Si

[PATCH] gpio: Remove impossible checks on container_of() result

2017-01-09 Thread Stephen Boyd
container_of() does pointer math on the pointer that's passed in. If it were to return a NULL pointer the value passed in would need to be perfectly offset from 0 to make that so. Remove these checks because they don't make sense. Signed-off-by: Stephen Boyd --- drivers/gpio/gpiolib.c | 4 +---