]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
gpiolib: acpi: Fix gpio count with string references
authorAlban Bedel <alban.bedel@lht.dlh.de>
Thu, 29 Jan 2026 14:59:44 +0000 (15:59 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Feb 2026 15:31:34 +0000 (16:31 +0100)
commit6d66464d1a059d92df8a5454d5bc9414f6ec0b03
treeca166639475af61d296da0512083ef64fce62390
parentfa4938e0d0d64a5623629470eefb5547495e7aa6
gpiolib: acpi: Fix gpio count with string references

[ Upstream commit c62e0658d458d8f100445445c3ddb106f3824a45 ]

Since commit 9880702d123f2 ("ACPI: property: Support using strings in
reference properties") it is possible to use strings instead of local
references. This work fine with single GPIO but not with arrays as
acpi_gpio_package_count() didn't handle this case. Update it to handle
strings like local references to cover this case as well.

Signed-off-by: Alban Bedel <alban.bedel@lht.dlh.de>
Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Link: https://patch.msgid.link/20260129145944.3372777-1-alban.bedel@lht.dlh.de
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpio/gpiolib-acpi-core.c