From: Rosen Penev Date: Wed, 15 Jul 2026 23:05:38 +0000 (-0700) Subject: gpio-button-hotplug: enable get_devtree_pdata everywhere X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aa09799aa22dcdc35b3282c9b3e055a9099eab8a;p=thirdparty%2Fopenwrt.git gpio-button-hotplug: enable get_devtree_pdata everywhere Upstream prefers fwnode helpers instead of OF ones (already done). This is important for software nodes, which upstream is migrating to for its non OF devices. Signed-off-by: Rosen Penev Link: https://github.com/openwrt/openwrt/pull/24348 Signed-off-by: Jonas Jelonek --- diff --git a/package/kernel/gpio-button-hotplug/Makefile b/package/kernel/gpio-button-hotplug/Makefile index caa3dce01e2..a69da412819 100644 --- a/package/kernel/gpio-button-hotplug/Makefile +++ b/package/kernel/gpio-button-hotplug/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=gpio-button-hotplug -PKG_RELEASE:=5 +PKG_RELEASE:=6 PKG_LICENSE:=GPL-2.0 include $(INCLUDE_DIR)/package.mk diff --git a/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c b/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c index 916411fb8b1..307827363f4 100644 --- a/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c +++ b/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c @@ -359,7 +359,6 @@ static irqreturn_t button_handle_irq(int irq, void *_bdata) return IRQ_HANDLED; } -#ifdef CONFIG_OF static struct gpio_keys_platform_data * gpio_keys_get_devtree_pdata(struct device *dev) { @@ -430,15 +429,6 @@ static const struct of_device_id gpio_keys_polled_of_match[] = { }; MODULE_DEVICE_TABLE(of, gpio_keys_polled_of_match); -#else - -static inline struct gpio_keys_platform_data * -gpio_keys_get_devtree_pdata(struct device *dev) -{ - return NULL; -} -#endif - static int gpio_keys_button_probe(struct platform_device *pdev, struct gpio_keys_button_dev **_bdev, int polled) {