summaryrefslogtreecommitdiff
path: root/drivers/gpio/gpio-gpio-mm.c
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2016-10-18 14:54:01 (GMT)
committerLinus Walleij <linus.walleij@linaro.org>2016-10-21 12:39:18 (GMT)
commite405f9fcb63602d35f7a419ededa3f952a395a72 (patch)
tree8ccb8cecafdc1b92ddfcdcfe9be26c71e07a45dd /drivers/gpio/gpio-gpio-mm.c
parent0f4bbb233743bdfd51d47688b0bc2561f310488b (diff)
downloadlinux-e405f9fcb63602d35f7a419ededa3f952a395a72.tar.xz
gpio: GPIO_GET_LINEHANDLE_IOCTL: Validate line offset
The line offset that is used as an index into the descs array is provided by userspace and might go beyond the bounds of the array. If that happens undefined behavior will occur. Make sure that the offset is within the bounds of the desc array and reject any requests that specify a value outside of it. Cc: stable@vger.kernel.org Fixes: d7c51b47ac11 ("gpio: userspace ABI for reading/writing GPIO lines") Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-gpio-mm.c')
0 files changed, 0 insertions, 0 deletions