diff options
Diffstat (limited to 'target/linux/generic/hack-5.15/800-GPIO-add-named-gpio-exports.patch')
-rw-r--r-- | target/linux/generic/hack-5.15/800-GPIO-add-named-gpio-exports.patch | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/target/linux/generic/hack-5.15/800-GPIO-add-named-gpio-exports.patch b/target/linux/generic/hack-5.15/800-GPIO-add-named-gpio-exports.patch index 76f89acdcd..f24fe9d192 100644 --- a/target/linux/generic/hack-5.15/800-GPIO-add-named-gpio-exports.patch +++ b/target/linux/generic/hack-5.15/800-GPIO-add-named-gpio-exports.patch @@ -15,9 +15,9 @@ Signed-off-by: John Crispin <blogic@openwrt.org> #include "gpiolib.h" #include "gpiolib-of.h" -@@ -1039,3 +1041,72 @@ void of_gpiochip_remove(struct gpio_chip - { - of_node_put(chip->of_node); +@@ -1052,3 +1054,72 @@ void of_gpio_dev_init(struct gpio_chip * + else + gc->of_node = gdev->dev.of_node; } + +#ifdef CONFIG_GPIO_SYSFS @@ -129,7 +129,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> { --- a/drivers/gpio/gpiolib-sysfs.c +++ b/drivers/gpio/gpiolib-sysfs.c -@@ -572,7 +572,7 @@ static struct class gpio_class = { +@@ -561,7 +561,7 @@ static struct class gpio_class = { * * Returns zero on success, else an error. */ @@ -138,7 +138,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> { struct gpio_chip *chip; struct gpio_device *gdev; -@@ -634,6 +634,8 @@ int gpiod_export(struct gpio_desc *desc, +@@ -623,6 +623,8 @@ int gpiod_export(struct gpio_desc *desc, offset = gpio_chip_hwgpio(desc); if (chip->names && chip->names[offset]) ioname = chip->names[offset]; @@ -147,7 +147,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org> dev = device_create_with_groups(&gpio_class, &gdev->dev, MKDEV(0, 0), data, gpio_groups, -@@ -655,6 +657,12 @@ err_unlock: +@@ -644,6 +646,12 @@ err_unlock: gpiod_dbg(desc, "%s: status %d\n", __func__, status); return status; } |