aboutsummaryrefslogtreecommitdiff
path: root/arch/s390/lib/test_modules_helpers.c
diff options
context:
space:
mode:
authorKent Gibson <warthog618@gmail.com>2022-07-06 16:45:07 +0800
committerBartosz Golaszewski <brgl@bgdev.pl>2022-07-07 12:18:18 +0200
commitc8e27a4a5136e7230f9e4ffcf132705bf56864cc (patch)
tree76b9c9125ccfb8459b96efd4e84951ac978adc9e /arch/s390/lib/test_modules_helpers.c
parent8af3a0b23818af59971f538bf258c15e1033ea55 (diff)
gpiolib: cdev: fix null pointer dereference in linereq_free()
Fix a kernel NULL pointer dereference reported by gpio kselftests. linereq_free() can be called as part of the cleanup of a failed request, at which time the desc for a line may not have been determined, so it is unsafe to dereference without a check. Add a check prior to dereferencing the line desc. Fixes: 2068339a6c35 ("gpiolib: cdev: Add hardware timestamp clock type") Signed-off-by: Kent Gibson <warthog618@gmail.com> Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Diffstat (limited to 'arch/s390/lib/test_modules_helpers.c')
0 files changed, 0 insertions, 0 deletions