Lines Matching refs:where
81 int dw_pcie_cfg_read(void __iomem *addr, int where, int size, u32 *val) in dw_pcie_cfg_read() argument
86 *val = (*val >> (8 * (where & 3))) & 0xff; in dw_pcie_cfg_read()
88 *val = (*val >> (8 * (where & 3))) & 0xffff; in dw_pcie_cfg_read()
95 int dw_pcie_cfg_write(void __iomem *addr, int where, int size, u32 val) in dw_pcie_cfg_write() argument
100 writew(val, addr + (where & 2)); in dw_pcie_cfg_write()
102 writeb(val, addr + (where & 3)); in dw_pcie_cfg_write()
125 static int dw_pcie_rd_own_conf(struct pcie_port *pp, int where, int size, in dw_pcie_rd_own_conf() argument
131 ret = pp->ops->rd_own_conf(pp, where, size, val); in dw_pcie_rd_own_conf()
133 ret = dw_pcie_cfg_read(pp->dbi_base + (where & ~0x3), where, in dw_pcie_rd_own_conf()
139 static int dw_pcie_wr_own_conf(struct pcie_port *pp, int where, int size, in dw_pcie_wr_own_conf() argument
145 ret = pp->ops->wr_own_conf(pp, where, size, val); in dw_pcie_wr_own_conf()
147 ret = dw_pcie_cfg_write(pp->dbi_base + (where & ~0x3), where, in dw_pcie_wr_own_conf()
581 u32 devfn, int where, int size, u32 *val) in dw_pcie_rd_other_conf() argument
588 address = where & ~0x3; in dw_pcie_rd_other_conf()
592 ret = dw_pcie_cfg_read(pp->va_cfg0_base + address, where, size, in dw_pcie_rd_other_conf()
597 ret = dw_pcie_cfg_read(pp->va_cfg1_base + address, where, size, in dw_pcie_rd_other_conf()
606 u32 devfn, int where, int size, u32 val) in dw_pcie_wr_other_conf() argument
613 address = where & ~0x3; in dw_pcie_wr_other_conf()
617 ret = dw_pcie_cfg_write(pp->va_cfg0_base + address, where, size, in dw_pcie_wr_other_conf()
622 ret = dw_pcie_cfg_write(pp->va_cfg1_base + address, where, size, in dw_pcie_wr_other_conf()
653 static int dw_pcie_rd_conf(struct pci_bus *bus, u32 devfn, int where, in dw_pcie_rd_conf() argument
667 where, size, val); in dw_pcie_rd_conf()
670 where, size, val); in dw_pcie_rd_conf()
672 ret = dw_pcie_rd_own_conf(pp, where, size, val); in dw_pcie_rd_conf()
678 int where, int size, u32 val) in dw_pcie_wr_conf() argument
689 where, size, val); in dw_pcie_wr_conf()
692 where, size, val); in dw_pcie_wr_conf()
694 ret = dw_pcie_wr_own_conf(pp, where, size, val); in dw_pcie_wr_conf()