diff options
| author | Andy Shevchenko <[email protected]> | 2022-08-30 18:33:10 +0000 |
|---|---|---|
| committer | Lorenzo Pieralisi <[email protected]> | 2022-10-03 08:34:46 +0000 |
| commit | 0dbc45241dc3f8d51957d4c770c16e49387cd6c2 (patch) | |
| tree | 7d9bf82afe705ec9861c6ba9ea743704a9159250 /drivers/pci/controller/dwc | |
| parent | PCI: dwc: Drop dependency on ZONE_DMA32 (diff) | |
| download | kernel-0dbc45241dc3f8d51957d4c770c16e49387cd6c2.tar.gz kernel-0dbc45241dc3f8d51957d4c770c16e49387cd6c2.zip | |
PCI: dwc: Replace of_gpio_named_count() by gpiod_count()
As a preparation to unexport of_gpio_named_count(), convert the
driver to use gpiod_count() instead.
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Andy Shevchenko <[email protected]>
Signed-off-by: Lorenzo Pieralisi <[email protected]>
Acked-by: Rob Herring <[email protected]>
Diffstat (limited to 'drivers/pci/controller/dwc')
| -rw-r--r-- | drivers/pci/controller/dwc/pcie-kirin.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/controller/dwc/pcie-kirin.c b/drivers/pci/controller/dwc/pcie-kirin.c index 7f67aad71df4..d09507f822a7 100644 --- a/drivers/pci/controller/dwc/pcie-kirin.c +++ b/drivers/pci/controller/dwc/pcie-kirin.c @@ -13,6 +13,7 @@ #include <linux/delay.h> #include <linux/err.h> #include <linux/gpio.h> +#include <linux/gpio/consumer.h> #include <linux/interrupt.h> #include <linux/mfd/syscon.h> #include <linux/of_address.h> @@ -366,12 +367,11 @@ static int kirin_pcie_get_gpio_enable(struct kirin_pcie *pcie, struct platform_device *pdev) { struct device *dev = &pdev->dev; - struct device_node *np = dev->of_node; char name[32]; int ret, i; /* This is an optional property */ - ret = of_gpio_named_count(np, "hisilicon,clken-gpios"); + ret = gpiod_count(dev, "hisilicon,clken"); if (ret < 0) return 0; |
