Skip to content

Commit 5539287

Browse files
Doug BergerBartosz Golaszewski
authored andcommitted
gpio: brcmstb: add support for gpio-ranges
A pin controller device mapped with the gpio-ranges property will need implementations of the .request and .free members of the gpiochip. Signed-off-by: Doug Berger <opendmb@gmail.com> Tested-by: Phil Elwell <phil@raspberrypi.com> Acked-by: Florian Fainelli <florian.fainelli@broadcom.com> Link: https://lore.kernel.org/r/20240424185039.1707812-4-opendmb@gmail.com Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
1 parent e818cd3 commit 5539287

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

drivers/gpio/gpio-brcmstb.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -694,6 +694,8 @@ static int brcmstb_gpio_probe(struct platform_device *pdev)
694694
/* not all ngpio lines are valid, will use bank width later */
695695
gc->ngpio = MAX_GPIO_PER_BANK;
696696
gc->offset = bank->id * MAX_GPIO_PER_BANK;
697+
gc->request = gpiochip_generic_request;
698+
gc->free = gpiochip_generic_free;
697699
if (priv->parent_irq > 0)
698700
gc->to_irq = brcmstb_gpio_to_irq;
699701

0 commit comments

Comments
 (0)