All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] gpio: cdev: label sanitization fixes
@ 2024-04-03 13:15 Kent Gibson
  2024-04-03 13:15 ` [PATCH 1/2] gpio: cdev: fix missed label sanitizing in debounce_setup() Kent Gibson
  2024-04-03 13:15 ` [PATCH 2/2] gpio: cdev: check for NULL labels when sanitizing them for irqs Kent Gibson
  0 siblings, 2 replies; 6+ messages in thread
From: Kent Gibson @ 2024-04-03 13:15 UTC (permalink / raw)
  To: linux-kernel, linux-gpio, brgl, linus.walleij; +Cc: Kent Gibson

This series fixes a couple of bugs in the sanitization of labels
being passed to irq.

Patch 1 fixes a missed path in the sanitization changes that can result
in memory corruption.

Patch 2 fixes the case where userspace provides empty labels.

I've placed my Patch 1 before Bart's Patch 2 as it has to relocate
make_irq_label() and free_irq_label(), while Bart's patch modifies
them. This order keeps the patch sizes minimal and the attribution
where it belongs.  Patch 2 has been very lightly modified to rebase it
onto Patch 1, including extending it to cover the modified error
return for the debounce_setup() case.

Cheers,
Kent.

Bartosz Golaszewski (1):
  gpio: cdev: check for NULL labels when sanitizing them for irqs

Kent Gibson (1):
  gpio: cdev: fix missed label sanitizing in debounce_setup()

 drivers/gpio/gpiolib-cdev.c | 48 ++++++++++++++++++++++++-------------
 1 file changed, 32 insertions(+), 16 deletions(-)


base-commit: 782f4e47ffc19622bf80b3c0cf9cadd2b0b9a644
-- 
2.39.2


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-04-04 12:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-03 13:15 [PATCH 0/2] gpio: cdev: label sanitization fixes Kent Gibson
2024-04-03 13:15 ` [PATCH 1/2] gpio: cdev: fix missed label sanitizing in debounce_setup() Kent Gibson
2024-04-04  8:20   ` Bartosz Golaszewski
2024-04-04 10:59     ` Kent Gibson
2024-04-04 12:20       ` Bartosz Golaszewski
2024-04-03 13:15 ` [PATCH 2/2] gpio: cdev: check for NULL labels when sanitizing them for irqs Kent Gibson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.