Merge tag 'gpio-fixes-for-v6.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux

Pull gpio fixes from Bartosz Golaszewski:

- fix interrupt handling in suspend and wakeup in gpio-vf610

- fix a bug on setting direction to output in gpio-vf610

- add a missing memset() in gpio ACPI code

* tag 'gpio-fixes-for-v6.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
gpiolib: acpi: Add missing memset(0) to acpi_get_gpiod_from_data()
gpio: vf610: set value before the direction to avoid a glitch
gpio: vf610: mask the gpio irq in system suspend and support wakeup

+5 -3
+4 -3
drivers/gpio/gpio-vf610.c
··· 126 unsigned long mask = BIT(gpio); 127 u32 val; 128 129 if (port->sdata && port->sdata->have_paddr) { 130 val = vf610_gpio_readl(port->gpio_base + GPIO_PDDR); 131 val |= mask; 132 vf610_gpio_writel(val, port->gpio_base + GPIO_PDDR); 133 } 134 - 135 - vf610_gpio_set(chip, gpio, value); 136 137 return pinctrl_gpio_direction_output(chip->base + gpio); 138 } ··· 246 .irq_unmask = vf610_gpio_irq_unmask, 247 .irq_set_type = vf610_gpio_irq_set_type, 248 .irq_set_wake = vf610_gpio_irq_set_wake, 249 - .flags = IRQCHIP_IMMUTABLE, 250 GPIOCHIP_IRQ_RESOURCE_HELPERS, 251 }; 252
··· 126 unsigned long mask = BIT(gpio); 127 u32 val; 128 129 + vf610_gpio_set(chip, gpio, value); 130 + 131 if (port->sdata && port->sdata->have_paddr) { 132 val = vf610_gpio_readl(port->gpio_base + GPIO_PDDR); 133 val |= mask; 134 vf610_gpio_writel(val, port->gpio_base + GPIO_PDDR); 135 } 136 137 return pinctrl_gpio_direction_output(chip->base + gpio); 138 } ··· 246 .irq_unmask = vf610_gpio_irq_unmask, 247 .irq_set_type = vf610_gpio_irq_set_type, 248 .irq_set_wake = vf610_gpio_irq_set_wake, 249 + .flags = IRQCHIP_IMMUTABLE | IRQCHIP_MASK_ON_SUSPEND 250 + | IRQCHIP_ENABLE_WAKEUP_ON_SUSPEND, 251 GPIOCHIP_IRQ_RESOURCE_HELPERS, 252 }; 253
+1
drivers/gpio/gpiolib-acpi.c
··· 951 if (!propname) 952 return ERR_PTR(-EINVAL); 953 954 lookup.index = index; 955 956 ret = acpi_gpio_property_lookup(fwnode, propname, index, &lookup);
··· 951 if (!propname) 952 return ERR_PTR(-EINVAL); 953 954 + memset(&lookup, 0, sizeof(lookup)); 955 lookup.index = index; 956 957 ret = acpi_gpio_property_lookup(fwnode, propname, index, &lookup);