/
usr
/
src
/
linux-headers-5.15.0-190
/
arch
/
powerpc
/
include
/
asm
/
/usr/src/linux-headers-5.15.0-190/arch/powerpc/include/asm
mkdir
upload
Name
Size
Mode
Actions
book3s/
-
0755
rm
nohash/
-
0755
rm
vdso/
-
0755
rm
8xx_immap.h
14099
0644
edit
dl
rm
accounting.h
908
0644
edit
dl
rm
agp.h
525
0644
edit
dl
rm
archrandom.h
838
0644
edit
dl
rm
asm-compat.h
1882
0644
edit
dl
rm
asm-const.h
468
0644
edit
dl
rm
asm-offsets.h
35
0644
edit
dl
rm
asm-prototypes.h
5130
0644
edit
dl
rm
async_tx.h
908
0644
edit
dl
rm
atomic.h
14267
0644
edit
dl
rm
backlight.h
1115
0644
edit
dl
rm
barrier.h
3977
0644
edit
dl
rm
bitops.h
7913
0644
edit
dl
rm
bootx.h
1142
0644
edit
dl
rm
bpf_perf_event.h
233
0644
edit
dl
rm
btext.h
1006
0644
edit
dl
rm
bug.h
4090
0644
edit
dl
rm
cache.h
2888
0644
edit
dl
rm
cacheflush.h
3851
0644
edit
dl
rm
cell-pmu.h
3496
0644
edit
dl
rm
cell-regs.h
9799
0644
edit
dl
rm
checksum.h
5723
0644
edit
dl
rm
clocksource.h
185
0644
edit
dl
rm
cmpxchg.h
12280
0644
edit
dl
rm
code-patching-asm.h
397
0644
edit
dl
rm
code-patching.h
5443
0644
edit
dl
rm
compat.h
3304
0644
edit
dl
rm
context_tracking.h
245
0644
edit
dl
rm
copro.h
593
0644
edit
dl
rm
cpm.h
25
0644
edit
dl
rm
cpm1.h
21711
0644
edit
dl
rm
cpm2.h
49598
0644
edit
dl
rm
cpufeature.h
998
0644
edit
dl
rm
cpuidle.h
3407
0644
edit
dl
rm
cputable.h
23211
0644
edit
dl
rm
cputhreads.h
3856
0644
edit
dl
rm
cputime.h
3069
0644
edit
dl
rm
cpu_has_feature.h
1339
0644
edit
dl
rm
cpu_setup_power.h
507
0644
edit
dl
rm
crashdump-ppc64.h
624
0644
edit
dl
rm
current.h
680
0644
edit
dl
rm
dbdma.h
3809
0644
edit
dl
rm
dbell.h
4025
0644
edit
dl
rm
dcr-generic.h
930
0644
edit
dl
rm
dcr-mmio.h
1026
0644
edit
dl
rm
dcr-native.h
3859
0644
edit
dl
rm
dcr-regs.h
5846
0644
edit
dl
rm
dcr.h
2108
0644
edit
dl
rm
debug.h
1886
0644
edit
dl
rm
delay.h
3297
0644
edit
dl
rm
device.h
1016
0644
edit
dl
rm
disassemble.h
2189
0644
edit
dl
rm
dma-direct.h
391
0644
edit
dl
rm
dma.h
10725
0644
edit
dl
rm
drmem.h
2970
0644
edit
dl
rm
dtl.h
1515
0644
edit
dl
rm
dt_cpu_ftrs.h
756
0644
edit
dl
rm
edac.h
1105
0644
edit
dl
rm
eeh.h
15478
0644
edit
dl
rm
eeh_event.h
826
0644
edit
dl
rm
ehv_pic.h
963
0644
edit
dl
rm
elf.h
6283
0644
edit
dl
rm
elfnote.h
527
0644
edit
dl
rm
emergency-restart.h
43
0644
edit
dl
rm
emulated_ops.h
2072
0644
edit
dl
rm
epapr_hcalls.h
16827
0644
edit
dl
rm
exception-64e.h
5785
0644
edit
dl
rm
exception-64s.h
4350
0644
edit
dl
rm
exec.h
246
0644
edit
dl
rm
extable.h
1205
0644
edit
dl
rm
fadump-internal.h
4352
0644
edit
dl
rm
fadump.h
1095
0644
edit
dl
rm
fb.h
483
0644
edit
dl
rm
feature-fixups.h
9828
0644
edit
dl
rm
firmware.h
5327
0644
edit
dl
rm
fixmap.h
3723
0644
edit
dl
rm
floppy.h
5111
0644
edit
dl
rm
fsl_85xx_cache_sram.h
812
0644
edit
dl
rm
fsl_gtm.h
1203
0644
edit
dl
rm
fsl_hcalls.h
17615
0644
edit
dl
rm
fsl_lbc.h
10489
0644
edit
dl
rm
fsl_pamu_stash.h
411
0644
edit
dl
rm
fsl_pm.h
1183
0644
edit
dl
rm
fs_pd.h
1046
0644
edit
dl
rm
ftrace.h
3550
0644
edit
dl
rm
futex.h
2246
0644
edit
dl
rm
grackle.h
331
0644
edit
dl
rm
hardirq.h
948
0644
edit
dl
rm
head-64.h
5507
0644
edit
dl
rm
heathrow.h
2595
0644
edit
dl
rm
highmem.h
2079
0644
edit
dl
rm
hmi.h
971
0644
edit
dl
rm
hugetlb.h
2186
0644
edit
dl
rm
hvcall.h
21250
0644
edit
dl
rm
hvconsole.h
790
0644
edit
dl
rm
hvcserver.h
1473
0644
edit
dl
rm
hvsi.h
2850
0644
edit
dl
rm
hw_breakpoint.h
3735
0644
edit
dl
rm
hw_irq.h
11218
0644
edit
dl
rm
hydra.h
2948
0644
edit
dl
rm
i8259.h
361
0644
edit
dl
rm
ibmebus.h
2204
0644
edit
dl
rm
icswx.h
5090
0644
edit
dl
rm
ide.h
586
0644
edit
dl
rm
idle.h
2372
0644
edit
dl
rm
imc-pmu.h
3983
0644
edit
dl
rm
immap_cpm2.h
10749
0644
edit
dl
rm
inst.h
3683
0644
edit
dl
rm
interrupt.h
18353
0644
edit
dl
rm
io-defs.h
3164
0644
edit
dl
rm
io-workarounds.h
1313
0644
edit
dl
rm
io.h
31387
0644
edit
dl
rm
iommu.h
10283
0644
edit
dl
rm
io_event_irq.h
1746
0644
edit
dl
rm
ipic.h
3141
0644
edit
dl
rm
irq.h
1320
0644
edit
dl
rm
irqflags.h
1777
0644
edit
dl
rm
irq_work.h
213
0644
edit
dl
rm
isa-bridge.h
654
0644
edit
dl
rm
jump_label.h
1351
0644
edit
dl
rm
kasan.h
1396
0644
edit
dl
rm
Kbuild
286
0644
edit
dl
rm
kdebug.h
291
0644
edit
dl
rm
kdump.h
1399
0644
edit
dl
rm
kexec.h
4838
0644
edit
dl
rm
kexec_ranges.h
943
0644
edit
dl
rm
keylargo.h
11061
0644
edit
dl
rm
kfence.h
650
0644
edit
dl
rm
kgdb.h
2156
0644
edit
dl
rm
kprobes.h
2815
0644
edit
dl
rm
kup.h
3259
0644
edit
dl
rm
kvm_asm.h
4952
0644
edit
dl
rm
kvm_book3s.h
17220
0644
edit
dl
rm
kvm_book3s_32.h
816
0644
edit
dl
rm
kvm_book3s_64.h
18333
0644
edit
dl
rm
kvm_book3s_asm.h
3777
0644
edit
dl
rm
kvm_book3s_uvmem.h
2738
0644
edit
dl
rm
kvm_booke.h
2233
0644
edit
dl
rm
kvm_booke_hv_asm.h
1960
0644
edit
dl
rm
kvm_fpu.h
2199
0644
edit
dl
rm
kvm_guest.h
566
0644
edit
dl
rm
kvm_host.h
21966
0644
edit
dl
rm
kvm_para.h
752
0644
edit
dl
rm
kvm_ppc.h
36699
0644
edit
dl
rm
libata-portmap.h
249
0644
edit
dl
rm
linkage.h
501
0644
edit
dl
rm
livepatch.h
1140
0644
edit
dl
rm
local.h
3258
0644
edit
dl
rm
lppaca.h
5015
0644
edit
dl
rm
lv1call.h
18555
0644
edit
dl
rm
machdep.h
9630
0644
edit
dl
rm
macio.h
3985
0644
edit
dl
rm
mc146818rtc.h
736
0644
edit
dl
rm
mce.h
6396
0644
edit
dl
rm
mediabay.h
1375
0644
edit
dl
rm
membarrier.h
877
0644
edit
dl
rm
mem_encrypt.h
532
0644
edit
dl
rm
mman.h
1471
0644
edit
dl
rm
mmiowb.h
374
0644
edit
dl
rm
mmu.h
11244
0644
edit
dl
rm
mmu_context.h
9646
0644
edit
dl
rm
mmzone.h
1003
0644
edit
dl
rm
module.h
2284
0644
edit
dl
rm
module.lds.h
95
0644
edit
dl
rm
mpc5xxx.h
439
0644
edit
dl
rm
mpc6xx.h
143
0644
edit
dl
rm
mpc52xx.h
11100
0644
edit
dl
rm
mpc52xx_psc.h
10125
0644
edit
dl
rm
mpc85xx.h
2382
0644
edit
dl
rm
mpc5121.h
3863
0644
edit
dl
rm
mpc8260.h
742
0644
edit
dl
rm
mpic.h
14309
0644
edit
dl
rm
mpic_msgr.h
3441
0644
edit
dl
rm
mpic_timer.h
1183
0644
edit
dl
rm
msi_bitmap.h
867
0644
edit
dl
rm
nmi.h
579
0644
edit
dl
rm
nvram.h
2834
0644
edit
dl
rm
ohare.h
1684
0644
edit
dl
rm
opal-api.h
31680
0644
edit
dl
rm
opal.h
17843
0644
edit
dl
rm
paca.h
8783
0644
edit
dl
rm
page.h
10362
0644
edit
dl
rm
page_32.h
1626
0644
edit
dl
rm
page_64.h
2716
0644
edit
dl
rm
paravirt.h
3881
0644
edit
dl
rm
parport.h
956
0644
edit
dl
rm
pasemi_dma.h
23273
0644
edit
dl
rm
pci-bridge.h
9481
0644
edit
dl
rm
pci.h
3605
0644
edit
dl
rm
percpu.h
815
0644
edit
dl
rm
perf_event.h
1509
0644
edit
dl
rm
perf_event_fsl_emb.h
1252
0644
edit
dl
rm
perf_event_server.h
7104
0644
edit
dl
rm
pgalloc.h
2067
0644
edit
dl
rm
pgtable-be-types.h
2601
0644
edit
dl
rm
pgtable-types.h
1895
0644
edit
dl
rm
pgtable.h
4047
0644
edit
dl
rm
pkeys.h
4279
0644
edit
dl
rm
plpar_wrappers.h
10193
0644
edit
dl
rm
pmac_feature.h
13396
0644
edit
dl
rm
pmac_low_i2c.h
3100
0644
edit
dl
rm
pmac_pfunc.h
8237
0644
edit
dl
rm
pmc.h
1116
0644
edit
dl
rm
pmi.h
1177
0644
edit
dl
rm
pnv-ocxl.h
3069
0644
edit
dl
rm
pnv-pci.h
2432
0644
edit
dl
rm
powernv.h
454
0644
edit
dl
rm
ppc-opcode.h
31419
0644
edit
dl
rm
ppc-pci.h
2282
0644
edit
dl
rm
ppc4xx.h
328
0644
edit
dl
rm
ppc_asm.h
20530
0644
edit
dl
rm
probes.h
1542
0644
edit
dl
rm
processor.h
11898
0644
edit
dl
rm
prom.h
7324
0644
edit
dl
rm
ps3.h
15219
0644
edit
dl
rm
ps3av.h
23422
0644
edit
dl
rm
ps3gpu.h
1928
0644
edit
dl
rm
ps3stor.h
1408
0644
edit
dl
rm
pte-walk.h
2281
0644
edit
dl
rm
ptrace.h
10508
0644
edit
dl
rm
qspinlock.h
2064
0644
edit
dl
rm
qspinlock_paravirt.h
221
0644
edit
dl
rm
reg.h
64465
0644
edit
dl
rm
reg_8xx.h
2867
0644
edit
dl
rm
reg_a2.h
6128
0644
edit
dl
rm
reg_booke.h
33882
0644
edit
dl
rm
reg_fsl_emb.h
3961
0644
edit
dl
rm
rheap.h
2578
0644
edit
dl
rm
rio.h
424
0644
edit
dl
rm
rtas-types.h
2939
0644
edit
dl
rm
rtas.h
12574
0644
edit
dl
rm
runlatch.h
1184
0644
edit
dl
rm
seccomp.h
1043
0644
edit
dl
rm
sections.h
1982
0644
edit
dl
rm
secure_boot.h
476
0644
edit
dl
rm
security_features.h
3509
0644
edit
dl
rm
secvar.h
765
0644
edit
dl
rm
serial.h
473
0644
edit
dl
rm
setjmp.h
400
0644
edit
dl
rm
setup.h
2475
0644
edit
dl
rm
set_memory.h
1160
0644
edit
dl
rm
sfp-machine.h
12676
0644
edit
dl
rm
shmparam.h
206
0644
edit
dl
rm
signal.h
320
0644
edit
dl
rm
simple_spinlock.h
6662
0644
edit
dl
rm
simple_spinlock_types.h
481
0644
edit
dl
rm
slice.h
1121
0644
edit
dl
rm
smp.h
7804
0644
edit
dl
rm
smu.h
19789
0644
edit
dl
rm
sparsemem.h
843
0644
edit
dl
rm
spinlock.h
472
0644
edit
dl
rm
spinlock_types.h
382
0644
edit
dl
rm
spu.h
23963
0644
edit
dl
rm
spu_csa.h
6166
0644
edit
dl
rm
spu_info.h
272
0644
edit
dl
rm
spu_priv1.h
5186
0644
edit
dl
rm
sstep.h
4730
0644
edit
dl
rm
stackprotector.h
788
0644
edit
dl
rm
stacktrace.h
297
0644
edit
dl
rm
string.h
2522
0644
edit
dl
rm
svm.h
652
0644
edit
dl
rm
swab.h
173
0644
edit
dl
rm
swiotlb.h
374
0644
edit
dl
rm
switch_to.h
2966
0644
edit
dl
rm
synch.h
2067
0644
edit
dl
rm
syscall.h
3057
0644
edit
dl
rm
syscalls.h
2189
0644
edit
dl
rm
task_size_32.h
544
0644
edit
dl
rm
task_size_64.h
2390
0644
edit
dl
rm
tce.h
892
0644
edit
dl
rm
termios.h
653
0644
edit
dl
rm
thread_info.h
6166
0644
edit
dl
rm
time.h
2997
0644
edit
dl
rm
timex.h
463
0644
edit
dl
rm
tlb.h
2308
0644
edit
dl
rm
tlbflush.h
271
0644
edit
dl
rm
tm.h
624
0644
edit
dl
rm
topology.h
3536
0644
edit
dl
rm
trace.h
4695
0644
edit
dl
rm
trace_clock.h
372
0644
edit
dl
rm
tsi108.h
3264
0644
edit
dl
rm
tsi108_irq.h
3916
0644
edit
dl
rm
tsi108_pci.h
1191
0644
edit
dl
rm
types.h
822
0644
edit
dl
rm
uaccess.h
14288
0644
edit
dl
rm
udbg.h
2003
0644
edit
dl
rm
uic.h
403
0644
edit
dl
rm
ultravisor-api.h
941
0644
edit
dl
rm
ultravisor.h
2101
0644
edit
dl
rm
uninorth.h
8410
0644
edit
dl
rm
unistd.h
1445
0644
edit
dl
rm
uprobes.h
801
0644
edit
dl
rm
user.h
2192
0644
edit
dl
rm
vas.h
7580
0644
edit
dl
rm
vdso.h
1096
0644
edit
dl
rm
vdso_datapage.h
3570
0644
edit
dl
rm
vermagic.h
490
0644
edit
dl
rm
vga.h
1273
0644
edit
dl
rm
vio.h
4734
0644
edit
dl
rm
vmalloc.h
554
0644
edit
dl
rm
word-at-a-time.h
4878
0644
edit
dl
rm
xics.h
4539
0644
edit
dl
rm
xive-regs.h
5083
0644
edit
dl
rm
xive.h
5191
0644
edit
dl
rm
xmon.h
733
0644
edit
dl
rm
xor.h
1017
0644
edit
dl
rm
xor_altivec.h
683
0644
edit
dl
rm
Edit:
/usr/src/linux-headers-5.15.0-190/arch/powerpc/include/asm/pci-bridge.h
(9481B)
/* SPDX-License-Identifier: GPL-2.0-or-later */ #ifndef _ASM_POWERPC_PCI_BRIDGE_H #define _ASM_POWERPC_PCI_BRIDGE_H #ifdef __KERNEL__ /* */ #include <linux/pci.h> #include <linux/list.h> #include <linux/ioport.h> #include <linux/numa.h> struct device_node; /* * PCI controller operations */ struct pci_controller_ops { void (*dma_dev_setup)(struct pci_dev *pdev); void (*dma_bus_setup)(struct pci_bus *bus); bool (*iommu_bypass_supported)(struct pci_dev *pdev, u64 mask); int (*probe_mode)(struct pci_bus *bus); /* Called when pci_enable_device() is called. Returns true to * allow assignment/enabling of the device. */ bool (*enable_device_hook)(struct pci_dev *pdev); void (*disable_device)(struct pci_dev *pdev); void (*release_device)(struct pci_dev *pdev); /* Called during PCI resource reassignment */ resource_size_t (*window_alignment)(struct pci_bus *bus, unsigned long type); void (*setup_bridge)(struct pci_bus *bus, unsigned long type); void (*reset_secondary_bus)(struct pci_dev *pdev); #ifdef CONFIG_PCI_MSI int (*setup_msi_irqs)(struct pci_dev *pdev, int nvec, int type); void (*teardown_msi_irqs)(struct pci_dev *pdev); #endif void (*shutdown)(struct pci_controller *hose); }; /* * Structure of a PCI controller (host bridge) */ struct pci_controller { struct pci_bus *bus; char is_dynamic; #ifdef CONFIG_PPC64 int node; #endif struct device_node *dn; struct list_head list_node; struct device *parent; int first_busno; int last_busno; int self_busno; struct resource busn; void __iomem *io_base_virt; #ifdef CONFIG_PPC64 void __iomem *io_base_alloc; #endif resource_size_t io_base_phys; resource_size_t pci_io_size; /* Some machines have a special region to forward the ISA * "memory" cycles such as VGA memory regions. Left to 0 * if unsupported */ resource_size_t isa_mem_phys; resource_size_t isa_mem_size; struct pci_controller_ops controller_ops; struct pci_ops *ops; unsigned int __iomem *cfg_addr; void __iomem *cfg_data; /* * Used for variants of PCI indirect handling and possible quirks: * SET_CFG_TYPE - used on 4xx or any PHB that does explicit type0/1 * EXT_REG - provides access to PCI-e extended registers * SURPRESS_PRIMARY_BUS - we suppress the setting of PCI_PRIMARY_BUS * on Freescale PCI-e controllers since they used the PCI_PRIMARY_BUS * to determine which bus number to match on when generating type0 * config cycles * NO_PCIE_LINK - the Freescale PCI-e controllers have issues with * hanging if we don't have link and try to do config cycles to * anything but the PHB. Only allow talking to the PHB if this is * set. * BIG_ENDIAN - cfg_addr is a big endian register * BROKEN_MRM - the 440EPx/GRx chips have an errata that causes hangs on * the PLB4. Effectively disable MRM commands by setting this. * FSL_CFG_REG_LINK - Freescale controller version in which the PCIe * link status is in a RC PCIe cfg register (vs being a SoC register) */ #define PPC_INDIRECT_TYPE_SET_CFG_TYPE 0x00000001 #define PPC_INDIRECT_TYPE_EXT_REG 0x00000002 #define PPC_INDIRECT_TYPE_SURPRESS_PRIMARY_BUS 0x00000004 #define PPC_INDIRECT_TYPE_NO_PCIE_LINK 0x00000008 #define PPC_INDIRECT_TYPE_BIG_ENDIAN 0x00000010 #define PPC_INDIRECT_TYPE_BROKEN_MRM 0x00000020 #define PPC_INDIRECT_TYPE_FSL_CFG_REG_LINK 0x00000040 u32 indirect_type; /* Currently, we limit ourselves to 1 IO range and 3 mem * ranges since the common pci_bus structure can't handle more */ struct resource io_resource; struct resource mem_resources[3]; resource_size_t mem_offset[3]; int global_number; /* PCI domain number */ resource_size_t dma_window_base_cur; resource_size_t dma_window_size; #ifdef CONFIG_PPC64 unsigned long buid; struct pci_dn *pci_data; #endif /* CONFIG_PPC64 */ void *private_data; /* IRQ domain hierarchy */ struct irq_domain *dev_domain; struct irq_domain *msi_domain; struct fwnode_handle *fwnode; }; /* These are used for config access before all the PCI probing has been done. */ extern int early_read_config_byte(struct pci_controller *hose, int bus, int dev_fn, int where, u8 *val); extern int early_read_config_word(struct pci_controller *hose, int bus, int dev_fn, int where, u16 *val); extern int early_read_config_dword(struct pci_controller *hose, int bus, int dev_fn, int where, u32 *val); extern int early_write_config_byte(struct pci_controller *hose, int bus, int dev_fn, int where, u8 val); extern int early_write_config_word(struct pci_controller *hose, int bus, int dev_fn, int where, u16 val); extern int early_write_config_dword(struct pci_controller *hose, int bus, int dev_fn, int where, u32 val); extern int early_find_capability(struct pci_controller *hose, int bus, int dev_fn, int cap); extern void setup_indirect_pci(struct pci_controller* hose, resource_size_t cfg_addr, resource_size_t cfg_data, u32 flags); extern int indirect_read_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 *val); extern int __indirect_read_config(struct pci_controller *hose, unsigned char bus_number, unsigned int devfn, int offset, int len, u32 *val); extern int indirect_write_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 val); static inline struct pci_controller *pci_bus_to_host(const struct pci_bus *bus) { return bus->sysdata; } #ifndef CONFIG_PPC64 extern int pci_device_from_OF_node(struct device_node *node, u8 *bus, u8 *devfn); extern void pci_create_OF_bus_map(void); #else /* CONFIG_PPC64 */ /* * PCI stuff, for nodes representing PCI devices, pointed to * by device_node->data. */ struct iommu_table; struct pci_dn { int flags; #define PCI_DN_FLAG_IOV_VF 0x01 #define PCI_DN_FLAG_DEAD 0x02 /* Device has been hot-removed */ int busno; /* pci bus number */ int devfn; /* pci device and function number */ int vendor_id; /* Vendor ID */ int device_id; /* Device ID */ int class_code; /* Device class code */ struct pci_dn *parent; struct pci_controller *phb; /* for pci devices */ struct iommu_table_group *table_group; /* for phb's or bridges */ int pci_ext_config_space; /* for pci devices */ #ifdef CONFIG_EEH struct eeh_dev *edev; /* eeh device */ #endif #define IODA_INVALID_PE 0xFFFFFFFF unsigned int pe_number; #ifdef CONFIG_PCI_IOV u16 vfs_expanded; /* number of VFs IOV BAR expanded */ u16 num_vfs; /* number of VFs enabled*/ unsigned int *pe_num_map; /* PE# for the first VF PE or array */ bool m64_single_mode; /* Use M64 BAR in Single Mode */ #define IODA_INVALID_M64 (-1) int (*m64_map)[PCI_SRIOV_NUM_BARS]; /* Only used on powernv */ int last_allow_rc; /* Only used on pseries */ #endif /* CONFIG_PCI_IOV */ int mps; /* Maximum Payload Size */ struct list_head child_list; struct list_head list; struct resource holes[PCI_SRIOV_NUM_BARS]; }; /* Get the pointer to a device_node's pci_dn */ #define PCI_DN(dn) ((struct pci_dn *) (dn)->data) extern struct pci_dn *pci_get_pdn_by_devfn(struct pci_bus *bus, int devfn); extern struct pci_dn *pci_get_pdn(struct pci_dev *pdev); extern struct pci_dn *pci_add_device_node_info(struct pci_controller *hose, struct device_node *dn); extern void pci_remove_device_node_info(struct device_node *dn); #ifdef CONFIG_PCI_IOV struct pci_dn *add_sriov_vf_pdns(struct pci_dev *pdev); void remove_sriov_vf_pdns(struct pci_dev *pdev); #endif static inline int pci_device_from_OF_node(struct device_node *np, u8 *bus, u8 *devfn) { if (!PCI_DN(np)) return -ENODEV; *bus = PCI_DN(np)->busno; *devfn = PCI_DN(np)->devfn; return 0; } #if defined(CONFIG_EEH) static inline struct eeh_dev *pdn_to_eeh_dev(struct pci_dn *pdn) { return pdn ? pdn->edev : NULL; } #else #define pdn_to_eeh_dev(x) (NULL) #endif /** Find the bus corresponding to the indicated device node */ extern struct pci_bus *pci_find_bus_by_node(struct device_node *dn); /** Remove all of the PCI devices under this bus */ extern void pci_hp_remove_devices(struct pci_bus *bus); /** Discover new pci devices under this bus, and add them */ extern void pci_hp_add_devices(struct pci_bus *bus); extern int pcibios_unmap_io_space(struct pci_bus *bus); extern int pcibios_map_io_space(struct pci_bus *bus); #ifdef CONFIG_NUMA #define PHB_SET_NODE(PHB, NODE) ((PHB)->node = (NODE)) #else #define PHB_SET_NODE(PHB, NODE) ((PHB)->node = NUMA_NO_NODE) #endif #endif /* CONFIG_PPC64 */ /* Get the PCI host controller for an OF device */ extern struct pci_controller *pci_find_hose_for_OF_device( struct device_node* node); extern struct pci_controller *pci_find_controller_for_domain(int domain_nr); /* Fill up host controller resources from the OF node */ extern void pci_process_bridge_OF_ranges(struct pci_controller *hose, struct device_node *dev, int primary); /* Allocate & free a PCI host bridge structure */ extern struct pci_controller *pcibios_alloc_controller(struct device_node *dev); extern void pcibios_free_controller(struct pci_controller *phb); extern void pcibios_free_controller_deferred(struct pci_host_bridge *bridge); #ifdef CONFIG_PCI extern int pcibios_vaddr_is_ioport(void __iomem *address); #else static inline int pcibios_vaddr_is_ioport(void __iomem *address) { return 0; } #endif /* CONFIG_PCI */ #endif /* __KERNEL__ */ #endif /* _ASM_POWERPC_PCI_BRIDGE_H */
Save
cmd:
run