1 // SPDX-License-Identifier: GPL-2.0
3 * PCIe host controller driver for Kirin Phone SoCs
5 * Copyright (C) 2017 HiSilicon Electronics Co., Ltd.
6 * https://www.huawei.com
8 * Author: Xiaowei Song <songxiaowei@huawei.com>
11 #include <linux/clk.h>
12 #include <linux/compiler.h>
13 #include <linux/delay.h>
14 #include <linux/err.h>
15 #include <linux/gpio.h>
16 #include <linux/gpio/consumer.h>
17 #include <linux/interrupt.h>
18 #include <linux/mfd/syscon.h>
20 #include <linux/of_gpio.h>
21 #include <linux/of_pci.h>
22 #include <linux/phy/phy.h>
23 #include <linux/pci.h>
24 #include <linux/pci_regs.h>
25 #include <linux/platform_device.h>
26 #include <linux/regmap.h>
27 #include <linux/resource.h>
28 #include <linux/types.h>
29 #include "pcie-designware.h"
31 #define to_kirin_pcie(x) dev_get_drvdata((x)->dev)
33 /* PCIe ELBI registers */
34 #define SOC_PCIECTRL_CTRL0_ADDR 0x000
35 #define SOC_PCIECTRL_CTRL1_ADDR 0x004
36 #define PCIE_ELBI_SLV_DBI_ENABLE (0x1 << 21)
38 /* info located in APB */
39 #define PCIE_APP_LTSSM_ENABLE 0x01c
40 #define PCIE_APB_PHY_STATUS0 0x400
41 #define PCIE_LINKUP_ENABLE (0x8020)
42 #define PCIE_LTSSM_ENABLE_BIT (0x1 << 11)
44 /* info located in sysctrl */
45 #define SCTRL_PCIE_CMOS_OFFSET 0x60
46 #define SCTRL_PCIE_CMOS_BIT 0x10
47 #define SCTRL_PCIE_ISO_OFFSET 0x44
48 #define SCTRL_PCIE_ISO_BIT 0x30
49 #define SCTRL_PCIE_HPCLK_OFFSET 0x190
50 #define SCTRL_PCIE_HPCLK_BIT 0x184000
51 #define SCTRL_PCIE_OE_OFFSET 0x14a
52 #define PCIE_DEBOUNCE_PARAM 0xF0F400
53 #define PCIE_OE_BYPASS (0x3 << 28)
56 * Max number of connected PCI slots at an external PCI bridge
58 * This is used on HiKey 970, which has a PEX 8606 bridge with 4 connected
59 * lanes (lane 0 upstream, and the other three lanes, one connected to an
60 * in-board Ethernet adapter and the other two connected to M.2 and mini
63 * Each slot has a different clock source and uses a separate PERST# pin.
65 #define MAX_PCI_SLOTS 3
67 enum pcie_kirin_phy_type {
68 PCIE_KIRIN_INTERNAL_PHY,
69 PCIE_KIRIN_EXTERNAL_PHY
73 enum pcie_kirin_phy_type type;
78 void *phy_priv; /* only for PCIE_KIRIN_INTERNAL_PHY */
81 int gpio_id_dwc_perst;
85 int gpio_id_reset[MAX_PCI_SLOTS];
86 const char *reset_names[MAX_PCI_SLOTS];
90 int gpio_id_clkreq[MAX_PCI_SLOTS];
91 const char *clkreq_names[MAX_PCI_SLOTS];
95 * Kirin 960 PHY. Can't be split into a PHY driver without changing the
99 #define REF_CLK_FREQ 100000000
101 /* PHY info located in APB */
102 #define PCIE_APB_PHY_CTRL0 0x0
103 #define PCIE_APB_PHY_CTRL1 0x4
104 #define PCIE_APB_PHY_STATUS0 0x400
105 #define PIPE_CLK_STABLE BIT(19)
106 #define PHY_REF_PAD_BIT BIT(8)
107 #define PHY_PWR_DOWN_BIT BIT(22)
108 #define PHY_RST_ACK_BIT BIT(16)
111 #define CRGCTRL_PCIE_ASSERT_OFFSET 0x88
112 #define CRGCTRL_PCIE_ASSERT_BIT 0x8c000000
115 #define REF_2_PERST_MIN 21000
116 #define REF_2_PERST_MAX 25000
117 #define PERST_2_ACCESS_MIN 10000
118 #define PERST_2_ACCESS_MAX 12000
119 #define PIPE_CLK_WAIT_MIN 550
120 #define PIPE_CLK_WAIT_MAX 600
121 #define TIME_CMOS_MIN 100
122 #define TIME_CMOS_MAX 105
123 #define TIME_PHY_PD_MIN 10
124 #define TIME_PHY_PD_MAX 11
126 struct hi3660_pcie_phy {
129 struct regmap *crgctrl;
130 struct regmap *sysctrl;
131 struct clk *apb_sys_clk;
132 struct clk *apb_phy_clk;
133 struct clk *phy_ref_clk;
138 /* Registers in PCIePHY */
139 static inline void kirin_apb_phy_writel(struct hi3660_pcie_phy *hi3660_pcie_phy,
142 writel(val, hi3660_pcie_phy->base + reg);
145 static inline u32 kirin_apb_phy_readl(struct hi3660_pcie_phy *hi3660_pcie_phy,
148 return readl(hi3660_pcie_phy->base + reg);
151 static int hi3660_pcie_phy_get_clk(struct hi3660_pcie_phy *phy)
153 struct device *dev = phy->dev;
155 phy->phy_ref_clk = devm_clk_get(dev, "pcie_phy_ref");
156 if (IS_ERR(phy->phy_ref_clk))
157 return PTR_ERR(phy->phy_ref_clk);
159 phy->aux_clk = devm_clk_get(dev, "pcie_aux");
160 if (IS_ERR(phy->aux_clk))
161 return PTR_ERR(phy->aux_clk);
163 phy->apb_phy_clk = devm_clk_get(dev, "pcie_apb_phy");
164 if (IS_ERR(phy->apb_phy_clk))
165 return PTR_ERR(phy->apb_phy_clk);
167 phy->apb_sys_clk = devm_clk_get(dev, "pcie_apb_sys");
168 if (IS_ERR(phy->apb_sys_clk))
169 return PTR_ERR(phy->apb_sys_clk);
171 phy->aclk = devm_clk_get(dev, "pcie_aclk");
172 if (IS_ERR(phy->aclk))
173 return PTR_ERR(phy->aclk);
178 static int hi3660_pcie_phy_get_resource(struct hi3660_pcie_phy *phy)
180 struct device *dev = phy->dev;
181 struct platform_device *pdev;
184 pdev = container_of(dev, struct platform_device, dev);
186 phy->base = devm_platform_ioremap_resource_byname(pdev, "phy");
187 if (IS_ERR(phy->base))
188 return PTR_ERR(phy->base);
190 phy->crgctrl = syscon_regmap_lookup_by_compatible("hisilicon,hi3660-crgctrl");
191 if (IS_ERR(phy->crgctrl))
192 return PTR_ERR(phy->crgctrl);
194 phy->sysctrl = syscon_regmap_lookup_by_compatible("hisilicon,hi3660-sctrl");
195 if (IS_ERR(phy->sysctrl))
196 return PTR_ERR(phy->sysctrl);
201 static int hi3660_pcie_phy_start(struct hi3660_pcie_phy *phy)
203 struct device *dev = phy->dev;
206 reg_val = kirin_apb_phy_readl(phy, PCIE_APB_PHY_CTRL1);
207 reg_val &= ~PHY_REF_PAD_BIT;
208 kirin_apb_phy_writel(phy, reg_val, PCIE_APB_PHY_CTRL1);
210 reg_val = kirin_apb_phy_readl(phy, PCIE_APB_PHY_CTRL0);
211 reg_val &= ~PHY_PWR_DOWN_BIT;
212 kirin_apb_phy_writel(phy, reg_val, PCIE_APB_PHY_CTRL0);
213 usleep_range(TIME_PHY_PD_MIN, TIME_PHY_PD_MAX);
215 reg_val = kirin_apb_phy_readl(phy, PCIE_APB_PHY_CTRL1);
216 reg_val &= ~PHY_RST_ACK_BIT;
217 kirin_apb_phy_writel(phy, reg_val, PCIE_APB_PHY_CTRL1);
219 usleep_range(PIPE_CLK_WAIT_MIN, PIPE_CLK_WAIT_MAX);
220 reg_val = kirin_apb_phy_readl(phy, PCIE_APB_PHY_STATUS0);
221 if (reg_val & PIPE_CLK_STABLE) {
222 dev_err(dev, "PIPE clk is not stable\n");
229 static void hi3660_pcie_phy_oe_enable(struct hi3660_pcie_phy *phy)
233 regmap_read(phy->sysctrl, SCTRL_PCIE_OE_OFFSET, &val);
234 val |= PCIE_DEBOUNCE_PARAM;
235 val &= ~PCIE_OE_BYPASS;
236 regmap_write(phy->sysctrl, SCTRL_PCIE_OE_OFFSET, val);
239 static int hi3660_pcie_phy_clk_ctrl(struct hi3660_pcie_phy *phy, bool enable)
246 ret = clk_set_rate(phy->phy_ref_clk, REF_CLK_FREQ);
250 ret = clk_prepare_enable(phy->phy_ref_clk);
254 ret = clk_prepare_enable(phy->apb_sys_clk);
258 ret = clk_prepare_enable(phy->apb_phy_clk);
262 ret = clk_prepare_enable(phy->aclk);
266 ret = clk_prepare_enable(phy->aux_clk);
273 clk_disable_unprepare(phy->aux_clk);
275 clk_disable_unprepare(phy->aclk);
277 clk_disable_unprepare(phy->apb_phy_clk);
279 clk_disable_unprepare(phy->apb_sys_clk);
281 clk_disable_unprepare(phy->phy_ref_clk);
286 static int hi3660_pcie_phy_power_on(struct kirin_pcie *pcie)
288 struct hi3660_pcie_phy *phy = pcie->phy_priv;
291 /* Power supply for Host */
292 regmap_write(phy->sysctrl,
293 SCTRL_PCIE_CMOS_OFFSET, SCTRL_PCIE_CMOS_BIT);
294 usleep_range(TIME_CMOS_MIN, TIME_CMOS_MAX);
296 hi3660_pcie_phy_oe_enable(phy);
298 ret = hi3660_pcie_phy_clk_ctrl(phy, true);
302 /* ISO disable, PCIeCtrl, PHY assert and clk gate clear */
303 regmap_write(phy->sysctrl,
304 SCTRL_PCIE_ISO_OFFSET, SCTRL_PCIE_ISO_BIT);
305 regmap_write(phy->crgctrl,
306 CRGCTRL_PCIE_ASSERT_OFFSET, CRGCTRL_PCIE_ASSERT_BIT);
307 regmap_write(phy->sysctrl,
308 SCTRL_PCIE_HPCLK_OFFSET, SCTRL_PCIE_HPCLK_BIT);
310 ret = hi3660_pcie_phy_start(phy);
317 hi3660_pcie_phy_clk_ctrl(phy, false);
321 static int hi3660_pcie_phy_init(struct platform_device *pdev,
322 struct kirin_pcie *pcie)
324 struct device *dev = &pdev->dev;
325 struct hi3660_pcie_phy *phy;
328 phy = devm_kzalloc(dev, sizeof(*phy), GFP_KERNEL);
332 pcie->phy_priv = phy;
335 ret = hi3660_pcie_phy_get_clk(phy);
339 return hi3660_pcie_phy_get_resource(phy);
342 static int hi3660_pcie_phy_power_off(struct kirin_pcie *pcie)
344 struct hi3660_pcie_phy *phy = pcie->phy_priv;
346 /* Drop power supply for Host */
347 regmap_write(phy->sysctrl, SCTRL_PCIE_CMOS_OFFSET, 0x00);
349 hi3660_pcie_phy_clk_ctrl(phy, false);
355 * The non-PHY part starts here
358 static const struct regmap_config pcie_kirin_regmap_conf = {
359 .name = "kirin_pcie_apb",
365 static int kirin_pcie_get_gpio_enable(struct kirin_pcie *pcie,
366 struct platform_device *pdev)
368 struct device *dev = &pdev->dev;
372 /* This is an optional property */
373 ret = gpiod_count(dev, "hisilicon,clken");
377 if (ret > MAX_PCI_SLOTS) {
378 dev_err(dev, "Too many GPIO clock requests!\n");
382 pcie->n_gpio_clkreq = ret;
384 for (i = 0; i < pcie->n_gpio_clkreq; i++) {
385 pcie->gpio_id_clkreq[i] = of_get_named_gpio(dev->of_node,
386 "hisilicon,clken-gpios", i);
387 if (pcie->gpio_id_clkreq[i] < 0)
388 return pcie->gpio_id_clkreq[i];
390 sprintf(name, "pcie_clkreq_%d", i);
391 pcie->clkreq_names[i] = devm_kstrdup_const(dev, name,
393 if (!pcie->clkreq_names[i])
400 static int kirin_pcie_parse_port(struct kirin_pcie *pcie,
401 struct platform_device *pdev,
402 struct device_node *node)
404 struct device *dev = &pdev->dev;
405 struct device_node *parent, *child;
409 for_each_available_child_of_node(node, parent) {
410 for_each_available_child_of_node(parent, child) {
413 pcie->gpio_id_reset[i] = of_get_named_gpio(child,
415 if (pcie->gpio_id_reset[i] < 0)
419 if (pcie->num_slots > MAX_PCI_SLOTS) {
420 dev_err(dev, "Too many PCI slots!\n");
425 ret = of_pci_get_devfn(child);
427 dev_err(dev, "failed to parse devfn: %d\n", ret);
431 slot = PCI_SLOT(ret);
433 sprintf(name, "pcie_perst_%d", slot);
434 pcie->reset_names[i] = devm_kstrdup_const(dev, name,
436 if (!pcie->reset_names[i]) {
451 static long kirin_pcie_get_resource(struct kirin_pcie *kirin_pcie,
452 struct platform_device *pdev)
454 struct device *dev = &pdev->dev;
455 struct device_node *child, *node = dev->of_node;
456 void __iomem *apb_base;
459 apb_base = devm_platform_ioremap_resource_byname(pdev, "apb");
460 if (IS_ERR(apb_base))
461 return PTR_ERR(apb_base);
463 kirin_pcie->apb = devm_regmap_init_mmio(dev, apb_base,
464 &pcie_kirin_regmap_conf);
465 if (IS_ERR(kirin_pcie->apb))
466 return PTR_ERR(kirin_pcie->apb);
468 /* pcie internal PERST# gpio */
469 kirin_pcie->gpio_id_dwc_perst = of_get_named_gpio(dev->of_node,
471 if (kirin_pcie->gpio_id_dwc_perst == -EPROBE_DEFER) {
472 return -EPROBE_DEFER;
473 } else if (!gpio_is_valid(kirin_pcie->gpio_id_dwc_perst)) {
474 dev_err(dev, "unable to get a valid gpio pin\n");
478 ret = kirin_pcie_get_gpio_enable(kirin_pcie, pdev);
482 /* Parse OF children */
483 for_each_available_child_of_node(node, child) {
484 ret = kirin_pcie_parse_port(kirin_pcie, pdev, child);
496 static void kirin_pcie_sideband_dbi_w_mode(struct kirin_pcie *kirin_pcie,
501 regmap_read(kirin_pcie->apb, SOC_PCIECTRL_CTRL0_ADDR, &val);
503 val = val | PCIE_ELBI_SLV_DBI_ENABLE;
505 val = val & ~PCIE_ELBI_SLV_DBI_ENABLE;
507 regmap_write(kirin_pcie->apb, SOC_PCIECTRL_CTRL0_ADDR, val);
510 static void kirin_pcie_sideband_dbi_r_mode(struct kirin_pcie *kirin_pcie,
515 regmap_read(kirin_pcie->apb, SOC_PCIECTRL_CTRL1_ADDR, &val);
517 val = val | PCIE_ELBI_SLV_DBI_ENABLE;
519 val = val & ~PCIE_ELBI_SLV_DBI_ENABLE;
521 regmap_write(kirin_pcie->apb, SOC_PCIECTRL_CTRL1_ADDR, val);
524 static int kirin_pcie_rd_own_conf(struct pci_bus *bus, unsigned int devfn,
525 int where, int size, u32 *val)
527 struct dw_pcie *pci = to_dw_pcie_from_pp(bus->sysdata);
530 return PCIBIOS_DEVICE_NOT_FOUND;
532 *val = dw_pcie_read_dbi(pci, where, size);
533 return PCIBIOS_SUCCESSFUL;
536 static int kirin_pcie_wr_own_conf(struct pci_bus *bus, unsigned int devfn,
537 int where, int size, u32 val)
539 struct dw_pcie *pci = to_dw_pcie_from_pp(bus->sysdata);
542 return PCIBIOS_DEVICE_NOT_FOUND;
544 dw_pcie_write_dbi(pci, where, size, val);
545 return PCIBIOS_SUCCESSFUL;
548 static int kirin_pcie_add_bus(struct pci_bus *bus)
550 struct dw_pcie *pci = to_dw_pcie_from_pp(bus->sysdata);
551 struct kirin_pcie *kirin_pcie = to_kirin_pcie(pci);
554 if (!kirin_pcie->num_slots)
557 /* Send PERST# to each slot */
558 for (i = 0; i < kirin_pcie->num_slots; i++) {
559 ret = gpio_direction_output(kirin_pcie->gpio_id_reset[i], 1);
561 dev_err(pci->dev, "PERST# %s error: %d\n",
562 kirin_pcie->reset_names[i], ret);
565 usleep_range(PERST_2_ACCESS_MIN, PERST_2_ACCESS_MAX);
570 static struct pci_ops kirin_pci_ops = {
571 .read = kirin_pcie_rd_own_conf,
572 .write = kirin_pcie_wr_own_conf,
573 .add_bus = kirin_pcie_add_bus,
576 static u32 kirin_pcie_read_dbi(struct dw_pcie *pci, void __iomem *base,
577 u32 reg, size_t size)
579 struct kirin_pcie *kirin_pcie = to_kirin_pcie(pci);
582 kirin_pcie_sideband_dbi_r_mode(kirin_pcie, true);
583 dw_pcie_read(base + reg, size, &ret);
584 kirin_pcie_sideband_dbi_r_mode(kirin_pcie, false);
589 static void kirin_pcie_write_dbi(struct dw_pcie *pci, void __iomem *base,
590 u32 reg, size_t size, u32 val)
592 struct kirin_pcie *kirin_pcie = to_kirin_pcie(pci);
594 kirin_pcie_sideband_dbi_w_mode(kirin_pcie, true);
595 dw_pcie_write(base + reg, size, val);
596 kirin_pcie_sideband_dbi_w_mode(kirin_pcie, false);
599 static int kirin_pcie_link_up(struct dw_pcie *pci)
601 struct kirin_pcie *kirin_pcie = to_kirin_pcie(pci);
604 regmap_read(kirin_pcie->apb, PCIE_APB_PHY_STATUS0, &val);
605 if ((val & PCIE_LINKUP_ENABLE) == PCIE_LINKUP_ENABLE)
611 static int kirin_pcie_start_link(struct dw_pcie *pci)
613 struct kirin_pcie *kirin_pcie = to_kirin_pcie(pci);
615 /* assert LTSSM enable */
616 regmap_write(kirin_pcie->apb, PCIE_APP_LTSSM_ENABLE,
617 PCIE_LTSSM_ENABLE_BIT);
622 static int kirin_pcie_host_init(struct dw_pcie_rp *pp)
624 pp->bridge->ops = &kirin_pci_ops;
629 static int kirin_pcie_gpio_request(struct kirin_pcie *kirin_pcie,
634 for (i = 0; i < kirin_pcie->num_slots; i++) {
635 if (!gpio_is_valid(kirin_pcie->gpio_id_reset[i])) {
636 dev_err(dev, "unable to get a valid %s gpio\n",
637 kirin_pcie->reset_names[i]);
641 ret = devm_gpio_request(dev, kirin_pcie->gpio_id_reset[i],
642 kirin_pcie->reset_names[i]);
647 for (i = 0; i < kirin_pcie->n_gpio_clkreq; i++) {
648 if (!gpio_is_valid(kirin_pcie->gpio_id_clkreq[i])) {
649 dev_err(dev, "unable to get a valid %s gpio\n",
650 kirin_pcie->clkreq_names[i]);
654 ret = devm_gpio_request(dev, kirin_pcie->gpio_id_clkreq[i],
655 kirin_pcie->clkreq_names[i]);
659 ret = gpio_direction_output(kirin_pcie->gpio_id_clkreq[i], 0);
667 static const struct dw_pcie_ops kirin_dw_pcie_ops = {
668 .read_dbi = kirin_pcie_read_dbi,
669 .write_dbi = kirin_pcie_write_dbi,
670 .link_up = kirin_pcie_link_up,
671 .start_link = kirin_pcie_start_link,
674 static const struct dw_pcie_host_ops kirin_pcie_host_ops = {
675 .host_init = kirin_pcie_host_init,
678 static int kirin_pcie_power_off(struct kirin_pcie *kirin_pcie)
682 if (kirin_pcie->type == PCIE_KIRIN_INTERNAL_PHY)
683 return hi3660_pcie_phy_power_off(kirin_pcie);
685 for (i = 0; i < kirin_pcie->n_gpio_clkreq; i++)
686 gpio_direction_output(kirin_pcie->gpio_id_clkreq[i], 1);
688 phy_power_off(kirin_pcie->phy);
689 phy_exit(kirin_pcie->phy);
694 static int kirin_pcie_power_on(struct platform_device *pdev,
695 struct kirin_pcie *kirin_pcie)
697 struct device *dev = &pdev->dev;
700 if (kirin_pcie->type == PCIE_KIRIN_INTERNAL_PHY) {
701 ret = hi3660_pcie_phy_init(pdev, kirin_pcie);
705 ret = hi3660_pcie_phy_power_on(kirin_pcie);
709 kirin_pcie->phy = devm_of_phy_get(dev, dev->of_node, NULL);
710 if (IS_ERR(kirin_pcie->phy))
711 return PTR_ERR(kirin_pcie->phy);
713 ret = kirin_pcie_gpio_request(kirin_pcie, dev);
717 ret = phy_init(kirin_pcie->phy);
721 ret = phy_power_on(kirin_pcie->phy);
726 /* perst assert Endpoint */
727 usleep_range(REF_2_PERST_MIN, REF_2_PERST_MAX);
729 if (!gpio_request(kirin_pcie->gpio_id_dwc_perst, "pcie_perst_bridge")) {
730 ret = gpio_direction_output(kirin_pcie->gpio_id_dwc_perst, 1);
735 usleep_range(PERST_2_ACCESS_MIN, PERST_2_ACCESS_MAX);
739 kirin_pcie_power_off(kirin_pcie);
744 static int kirin_pcie_remove(struct platform_device *pdev)
746 struct kirin_pcie *kirin_pcie = platform_get_drvdata(pdev);
748 dw_pcie_host_deinit(&kirin_pcie->pci->pp);
750 kirin_pcie_power_off(kirin_pcie);
755 struct kirin_pcie_data {
756 enum pcie_kirin_phy_type phy_type;
759 static const struct kirin_pcie_data kirin_960_data = {
760 .phy_type = PCIE_KIRIN_INTERNAL_PHY,
763 static const struct kirin_pcie_data kirin_970_data = {
764 .phy_type = PCIE_KIRIN_EXTERNAL_PHY,
767 static const struct of_device_id kirin_pcie_match[] = {
768 { .compatible = "hisilicon,kirin960-pcie", .data = &kirin_960_data },
769 { .compatible = "hisilicon,kirin970-pcie", .data = &kirin_970_data },
773 static int kirin_pcie_probe(struct platform_device *pdev)
775 struct device *dev = &pdev->dev;
776 const struct kirin_pcie_data *data;
777 struct kirin_pcie *kirin_pcie;
782 dev_err(dev, "NULL node\n");
786 data = of_device_get_match_data(dev);
788 dev_err(dev, "OF data missing\n");
792 kirin_pcie = devm_kzalloc(dev, sizeof(struct kirin_pcie), GFP_KERNEL);
796 pci = devm_kzalloc(dev, sizeof(*pci), GFP_KERNEL);
801 pci->ops = &kirin_dw_pcie_ops;
802 pci->pp.ops = &kirin_pcie_host_ops;
803 kirin_pcie->pci = pci;
804 kirin_pcie->type = data->phy_type;
806 ret = kirin_pcie_get_resource(kirin_pcie, pdev);
810 platform_set_drvdata(pdev, kirin_pcie);
812 ret = kirin_pcie_power_on(pdev, kirin_pcie);
816 return dw_pcie_host_init(&pci->pp);
819 static struct platform_driver kirin_pcie_driver = {
820 .probe = kirin_pcie_probe,
821 .remove = kirin_pcie_remove,
823 .name = "kirin-pcie",
824 .of_match_table = kirin_pcie_match,
825 .suppress_bind_attrs = true,
828 module_platform_driver(kirin_pcie_driver);
830 MODULE_DEVICE_TABLE(of, kirin_pcie_match);
831 MODULE_DESCRIPTION("PCIe host controller driver for Kirin Phone SoCs");
832 MODULE_AUTHOR("Xiaowei Song <songxiaowei@huawei.com>");
833 MODULE_LICENSE("GPL v2");