Home
last modified time | relevance | path

Searched refs:where (Results 1 – 25 of 1044) sorted by relevance

12345678910>>...42

/linux/arch/mips/pci/
A Dops-rc32434.c48 unsigned char where, u32 *data) in config_access() argument
54 PCI_CFG_SET(bus->number, slot, func, where); in config_access()
73 int where, u8 *val) in read_config_byte() argument
79 *val = (data >> ((where & 3) << 3)) & 0xff; in read_config_byte()
84 int where, u16 *val) in read_config_word() argument
95 int where, u32 *val) in read_config_dword() argument
114 if (where == PCI_VENDOR_ID) { in read_config_dword()
138 (val << ((where & 3) << 3)); in write_config_byte()
157 (val << ((where & 3) << 3)); in write_config_word()
178 int where, int size, u32 *val) in pci_config_read() argument
[all …]
A Dops-bcm63xx.c48 (val << ((where & 3) << 3)); in preprocess_write()
52 (val << ((where & 3) << 3)); in preprocess_write()
72 reg = where >> 2; in bcm63xx_setup_cfg_access()
158 where, size, val); in bcm63xx_pci_read()
172 where, size, val); in bcm63xx_pci_write()
214 reg = where >> 2; in fake_cb_bridge_read()
303 reg = where >> 2; in fake_cb_bridge_write()
381 where, size, val); in bcm63xx_cb_read()
399 where, size, val); in bcm63xx_cb_write()
487 u32 reg = where & ~3; in bcm63xx_pcie_read()
[all …]
A Dops-msc.c76 int where, int size, u32 * val) in msc_pcibios_read() argument
80 if ((size == 2) && (where & 1)) in msc_pcibios_read()
82 else if ((size == 4) && (where & 3)) in msc_pcibios_read()
90 *val = (data >> ((where & 3) << 3)) & 0xff; in msc_pcibios_read()
92 *val = (data >> ((where & 3) << 3)) & 0xffff; in msc_pcibios_read()
100 int where, int size, u32 val) in msc_pcibios_write() argument
104 if ((size == 2) && (where & 1)) in msc_pcibios_write()
106 else if ((size == 4) && (where & 3)) in msc_pcibios_write()
113 where, &data)) in msc_pcibios_write()
118 (val << ((where & 3) << 3)); in msc_pcibios_write()
[all …]
A Dops-bonito64.c26 unsigned int devfn, int where, in bonito64_pcibios_config_access() argument
35 int reg = where & ~3; in bonito64_pcibios_config_access()
90 int where, int size, u32 * val) in bonito64_pcibios_read() argument
94 if ((size == 2) && (where & 1)) in bonito64_pcibios_read()
96 else if ((size == 4) && (where & 3)) in bonito64_pcibios_read()
114 int where, int size, u32 val) in bonito64_pcibios_write() argument
118 if ((size == 2) && (where & 1)) in bonito64_pcibios_write()
120 else if ((size == 4) && (where & 3)) in bonito64_pcibios_write()
127 where, &data)) in bonito64_pcibios_write()
132 (val << ((where & 3) << 3)); in bonito64_pcibios_write()
[all …]
A Dpci-bcm1480ht.c38 #define CFGOFFSET(bus, devfn, where) (((bus)<<16)+((devfn)<<8)+(where)) argument
39 #define CFGADDR(bus, devfn, where) CFGOFFSET((bus)->number, (devfn), where) argument
97 int where, int size, u32 * val) in bcm1480ht_pcibios_read() argument
101 if ((size == 2) && (where & 1)) in bcm1480ht_pcibios_read()
103 else if ((size == 4) && (where & 3)) in bcm1480ht_pcibios_read()
122 int where, int size, u32 val) in bcm1480ht_pcibios_write() argument
124 u32 cfgaddr = CFGADDR(bus, devfn, where); in bcm1480ht_pcibios_write()
127 if ((size == 2) && (where & 1)) in bcm1480ht_pcibios_write()
129 else if ((size == 4) && (where & 3)) in bcm1480ht_pcibios_write()
139 (val << ((where & 3) << 3)); in bcm1480ht_pcibios_write()
[all …]
A Dpci-sb1250.c40 #define CFGOFFSET(bus, devfn, where) (((bus)<<16) + ((devfn)<<8) + (where)) argument
41 #define CFGADDR(bus, devfn, where) CFGOFFSET((bus)->number, (devfn), where) argument
117 int where, int size, u32 * val) in sb1250_pcibios_read() argument
121 if ((size == 2) && (where & 1)) in sb1250_pcibios_read()
123 else if ((size == 4) && (where & 3)) in sb1250_pcibios_read()
142 int where, int size, u32 val) in sb1250_pcibios_write() argument
144 u32 cfgaddr = CFGADDR(bus, devfn, where); in sb1250_pcibios_write()
147 if ((size == 2) && (where & 1)) in sb1250_pcibios_write()
149 else if ((size == 4) && (where & 3)) in sb1250_pcibios_write()
159 (val << ((where & 3) << 3)); in sb1250_pcibios_write()
[all …]
A Dpci-bcm1480.c40 #define CFGOFFSET(bus, devfn, where) (((bus)<<16)+((devfn)<<8)+(where)) argument
41 #define CFGADDR(bus, devfn, where) CFGOFFSET((bus)->number, (devfn), where) argument
108 int where, int size, u32 * val) in bcm1480_pcibios_read() argument
112 if ((size == 2) && (where & 1)) in bcm1480_pcibios_read()
114 else if ((size == 4) && (where & 3)) in bcm1480_pcibios_read()
133 int where, int size, u32 val) in bcm1480_pcibios_write() argument
135 u32 cfgaddr = CFGADDR(bus, devfn, where); in bcm1480_pcibios_write()
138 if ((size == 2) && (where & 1)) in bcm1480_pcibios_write()
140 else if ((size == 4) && (where & 3)) in bcm1480_pcibios_write()
150 (val << ((where & 3) << 3)); in bcm1480_pcibios_write()
[all …]
A Dops-vr41xx.c23 unsigned int devfn, int where) in set_pci_configuration_address() argument
29 if (PCI_SLOT(devfn) < 11 || where > 0xff) in set_pci_configuration_address()
33 (where & 0xfc), PCICONFAREG); in set_pci_configuration_address()
38 if (where > 0xff) in set_pci_configuration_address()
42 (where & 0xfc) | 1U, PCICONFAREG); in set_pci_configuration_address()
54 if (set_pci_configuration_address(bus->number, devfn, where) < 0) in pci_config_read()
61 *val = (data >> ((where & 3) << 3)) & 0xffU; in pci_config_read()
64 *val = (data >> ((where & 2) << 3)) & 0xffffU; in pci_config_read()
82 if (set_pci_configuration_address(bus->number, devfn, where) < 0) in pci_config_write()
89 shift = (where & 3) << 3; in pci_config_write()
[all …]
A Dops-loongson2.c34 unsigned int devfn, int where, in loongson_pcibios_config_access() argument
43 int reg = where & ~3; in loongson_pcibios_config_access()
119 int where, int size, u32 *val) in loongson_pcibios_read() argument
123 if ((size == 2) && (where & 1)) in loongson_pcibios_read()
125 else if ((size == 4) && (where & 3)) in loongson_pcibios_read()
143 int where, int size, u32 val) in loongson_pcibios_write() argument
147 if ((size == 2) && (where & 1)) in loongson_pcibios_write()
149 else if ((size == 4) && (where & 3)) in loongson_pcibios_write()
156 where, &data)) in loongson_pcibios_write()
161 (val << ((where & 3) << 3)); in loongson_pcibios_write()
[all …]
A Dops-gt64xxx_pci0.c47 ((where / 4) << GT_PCI0_CFGADDR_REGNUM_SHF) | in gt64xxx_pci0_pcibios_config_access()
92 int where, int size, u32 * val) in gt64xxx_pci0_pcibios_read() argument
97 where, &data)) in gt64xxx_pci0_pcibios_read()
101 *val = (data >> ((where & 3) << 3)) & 0xff; in gt64xxx_pci0_pcibios_read()
103 *val = (data >> ((where & 3) << 3)) & 0xffff; in gt64xxx_pci0_pcibios_read()
111 int where, int size, u32 val) in gt64xxx_pci0_pcibios_write() argument
119 devfn, where, &data)) in gt64xxx_pci0_pcibios_write()
123 data = (data & ~(0xff << ((where & 3) << 3))) | in gt64xxx_pci0_pcibios_write()
124 (val << ((where & 3) << 3)); in gt64xxx_pci0_pcibios_write()
127 (val << ((where & 3) << 3)); in gt64xxx_pci0_pcibios_write()
[all …]
A Dops-lantiq.c27 unsigned int devfn, unsigned int where, u32 *data) in ltq_pci_config_access() argument
43 LTQ_PCI_CFG_FUNNUM_SHF) | (where & ~0x3); in ltq_pci_config_access()
72 int where, int size, u32 *val) in ltq_pci_read_config_dword() argument
80 *val = (data >> ((where & 3) << 3)) & 0xff; in ltq_pci_read_config_dword()
82 *val = (data >> ((where & 3) << 3)) & 0xffff; in ltq_pci_read_config_dword()
90 int where, int size, u32 val) in ltq_pci_write_config_dword() argument
98 devfn, where, &data)) in ltq_pci_write_config_dword()
102 data = (data & ~(0xff << ((where & 3) << 3))) | in ltq_pci_write_config_dword()
103 (val << ((where & 3) << 3)); in ltq_pci_write_config_dword()
105 data = (data & ~(0xffff << ((where & 3) << 3))) | in ltq_pci_write_config_dword()
[all …]
A Dpci-alchemy.c189 int where, u8 *val) in read_config_byte() argument
194 if (where & 1) in read_config_byte()
196 if (where & 2) in read_config_byte()
203 int where, u16 *val) in read_config_word() argument
208 if (where & 2) in read_config_word()
215 int where, u32 *val) in read_config_dword() argument
221 int where, u8 val) in write_config_byte() argument
229 (val << ((where & 3) << 3)); in write_config_byte()
238 int where, u16 val) in write_config_word() argument
246 (val << ((where & 3) << 3)); in write_config_word()
[all …]
A Dpci-ar724x.c74 int where, int size, u32 value) in ar724x_pci_local_write() argument
80 WARN_ON(where & (size - 1)); in ar724x_pci_local_write()
90 s = ((where & 3) * 8); in ar724x_pci_local_write()
95 s = ((where & 2) * 8); in ar724x_pci_local_write()
108 __raw_readl(base + (where & ~3)); in ar724x_pci_local_write()
132 if (where & 1) in ar724x_pci_read()
134 if (where & 2) in ar724x_pci_read()
139 if (where & 2) in ar724x_pci_read()
201 s = ((where & 3) * 8); in ar724x_pci_write()
206 s = ((where & 2) * 8); in ar724x_pci_write()
[all …]
/linux/drivers/pci/controller/
A Dpci-thunder-ecam.c18 int shift = (where & 3) * 8; in set_val()
36 int where_a = where & 0xc; in handle_ea_bar()
39 set_val(e0, where, size, val); in handle_ea_bar()
51 set_val(v, where, size, val); in handle_ea_bar()
70 set_val(v, where, size, val); in handle_ea_bar()
90 int where_a = where & ~3; in thunder_ecam_p2_config_read()
135 int where_a = where & ~3; in thunder_ecam_config_read()
171 ((where >= 0x10 && where < 0x2c) || in thunder_ecam_config_read()
172 (where >= 0x1a4 && where < 0x1bc))) { in thunder_ecam_config_read()
340 if ((where >= 0x10 && where < 0x2c) || in thunder_ecam_config_write()
[all …]
A Dpci-thunder-pem.c38 int where, int size, u32 *val) in thunder_pem_bridge_read() argument
44 if (devfn != 0 || where >= 2048) { in thunder_pem_bridge_read()
54 read_val = where & ~3ull; in thunder_pem_bridge_read()
63 switch (where & ~3) { in thunder_pem_bridge_read()
124 read_val >>= (8 * (where & 3)); in thunder_pem_bridge_read()
140 int where, int size, u32 *val) in thunder_pem_config_read() argument
216 int where, int size, u32 val) in thunder_pem_bridge_write() argument
221 u64 where_aligned = where & ~3ull; in thunder_pem_bridge_write()
225 if (devfn != 0 || where >= 2048) in thunder_pem_bridge_write()
239 mask = ~(0xff << (8 * (where & 3))); in thunder_pem_bridge_write()
[all …]
/linux/arch/sh/drivers/pci/
A Dops-sh7786.c28 reg = where & ~3; in sh7786_pcie_config_access()
90 int where, int size, u32 *val) in sh7786_pcie_read() argument
96 if ((size == 2) && (where & 1)) in sh7786_pcie_read()
98 else if ((size == 4) && (where & 3)) in sh7786_pcie_read()
103 devfn, where, &data); in sh7786_pcie_read()
126 int where, int size, u32 val) in sh7786_pcie_write() argument
134 else if ((size == 4) && (where & 3)) in sh7786_pcie_write()
139 devfn, where, &data); in sh7786_pcie_write()
148 shift = (where & 3) << 3; in sh7786_pcie_write()
152 shift = (where & 2) << 3; in sh7786_pcie_write()
[all …]
A Dops-sh4.c16 #define CONFIG_CMD(bus, devfn, where) \ argument
17 (0x80000000 | (bus->number << 16) | (devfn << 8) | (where & ~3))
23 int where, int size, u32 *val) in sh4_pci_read() argument
34 pci_write_reg(chan, CONFIG_CMD(bus, devfn, where), SH4_PCIPAR); in sh4_pci_read()
40 *val = (data >> ((where & 3) << 3)) & 0xff; in sh4_pci_read()
43 *val = (data >> ((where & 2) << 3)) & 0xffff; in sh4_pci_read()
61 int where, int size, u32 val) in sh4_pci_write() argument
69 pci_write_reg(chan, CONFIG_CMD(bus, devfn, where), SH4_PCIPAR); in sh4_pci_write()
75 shift = (where & 3) << 3; in sh4_pci_write()
80 shift = (where & 2) << 3; in sh4_pci_write()
A Dops-dreamcast.c46 static int gapspci_read(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 *val) in gapspci_read() argument
54 case 1: *val = inb(GAPSPCI_BBA_CONFIG+where); break; in gapspci_read()
55 case 2: *val = inw(GAPSPCI_BBA_CONFIG+where); break; in gapspci_read()
56 case 4: *val = inl(GAPSPCI_BBA_CONFIG+where); break; in gapspci_read()
62 static int gapspci_write(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 val) in gapspci_write() argument
68 case 1: outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break; in gapspci_write()
69 case 2: outw((u16)val, GAPSPCI_BBA_CONFIG+where); break; in gapspci_write()
70 case 4: outl((u32)val, GAPSPCI_BBA_CONFIG+where); break; in gapspci_write()
/linux/arch/sparc/kernel/
A Dpci_common.c66 if (where < 8) { in sun4u_read_pci_cfg_host()
71 if (where & 1) in sun4u_read_pci_cfg_host()
82 if (where < 8) { in sun4u_read_pci_cfg_host()
146 where); in sun4u_read_pci_cfg()
156 where); in sun4u_read_pci_cfg()
177 if (where < 8) { in sun4u_write_pci_cfg_host()
183 if (where & 1) { in sun4u_write_pci_cfg_host()
195 if (where < 8) { in sun4u_write_pci_cfg_host()
235 where); in sun4u_write_pci_cfg()
244 where); in sun4u_write_pci_cfg()
[all …]
A Dleon_pci_grpci1.c103 unsigned int devfn, int where, u32 val);
122 if (where & 0x3) in grpci1_cfg_r32()
160 if (where & 0x1) in grpci1_cfg_r16()
174 *val = 0xff & (v >> (8 * (where & 3))); in grpci1_cfg_r8()
180 unsigned int devfn, int where, u32 val) in grpci1_cfg_w32() argument
185 if (where & 0x3) in grpci1_cfg_w32()
200 (devfn << 8) | (where & 0xfc)); in grpci1_cfg_w32()
207 unsigned int devfn, int where, u32 val) in grpci1_cfg_w16() argument
212 if (where & 0x1) in grpci1_cfg_w16()
240 int where, int size, u32 *val) in grpci1_read_config() argument
[all …]
A Dleon_pci_grpci2.c241 if (where & 0x3) in grpci2_cfg_r32()
261 (devfn << 8) | (where & 0xfc)); in grpci2_cfg_r32()
286 if (where & 0x1) in grpci2_cfg_r16()
300 *val = 0xff & (v >> (8 * (where & 3))); in grpci2_cfg_r8()
306 unsigned int devfn, int where, u32 val) in grpci2_cfg_w32() argument
311 if (where & 0x3) in grpci2_cfg_w32()
331 (devfn << 8) | (where & 0xfc)); in grpci2_cfg_w32()
349 if (where & 0x1) in grpci2_cfg_w16()
377 int where, int size, u32 *val) in grpci2_read_config() argument
416 int where, int size, u32 val) in grpci2_write_config() argument
[all …]
A Dpcic.c177 int where, u32 *value) in pcic_read_config_dword() argument
214 int where, int size, u32 *val) in pcic_read_config() argument
225 if (where&1) return -EINVAL; in pcic_read_config()
230 if (where&3) return -EINVAL; in pcic_read_config()
238 int where, u32 value) in pcic_write_config_dword() argument
253 int where, int size, u32 val) in pcic_write_config() argument
261 v = (v & ~(0xff << (8*(where&3)))) | in pcic_write_config()
262 ((0xff&val) << (8*(where&3))); in pcic_write_config()
265 if (where&1) return -EINVAL; in pcic_write_config()
268 ((0xffff&val) << (8*(where&3))); in pcic_write_config()
[all …]
/linux/arch/arm/mach-ixp4xx/
A Dcommon-pci.c171 (where & ~3); in ixp4xx_config_addr()
175 ((PCI_FUNC(devfn)) << 8) | (where & ~3) | 1; in ixp4xx_config_addr()
203 static int local_read_config(int where, int size, u32 *value) in local_read_config() argument
207 n = where % 4; in local_read_config()
208 crp_read(where & ~3, &data); in local_read_config()
218 n = where % 4; in local_write_config()
223 crp_write((where & ~3) | byte_enables, data); in local_write_config()
247 n = where % 4; in ixp4xx_pci_read_config()
252 addr = ixp4xx_config_addr(bus_num, devfn, where); in ixp4xx_pci_read_config()
269 n = where % 4; in ixp4xx_pci_write_config()
[all …]
/linux/arch/powerpc/kernel/
A Drtas_pci.c35 static inline int config_access_valid(struct pci_dn *dn, int where) in config_access_valid() argument
37 if (where < 256) in config_access_valid()
39 if (where < 4096 && dn->pci_ext_config_space) in config_access_valid()
53 if (!config_access_valid(pdn, where)) in rtas_read_config()
61 addr = rtas_config_addr(pdn->busno, pdn->devfn, where); in rtas_read_config()
79 int where, int size, u32 *val) in rtas_pci_read_config() argument
89 ret = rtas_read_config(pdn, where, size, val); in rtas_pci_read_config()
104 if (!config_access_valid(pdn, where)) in rtas_write_config()
112 addr = rtas_config_addr(pdn->busno, pdn->devfn, where); in rtas_write_config()
129 int where, int size, u32 val) in rtas_pci_write_config() argument
[all …]
/linux/drivers/pci/
A Daccess.c78 int where, int size, u32 *val) in pci_generic_config_read() argument
82 addr = bus->ops->map_bus(bus, devfn, where); in pci_generic_config_read()
100 int where, int size, u32 val) in pci_generic_config_write() argument
104 addr = bus->ops->map_bus(bus, devfn, where); in pci_generic_config_write()
120 int where, int size, u32 *val) in pci_generic_config_read32() argument
124 addr = bus->ops->map_bus(bus, devfn, where & ~0x3); in pci_generic_config_read32()
140 int where, int size, u32 val) in pci_generic_config_write32() argument
145 addr = bus->ops->map_bus(bus, devfn, where & ~0x3); in pci_generic_config_write32()
165 PCI_SLOT(devfn), PCI_FUNC(devfn), where); in pci_generic_config_write32()
167 mask = ~(((1 << (size * 8)) - 1) << ((where & 0x3) * 8)); in pci_generic_config_write32()
[all …]

Completed in 55 milliseconds

12345678910>>...42