1menuconfig PCI
2	bool "PCI support"
3	depends on DM
4	default y if PPC
5	help
6	  Enable support for PCI (Peripheral Interconnect Bus), a type of bus
7	  used on some devices to allow the CPU to communicate with its
8	  peripherals.
9
10	  This subsystem requires driver model.
11
12if PCI
13
14config DM_PCI_COMPAT
15	bool "Enable compatible functions for PCI"
16	help
17	  Enable compatibility functions for PCI so that old code can be used
18	  with CONFIG_PCI enabled. This should be used as an interim
19	  measure when porting a board to use driver model for PCI. Once the
20	  board is fully supported, this option should be disabled.
21
22config SYS_PCI_64BIT
23	bool "Enable 64-bit PCI resources"
24	default y if PPC
25	help
26	  Enable 64-bit PCI resource access.
27
28config PCI_AARDVARK
29	bool "Enable Aardvark PCIe driver"
30	depends on DM_GPIO
31	depends on ARMADA_3700
32	help
33	  Say Y here if you want to enable PCIe controller support on
34	  Armada37x0 SoCs. The PCIe controller on Armada37x0 is based on
35	  Aardvark hardware.
36
37config PCI_PNP
38	bool "Enable Plug & Play support for PCI"
39	default y
40	help
41	  Enable PCI memory and I/O space resource allocation and assignment.
42
43config PCI_REGION_MULTI_ENTRY
44	bool "Enable Multiple entries of region type MEMORY in ranges for PCI"
45	help
46	  Enable PCI memory regions to be of multiple entry. Multiple entry
47	  here refers to allow more than one count of address ranges for MEMORY
48	  region type. This helps to add support for SoC's like OcteonTX/TX2
49	  where every peripheral is on the PCI bus.
50
51config PCI_CONFIG_HOST_BRIDGE
52	bool "Configure PCI host bridges"
53	default y if X86
54
55config PCI_MAP_SYSTEM_MEMORY
56	bool "Map local system memory from a virtual base address"
57	depends on MIPS
58	help
59	  Say Y if base address of system memory is being used as a virtual address
60	  instead of a physical address (e.g. on MIPS). The PCI core will then remap
61	  the virtual memory base address to a physical address when adding the PCI
62	  region of type PCI_REGION_SYS_MEMORY.
63	  This should only be required on MIPS where CFG_SYS_SDRAM_BASE is still
64	  being used as virtual address.
65
66config PCI_SRIOV
67	bool "Enable Single Root I/O Virtualization support for PCI"
68	help
69	  Say Y here if you want to enable PCI Single Root I/O Virtualization
70	  capability support. This helps to enumerate Virtual Function devices
71	  if available on a PCI Physical Function device and probe for
72	  applicable drivers.
73
74config PCI_ENHANCED_ALLOCATION
75	bool "Enable support for Enhanced Allocation of resources"
76	default y
77	help
78	  Enable support for Enhanced Allocation which can be used by supported
79	  devices in place of traditional BARS for allocation of resources.
80
81config PCI_ARID
82        bool "Enable Alternate Routing-ID support for PCI"
83        help
84          Say Y here if you want to enable Alternate Routing-ID capability
85          support on PCI devices. This helps to skip some devices in BDF
86          scan that are not present.
87
88config PCI_SCAN_SHOW
89	bool "Show PCI devices during startup"
90	depends on PCIE_IMX
91
92config PCIE_ECAM_GENERIC
93	bool "Generic ECAM-based PCI host controller support"
94	help
95	  Say Y here if you want to enable support for generic ECAM-based
96	  PCIe host controllers, such as the one emulated by QEMU.
97
98config PCIE_ECAM_SYNQUACER
99	bool "SynQuacer ECAM-based PCI host controller support"
100	select PCI_INIT_R
101	select PCI_REGION_MULTI_ENTRY
102	help
103	  Say Y here if you want to enable support for Socionext
104	  SynQuacer SoC's ECAM-based PCIe host controllers.
105	  Note that this must be configured when boot because Linux driver
106	  expects the PCIe RC has been configured in the bootloader.
107
108config PCIE_APPLE
109	bool "Enable Apple PCIe driver"
110	depends on ARCH_APPLE
111	imply PCI_INIT_R
112	default y
113	help
114	  Say Y here if you want to enable PCIe controller support on
115	  Apple SoCs.
116
117config PCI_GT64120
118	bool "GT64120 PCI support"
119	depends on MIPS
120
121config PCI_PHYTIUM
122	bool "Phytium PCIe support"
123	help
124	  Say Y here if you want to enable PCIe controller support on
125	  Phytium SoCs.
126
127config PCIE_DW_MVEBU
128	bool "Enable Armada-8K PCIe driver (DesignWare core)"
129	depends on ARMADA_8K
130	help
131	  Say Y here if you want to enable PCIe controller support on
132	  Armada-8K SoCs. The PCIe controller on Armada-8K is based on
133	  DesignWare hardware.
134
135config PCIE_DW_SIFIVE
136	bool "Enable SiFive FU740 PCIe"
137	depends on CLK_SIFIVE_PRCI
138	depends on RESET_SIFIVE
139	depends on SIFIVE_GPIO
140	select PCIE_DW_COMMON
141	help
142	  Say Y here if you want to enable PCIe controller support on
143	  FU740.
144
145config SYS_FSL_PCI_VER_3_X
146	bool
147
148config PCIE_FSL
149	bool "FSL PowerPC PCIe support"
150	select SYS_FSL_PCI_VER_3_X if ARCH_T2080 || ARCH_T4240
151	help
152	  Say Y here if you want to enable PCIe controller support on FSL
153	  PowerPC MPC85xx, MPC86xx, B series, P series and T series SoCs.
154	  This driver does not support SRIO_PCIE_BOOT feature.
155
156config PCI_MPC85XX
157	bool "MPC85XX PowerPC PCI support"
158	help
159	  Say Y here if you want to enable PCI controller support on FSL
160	  PowerPC MPC85xx SoC.
161
162config PCI_MSC01
163	bool "MSC01 PCI support"
164	depends on TARGET_MALTA
165
166config PCI_RCAR_GEN2
167	bool "Renesas RCar Gen2 PCIe driver"
168	depends on RCAR_32
169	help
170	  Say Y here if you want to enable PCIe controller support on
171	  Renesas RCar Gen2 SoCs. The PCIe controller on RCar Gen2 is
172	  also used to access EHCI USB controller on the SoC.
173
174config PCI_RCAR_GEN3
175	bool "Renesas RCar Gen3 PCIe driver"
176	depends on RCAR_GEN3
177	help
178	  Say Y here if you want to enable PCIe controller support on
179	  Renesas RCar Gen3 SoCs.
180
181config PCI_SANDBOX
182	bool "Sandbox PCI support"
183	depends on SANDBOX
184	help
185	  Support PCI on sandbox, as an emulated bus. This permits testing of
186	  PCI feature such as bus scanning, device configuration and device
187	  access. The available (emulated) devices are defined statically in
188	  the device tree but the normal PCI scan technique is used to find
189	  then.
190
191config SH7751_PCI
192	bool "SH7751 PCI controller support"
193	depends on SH
194	help
195	  SuperH PCI Bridge Configuration
196
197config PCI_TEGRA
198	bool "Tegra PCI support"
199	depends on ARCH_TEGRA
200	depends on (TEGRA186 && POWER_DOMAIN) || (!TEGRA186)
201	help
202	  Enable support for the PCIe controller found on some generations of
203	  Tegra. Tegra20 has 2 root ports with a total of 4 lanes, Tegra30 has
204	  3 root ports with a total of 6 lanes and Tegra124 has 2 root ports
205	  with a total of 5 lanes. Some boards require this for Ethernet
206	  support to work (e.g. beaver, jetson-tk1).
207
208config PCI_OCTEONTX
209	bool "OcteonTX PCI support"
210	depends on (ARCH_OCTEONTX || ARCH_OCTEONTX2)
211	help
212	  Enable support for the OcteonTX/TX2 SoC family ECAM/PEM controllers.
213	  These controllers provide PCI configuration access to all on-board
214	  peripherals so it should only be disabled for testing purposes
215
216config PCIE_OCTEON
217	bool "MIPS Octeon PCIe support"
218	depends on ARCH_OCTEON
219	help
220	  Enable support for the MIPS Octeon SoC family PCIe controllers.
221
222config PCI_XILINX
223	bool "Xilinx AXI Bridge for PCI Express"
224	help
225	  Enable support for the Xilinx AXI bridge for PCI express, an IP block
226	  which can be used on some generations of Xilinx FPGAs.
227
228config PCIE_LAYERSCAPE
229	bool
230
231config PCIE_LAYERSCAPE_RC
232	bool "Layerscape PCIe Root Complex mode support"
233	select PCIE_LAYERSCAPE
234	help
235	  Enable Layerscape PCIe Root Complex mode driver support. The Layerscape
236	  SoC may have one or several PCIe controllers. Each controller can be
237	  configured to Root Complex mode by clearing the corresponding bit of
238	  RCW[HOST_AGT_PEX].
239
240config PCI_IOMMU_EXTRA_MAPPINGS
241	bool "Support for specifying extra IOMMU mappings for PCI"
242	depends on PCIE_LAYERSCAPE_RC
243	help
244	  Enable support for specifying extra IOMMU mappings for PCI
245	  controllers through a special env var called "pci_iommu_extra" or
246	  through a device tree property named "pci-iommu-extra" placed in
247	  the node describing the PCI controller.
248	  The intent is to cover SR-IOV scenarios which need mappings for VFs
249	  and PCI hot-plug scenarios. More documentation can be found under:
250	    arch/arm/cpu/armv8/fsl-layerscape/doc/README.pci_iommu_extra
251
252config PCIE_LAYERSCAPE_EP
253	bool "Layerscape PCIe Endpoint mode support"
254	select PCIE_LAYERSCAPE
255	select PCI_ENDPOINT
256	help
257	  Enable Layerscape PCIe Endpoint mode driver support. The Layerscape
258	  SoC may have one or several PCIe controllers. Each controller can be
259	  configured to Endpoint mode by setting the corresponding bit of
260	  RCW[HOST_AGT_PEX].
261
262config PCIE_LAYERSCAPE_GEN4
263	bool "Layerscape Gen4 PCIe support"
264	help
265	  Support PCIe Gen4 on NXP Layerscape SoCs, which may have one or
266	  several PCIe controllers. The PCIe controller can work in RC or
267	  EP mode according to RCW[HOST_AGT_PEX] setting.
268
269config FSL_PCIE_COMPAT
270	string "PCIe compatible of Kernel DT"
271	depends on PCIE_LAYERSCAPE_RC || PCIE_LAYERSCAPE_GEN4
272	default "fsl,ls1012a-pcie" if ARCH_LS1012A
273	default "fsl,ls1028a-pcie" if ARCH_LS1028A
274	default "fsl,ls1043a-pcie" if ARCH_LS1043A
275	default "fsl,ls1046a-pcie" if ARCH_LS1046A
276	default "fsl,ls2080a-pcie" if ARCH_LS2080A
277	default "fsl,ls1088a-pcie" if ARCH_LS1088A
278	default "fsl,ls2088a-pcie" if ARCH_LX2160A || ARCH_LX2162A
279	default "fsl,ls1021a-pcie" if ARCH_LS1021A
280	help
281	  This compatible is used to find pci controller node in Kernel DT
282	  to complete fixup.
283
284config FSL_PCIE_EP_COMPAT
285	string "PCIe EP compatible of Kernel DT"
286	depends on PCIE_LAYERSCAPE_RC || PCIE_LAYERSCAPE_GEN4
287	default "fsl,ls-pcie-ep"
288	help
289	  This compatible is used to find pci controller ep node in Kernel DT
290	  to complete fixup.
291
292config PCIE_IMX
293	bool "i.MX PCIe support"
294	depends on ARCH_MX6
295
296config PCIE_INTEL_FPGA
297	bool "Intel FPGA PCIe support"
298	help
299	  Say Y here if you want to enable PCIe controller support on Intel
300	  FPGA, example Stratix 10.
301
302config PCIE_IPROC
303	bool "Iproc PCIe support"
304	help
305	  Broadcom iProc PCIe controller driver.
306	  Say Y here if you want to enable Broadcom iProc PCIe controller,
307
308config PCI_MVEBU
309	bool "Enable Kirkwood / Armada 370/XP/375/38x PCIe driver"
310	depends on (ARCH_KIRKWOOD || ARCH_MVEBU)
311	select MISC
312	select DM_RESET
313	select DM_GPIO
314	help
315	  Say Y here if you want to enable PCIe controller support on
316	  Kirkwood and Armada 370/XP/375/38x SoCs.
317
318config PCIE_DW_COMMON
319	bool
320
321config PCI_KEYSTONE
322	bool "TI Keystone PCIe controller"
323	select PCIE_DW_COMMON
324	help
325	  Say Y here if you want to enable PCI controller support on AM654 SoC.
326
327config PCIE_MEDIATEK
328	bool "MediaTek PCIe Gen2 controller"
329	depends on ARCH_MEDIATEK
330	help
331	  Say Y here if you want to enable Gen2 PCIe controller,
332	  which could be found on MT7623 SoC family.
333
334config PCIE_DW_MESON
335	bool "Amlogic Meson DesignWare based PCIe controller"
336	depends on ARCH_MESON
337	select PCIE_DW_COMMON
338	help
339	  Say Y here if you want to enable DW PCIe controller support on
340	  Amlogic SoCs.
341
342config PCIE_ROCKCHIP
343	bool "Enable Rockchip PCIe driver"
344	depends on ARCH_ROCKCHIP
345	select PHY_ROCKCHIP_PCIE
346	default y if ROCKCHIP_RK3399
347	help
348	  Say Y here if you want to enable PCIe controller support on
349	  Rockchip SoCs.
350
351config PCIE_DW_ROCKCHIP
352	bool "Rockchip DesignWare based PCIe controller"
353	depends on ARCH_ROCKCHIP
354	select PCIE_DW_COMMON
355	select PHY_ROCKCHIP_SNPS_PCIE3
356	help
357	  Say Y here if you want to enable DW PCIe controller support on
358	  Rockchip SoCs.
359
360config PCI_BRCMSTB
361	bool "Broadcom STB PCIe controller"
362	depends on ARCH_BCM283X
363	help
364	  Say Y here if you want to enable support for PCIe controller
365	  on Broadcom set-top-box (STB) SoCs.
366	  This driver currently supports only BCM2711 SoC and RC mode
367	  of the controller.
368
369config PCIE_UNIPHIER
370	bool "Socionext UniPhier PCIe driver"
371	depends on ARCH_UNIPHIER
372	select PHY_UNIPHIER_PCIE
373	help
374	  Say Y here if you want to enable PCIe controller support on
375	  UniPhier SoCs.
376
377endif
378