gpio: Allow per-parent interrupt data
stable inclusion from stable-v5.10.186 commit 304802e5b038e9e33e1b7fe5f933864e7a8e0ec1 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I8J4KH Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=304802e5b038e9e33e1b7fe5f933864e7a8e0ec1 -------------------------------- [ Upstream commit cfe6807d ] The core gpiolib code is able to deal with multiple interrupt parents for a single gpio irqchip. It however only allows a single piece of data to be conveyed to all flow handlers (either the gpio_chip or some other, driver-specific data). This means that drivers have to go through some interesting dance to find the correct context, something that isn't great in interrupt context (see aebdc8ab for a prime example). Instead, offer an optional way for a pinctrl/gpio driver to provide an array of pointers which gets used to provide the correct context to the flow handler. Signed-off-by:Marc Zyngier <maz@kernel.org> Signed-off-by:
Joey Gouly <joey.gouly@arm.com> Reviewed-by:
Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20211026175815.52703-2-joey.gouly@arm.com Signed-off-by:
Linus Walleij <linus.walleij@linaro.org> Stable-dep-of: 8c00914e ("gpiolib: Fix GPIO chip IRQ initialization restriction") Signed-off-by:
Sasha Levin <sashal@kernel.org> Signed-off-by:
sanglipeng <sanglipeng1@jd.com>
Loading
Please sign in to comment