]> git.baikalelectronics.ru Git - kernel.git/commit
gpio: dln2: Fix interrupts when replugging the device
authorNoralf Trønnes <noralf@tronnes.org>
Mon, 18 Oct 2021 11:22:01 +0000 (13:22 +0200)
committerBartosz Golaszewski <brgl@bgdev.pl>
Sun, 19 Dec 2021 14:03:30 +0000 (15:03 +0100)
commit036cfa8d557f1647df71165b6019f97f091c3ad7
tree603d3a147e4a7e6b7d1a92d5e81506cc466e77fb
parentbdbce92ac825631560e178be1343c0913079f17a
gpio: dln2: Fix interrupts when replugging the device

When replugging the device the following message shows up:

gpio gpiochip2: (dln2): detected irqchip that is shared with multiple gpiochips: please fix the driver.

This also has the effect that interrupts won't work.
The same problem would also show up if multiple devices where plugged in.

Fix this by allocating the irq_chip data structure per instance like other
drivers do.

I don't know when this problem appeared, but it is present in 5.10.

Cc: <stable@vger.kernel.org> # 5.10+
Cc: Daniel Baluta <daniel.baluta@gmail.com>
Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
drivers/gpio/gpio-dln2.c