gpio-button-hotplug: fix probe failed

This commit is contained in:
aiamadeus 2024-01-21 23:20:10 +08:00
parent e0ea643c5b
commit 2843c0b911
2 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@ PKG_LICENSE:=GPL-2.0
include $(INCLUDE_DIR)/package.mk
define KernelPackage/gpio-button-hotplug
SUBMENU:=Other modules
SUBMENU:=GPIO support
TITLE:=Simple GPIO Button Hotplug driver
FILES:=$(PKG_BUILD_DIR)/gpio-button-hotplug.ko
AUTOLOAD:=$(call AutoLoad,30,gpio-button-hotplug,1)

View File

@ -538,7 +538,7 @@ static int gpio_keys_button_probe(struct platform_device *pdev,
struct device_node *child =
of_get_next_child(dev->of_node, prev);
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 3, 0)
bdata->gpiod = devm_fwnode_gpiod_get(dev,
of_fwnode_handle(child), "gpios", GPIOD_IN,
desc);