]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
pinctrl: meson: amlogic-a4: fix deadlock issue
authorXianwei Zhao <xianwei.zhao@amlogic.com>
Wed, 22 Apr 2026 11:44:13 +0000 (11:44 +0000)
committerLinus Walleij <linusw@kernel.org>
Tue, 28 Apr 2026 09:50:13 +0000 (11:50 +0200)
commite72ce029810390eb987a036fb2c8a5da9a23b685
tree5396de4f057e0a5abfd17402f40e9c8bd384aa85
parentd743c1ba6c66a7dcb2bfd93fd36b7185e8a4766b
pinctrl: meson: amlogic-a4: fix deadlock issue

Accessing the pinconf-pins sysfs node may deadlock.

pinconf_pins_show() holds pctldev->mutex, and the platform driver
calls pinctrl_find_gpio_range_from_pin(), which tries to acquire
the same mutex again, leading to a deadlock.

Use pinctrl_find_gpio_range_from_pin_nolock() to fix this issue.

Fixes: 6e9be3abb78c ("pinctrl: Add driver support for Amlogic SoCs")
Signed-off-by: Xianwei Zhao <xianwei.zhao@amlogic.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Linus Walleij <linusw@kernel.org>
drivers/pinctrl/meson/pinctrl-amlogic-a4.c