Lines Matching refs:base

255 	void __iomem		*base;
268 /* This is the base pointer for interrupt status/set/clr regs */
275 void __iomem *base;
322 static int brcm_pcie_mdio_read(void __iomem *base, u8 port, u8 regad, u32 *val)
328 base + PCIE_RC_DL_MDIO_ADDR);
329 readl(base + PCIE_RC_DL_MDIO_ADDR);
331 data = readl(base + PCIE_RC_DL_MDIO_RD_DATA);
334 data = readl(base + PCIE_RC_DL_MDIO_RD_DATA);
342 static int brcm_pcie_mdio_write(void __iomem *base, u8 port,
349 base + PCIE_RC_DL_MDIO_ADDR);
350 readl(base + PCIE_RC_DL_MDIO_ADDR);
351 writel(MDIO_DATA_DONE_MASK | wrdata, base + PCIE_RC_DL_MDIO_WR_DATA);
353 data = readl(base + PCIE_RC_DL_MDIO_WR_DATA);
356 data = readl(base + PCIE_RC_DL_MDIO_WR_DATA);
372 ret = brcm_pcie_mdio_write(pcie->base, MDIO_PORT0, SET_ADDR_OFFSET,
377 ret = brcm_pcie_mdio_read(pcie->base, MDIO_PORT0,
384 ret = brcm_pcie_mdio_write(pcie->base, MDIO_PORT0,
390 ret = brcm_pcie_mdio_read(pcie->base, MDIO_PORT0,
404 u16 lnkctl2 = readw(pcie->base + BRCM_PCIE_CAP_REGS + PCI_EXP_LNKCTL2);
405 u32 lnkcap = readl(pcie->base + BRCM_PCIE_CAP_REGS + PCI_EXP_LNKCAP);
408 writel(lnkcap, pcie->base + BRCM_PCIE_CAP_REGS + PCI_EXP_LNKCAP);
411 writew(lnkctl2, pcie->base + BRCM_PCIE_CAP_REGS + PCI_EXP_LNKCTL2);
423 /* Set the base of the pcie_addr window */
424 writel(lower_32_bits(pcie_addr), pcie->base + PCIE_MEM_WIN0_LO(win));
425 writel(upper_32_bits(pcie_addr), pcie->base + PCIE_MEM_WIN0_HI(win));
427 /* Write the addr base & limit lower bits (in MBs) */
431 tmp = readl(pcie->base + PCIE_MEM_WIN0_BASE_LIMIT(win));
436 writel(tmp, pcie->base + PCIE_MEM_WIN0_BASE_LIMIT(win));
443 tmp = readl(pcie->base + PCIE_MEM_WIN0_BASE_HI(win));
446 writel(tmp, pcie->base + PCIE_MEM_WIN0_BASE_HI(win));
449 tmp = readl(pcie->base + PCIE_MEM_WIN0_LIMIT_HI(win));
452 writel(tmp, pcie->base + PCIE_MEM_WIN0_LIMIT_HI(win));
626 msi->base + PCIE_MISC_MSI_BAR_CONFIG_LO);
628 msi->base + PCIE_MISC_MSI_BAR_CONFIG_HI);
631 writel(val, msi->base + PCIE_MISC_MSI_DATA_CONFIG);
652 msi->base = pcie->base;
659 msi->intr_base = msi->base + PCIE_INTR2_CPU_BASE;
663 msi->intr_base = msi->base + PCIE_MSI_INTR2_BASE;
683 void __iomem *base = pcie->base;
684 u32 val = readl(base + PCIE_MISC_PCIE_STATUS);
691 u32 val = readl(pcie->base + PCIE_MISC_PCIE_STATUS);
711 void __iomem *base = pcie->base;
716 return PCI_SLOT(devfn) ? NULL : base + where;
720 writel(idx, pcie->base + PCIE_EXT_CFG_INDEX);
721 return base + PCIE_EXT_CFG_DATA + where;
735 tmp = readl(pcie->base + PCIE_RGR1_SW_INIT_1(pcie));
737 writel(tmp, pcie->base + PCIE_RGR1_SW_INIT_1(pcie));
745 tmp = readl(pcie->base + PCIE_RGR1_SW_INIT_1(pcie));
747 writel(tmp, pcie->base + PCIE_RGR1_SW_INIT_1(pcie));
755 tmp = readl(pcie->base + PCIE_MISC_PCIE_CTRL);
757 writel(tmp, pcie->base + PCIE_MISC_PCIE_CTRL);
764 tmp = readl(pcie->base + PCIE_RGR1_SW_INIT_1(pcie));
766 writel(tmp, pcie->base + PCIE_RGR1_SW_INIT_1(pcie));
860 void __iomem *base = pcie->base;
877 tmp = readl(base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
879 writel(tmp, base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
896 tmp = readl(base + PCIE_MISC_MISC_CTRL);
900 writel(tmp, base + PCIE_MISC_MISC_CTRL);
910 writel(tmp, base + PCIE_MISC_RC_BAR2_CONFIG_LO);
912 base + PCIE_MISC_RC_BAR2_CONFIG_HI);
914 tmp = readl(base + PCIE_MISC_MISC_CTRL);
925 writel(tmp, base + PCIE_MISC_MISC_CTRL);
940 tmp = readl(base + PCIE_MISC_RC_BAR1_CONFIG_LO);
942 writel(tmp, base + PCIE_MISC_RC_BAR1_CONFIG_LO);
945 tmp = readl(base + PCIE_MISC_RC_BAR3_CONFIG_LO);
947 writel(tmp, base + PCIE_MISC_RC_BAR3_CONFIG_LO);
993 tmp = readl(base + PCIE_RC_CFG_PRIV1_LINK_CAPABILITY);
996 writel(tmp, base + PCIE_RC_CFG_PRIV1_LINK_CAPABILITY);
1002 tmp = readl(base + PCIE_RC_CFG_PRIV1_ID_VAL3);
1005 writel(tmp, base + PCIE_RC_CFG_PRIV1_ID_VAL3);
1015 lnksta = readw(base + BRCM_PCIE_CAP_REGS + PCI_EXP_LNKSTA);
1023 tmp = readl(base + PCIE_RC_CFG_VENDOR_VENDOR_SPECIFIC_REG1);
1026 writel(tmp, base + PCIE_RC_CFG_VENDOR_VENDOR_SPECIFIC_REG1);
1032 tmp = readl(base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
1034 writel(tmp, base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
1042 void __iomem *base = pcie->base;
1047 tmp = readl(base + PCIE_MISC_PCIE_CTRL);
1049 writel(tmp, base + PCIE_MISC_PCIE_CTRL);
1052 tmp = readl(base + PCIE_MISC_PCIE_STATUS);
1056 tmp = readl(base + PCIE_MISC_PCIE_STATUS);
1079 void __iomem *base = pcie->base;
1084 tmp = readl(base + PCIE_DVT_PMU_PCIE_PHY_CTRL);
1086 writel(tmp, base + PCIE_DVT_PMU_PCIE_PHY_CTRL);
1091 tmp = readl(base + PCIE_DVT_PMU_PCIE_PHY_CTRL);
1113 void __iomem *base = pcie->base;
1122 tmp = readl(base + PCIE_MISC_PCIE_CTRL);
1124 writel(tmp, base + PCIE_MISC_PCIE_CTRL);
1127 tmp = readl(base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
1129 writel(tmp, base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
1150 void __iomem *base;
1154 base = pcie->base;
1165 tmp = readl(base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
1167 writel(tmp, base + PCIE_MISC_HARD_PCIE_HARD_DEBUG);
1242 pcie->base = devm_platform_ioremap_resource(pdev, 0);
1243 if (IS_ERR(pcie->base))
1244 return PTR_ERR(pcie->base);
1281 pcie->hw_rev = readl(pcie->base + PCIE_MISC_REVISION);