diff options
| author | Rob Herring <robh@kernel.org> | 2023-03-14 10:41:17 -0500 |
|---|---|---|
| committer | Bartosz Golaszewski <bartosz.golaszewski@linaro.org> | 2023-03-15 10:43:08 +0100 |
| commit | 5b0ad5b24327d44b8307e822d160a3d48a70e87c (patch) | |
| tree | 3044c973e9bfc56f36984792d98999ca6e33c306 /drivers/gpio/gpio-tb10x.c | |
| parent | gpiolib: Get rid of devprop prefix in one function (diff) | |
| download | linux-5b0ad5b24327d44b8307e822d160a3d48a70e87c.tar.gz linux-5b0ad5b24327d44b8307e822d160a3d48a70e87c.zip | |
gpio: Use of_property_read_bool() for boolean properties
It is preferred to use typed property access functions (i.e.
of_property_read_<type> functions) rather than low-level
of_get_property/of_find_property functions for reading properties.
Convert reading boolean properties to to of_property_read_bool().
Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-tb10x.c')
| -rw-r--r-- | drivers/gpio/gpio-tb10x.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-tb10x.c b/drivers/gpio/gpio-tb10x.c index de6afa3f9716..78f8790168ae 100644 --- a/drivers/gpio/gpio-tb10x.c +++ b/drivers/gpio/gpio-tb10x.c @@ -167,7 +167,7 @@ static int tb10x_gpio_probe(struct platform_device *pdev) platform_set_drvdata(pdev, tb10x_gpio); - if (of_find_property(np, "interrupt-controller", NULL)) { + if (of_property_read_bool(np, "interrupt-controller")) { struct irq_chip_generic *gc; ret = platform_get_irq(pdev, 0); |
