Lines Matching refs:devfn
85 static unsigned long u3_agp_cfa0(u8 devfn, u8 off) in u3_agp_cfa0() argument
87 return (1 << (unsigned long)PCI_SLOT(devfn)) | in u3_agp_cfa0()
88 ((unsigned long)PCI_FUNC(devfn) << 8) | in u3_agp_cfa0()
92 static unsigned long u3_agp_cfa1(u8 bus, u8 devfn, u8 off) in u3_agp_cfa1() argument
95 ((unsigned long)devfn << 8) | in u3_agp_cfa1()
121 static int u3_agp_read_config(struct pci_bus *bus, unsigned int devfn, in u3_agp_read_config() argument
131 addr = u3_agp_cfg_access(hose, bus->number, devfn, offset); in u3_agp_read_config()
152 static int u3_agp_write_config(struct pci_bus *bus, unsigned int devfn, in u3_agp_write_config() argument
162 addr = u3_agp_cfg_access(hose, bus->number, devfn, offset); in u3_agp_write_config()
189 static unsigned long u3_ht_cfa0(u8 devfn, u8 off) in u3_ht_cfa0() argument
191 return (devfn << 8) | off; in u3_ht_cfa0()
194 static unsigned long u3_ht_cfa1(u8 bus, u8 devfn, u8 off) in u3_ht_cfa1() argument
196 return u3_ht_cfa0(devfn, off) + (bus << 16) + 0x01000000UL; in u3_ht_cfa1()
200 u8 bus, u8 devfn, u8 offset) in u3_ht_cfg_access() argument
203 if (PCI_SLOT(devfn) == 0) in u3_ht_cfg_access()
205 return hose->cfg_data + u3_ht_cfa0(devfn, offset); in u3_ht_cfg_access()
207 return hose->cfg_data + u3_ht_cfa1(bus, devfn, offset); in u3_ht_cfg_access()
258 static int u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, in u3_ht_read_config() argument
268 if (bus->number == hose->first_busno && devfn == PCI_DEVFN(0, 0)) in u3_ht_read_config()
274 addr = u3_ht_cfg_access(hose, bus->number, devfn, offset); in u3_ht_read_config()
296 static int u3_ht_write_config(struct pci_bus *bus, unsigned int devfn, in u3_ht_write_config() argument
306 if (bus->number == hose->first_busno && devfn == PCI_DEVFN(0, 0)) in u3_ht_write_config()
312 addr = u3_ht_cfg_access(hose, bus->number, devfn, offset); in u3_ht_write_config()
339 static unsigned int u4_pcie_cfa0(unsigned int devfn, unsigned int off) in u4_pcie_cfa0() argument
341 return (1 << PCI_SLOT(devfn)) | in u4_pcie_cfa0()
342 (PCI_FUNC(devfn) << 8) | in u4_pcie_cfa0()
347 static unsigned int u4_pcie_cfa1(unsigned int bus, unsigned int devfn, in u4_pcie_cfa1() argument
351 (devfn << 8) | in u4_pcie_cfa1()
375 static int u4_pcie_read_config(struct pci_bus *bus, unsigned int devfn, in u4_pcie_read_config() argument
386 addr = u4_pcie_cfg_access(hose, bus->number, devfn, offset); in u4_pcie_read_config()
406 static int u4_pcie_write_config(struct pci_bus *bus, unsigned int devfn, in u4_pcie_write_config() argument
417 addr = u4_pcie_cfg_access(hose, bus->number, devfn, offset); in u4_pcie_write_config()