]> git.baikalelectronics.ru Git - kernel.git/commit
gpio: simplify gpiochip_export()
authorAlexandre Courbot <acourbot@nvidia.com>
Tue, 22 Jul 2014 07:17:40 +0000 (16:17 +0900)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 23 Jul 2014 15:37:51 +0000 (17:37 +0200)
commitf68ce812d3745df984dc91dcf258268ba85a7177
treef54c02c3344952004a08f1ea3f1913467c5fa357
parentc329b39cf61a10bd1d1c262e9bc8c1a4b59b6afa
gpio: simplify gpiochip_export()

For some reason gpiochip_export() would invalidate all the descriptors
of a chip if exporting it to sysfs failed. This does not appear as
necessary. Remove that part of the code.

While we are at it, add a note about the non-safety of temporarily
releasing a spinlock in the middle of the loop that protects its
iterator, and explain why this is done.

Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpiolib-sysfs.c