drivers/pci/controller/pcie-iproc.c
Source file repositories/reference/linux-study-clean/drivers/pci/controller/pcie-iproc.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/pci/controller/pcie-iproc.c- Extension
.c- Size
- 41961 bytes
- Lines
- 1587
- Domain
- Representative Device Path
- Bucket
- PCIe NVMe Storage Path
- Inferred role
- Representative Device Path: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
Part of the selected hardware vertical slice: PCI discovery, driver binding, NVMe queues, block requests, DMA, interrupts, and completion.
- Part of the selected hardware vertical slice: PCI discovery, driver binding, NVMe queues, block requests, DMA, interrupts, and completion.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/kernel.hlinux/pci.hlinux/pci-ecam.hlinux/msi.hlinux/clk.hlinux/module.hlinux/mbus.hlinux/slab.hlinux/delay.hlinux/interrupt.hlinux/irqchip/arm-gic-v3.hlinux/platform_device.hlinux/of_address.hlinux/of_irq.hlinux/of_pci.hlinux/of_platform.hlinux/phy/phy.hpcie-iproc.h
Detected Declarations
struct iproc_pcie_ob_mapstruct iproc_pcie_ib_mapenum iproc_pcie_ib_map_typeenum iproc_pcie_regfunction iproc_pcie_reg_is_invalidfunction iproc_pcie_reg_offsetfunction iproc_pcie_read_regfunction iproc_pcie_write_regfunction iproc_pcie_apb_err_disablefunction iproc_pcie_cfg_retryfunction iproc_pcie_fix_capfunction iproc_pcie_config_readfunction iproc_pci_raw_config_read32function iproc_pci_raw_config_write32function iproc_pcie_config_read32function iproc_pcie_config_write32function iproc_pcie_perst_ctrlfunction iproc_pcie_shutdownfunction iproc_pcie_check_linkfunction iproc_pcie_enablefunction iproc_pcie_ob_is_validfunction iproc_pcie_ob_writefunction iproc_pcie_setup_obfunction iproc_pcie_map_rangesfunction resource_list_for_each_entryfunction iproc_pcie_ib_is_in_usefunction iproc_pcie_ib_check_typefunction iproc_pcie_ib_writefunction iproc_pcie_setup_ibfunction iproc_pcie_map_dma_rangesfunction resource_list_for_each_entryfunction iproc_pcie_invalidate_mappingfunction iproce_pcie_get_msifunction iproc_pcie_paxb_v2_msi_steerfunction iproc_pcie_paxc_v2_msi_steerfunction iproc_pcie_msi_steerfunction iproc_pcie_msi_enablefunction iproc_pcie_msi_disablefunction iproc_pcie_rev_initfunction iproc_pcie_setupfunction for_each_pci_bridgefunction iproc_pcie_removefunction quirk_paxc_disable_msi_parsingfunction quirk_paxc_bridgeexport iproc_pcie_shutdownexport iproc_pcie_setupexport iproc_pcie_remove
Annotated Snippet
struct iproc_pcie_ob_map {
resource_size_t window_sizes[MAX_NUM_OB_WINDOW_SIZES];
unsigned int nr_sizes;
};
static const struct iproc_pcie_ob_map paxb_ob_map[] = {
{
/* OARR0/OMAP0 */
.window_sizes = { 128, 256 },
.nr_sizes = 2,
},
{
/* OARR1/OMAP1 */
.window_sizes = { 128, 256 },
.nr_sizes = 2,
},
};
static const struct iproc_pcie_ob_map paxb_v2_ob_map[] = {
{
/* OARR0/OMAP0 */
.window_sizes = { 128, 256 },
.nr_sizes = 2,
},
{
/* OARR1/OMAP1 */
.window_sizes = { 128, 256 },
.nr_sizes = 2,
},
{
/* OARR2/OMAP2 */
.window_sizes = { 128, 256, 512, 1024 },
.nr_sizes = 4,
},
{
/* OARR3/OMAP3 */
.window_sizes = { 128, 256, 512, 1024 },
.nr_sizes = 4,
},
};
/**
* enum iproc_pcie_ib_map_type - iProc PCIe inbound mapping type
* @IPROC_PCIE_IB_MAP_MEM: DDR memory
* @IPROC_PCIE_IB_MAP_IO: device I/O memory
* @IPROC_PCIE_IB_MAP_INVALID: invalid or unused
*/
enum iproc_pcie_ib_map_type {
IPROC_PCIE_IB_MAP_MEM = 0,
IPROC_PCIE_IB_MAP_IO,
IPROC_PCIE_IB_MAP_INVALID
};
/**
* struct iproc_pcie_ib_map - iProc PCIe inbound mapping controller-specific
* parameters
* @type: inbound mapping region type
* @size_unit: inbound mapping region size unit, could be SZ_1K, SZ_1M, or
* SZ_1G
* @region_sizes: list of supported inbound mapping region sizes in KB, MB, or
* GB, depending on the size unit
* @nr_sizes: number of supported inbound mapping region sizes
* @nr_windows: number of supported inbound mapping windows for the region
* @imap_addr_offset: register offset between the upper and lower 32-bit
* IMAP address registers
* @imap_window_offset: register offset between each IMAP window
*/
struct iproc_pcie_ib_map {
enum iproc_pcie_ib_map_type type;
unsigned int size_unit;
resource_size_t region_sizes[MAX_NUM_IB_REGION_SIZES];
unsigned int nr_sizes;
unsigned int nr_windows;
u16 imap_addr_offset;
u16 imap_window_offset;
};
static const struct iproc_pcie_ib_map paxb_v2_ib_map[] = {
{
/* IARR0/IMAP0 */
.type = IPROC_PCIE_IB_MAP_IO,
.size_unit = SZ_1K,
.region_sizes = { 32 },
.nr_sizes = 1,
.nr_windows = 8,
.imap_addr_offset = 0x40,
.imap_window_offset = 0x4,
},
{
/* IARR1/IMAP1 */
Annotation
- Immediate include surface: `linux/kernel.h`, `linux/pci.h`, `linux/pci-ecam.h`, `linux/msi.h`, `linux/clk.h`, `linux/module.h`, `linux/mbus.h`, `linux/slab.h`.
- Detected declarations: `struct iproc_pcie_ob_map`, `struct iproc_pcie_ib_map`, `enum iproc_pcie_ib_map_type`, `enum iproc_pcie_reg`, `function iproc_pcie_reg_is_invalid`, `function iproc_pcie_reg_offset`, `function iproc_pcie_read_reg`, `function iproc_pcie_write_reg`, `function iproc_pcie_apb_err_disable`, `function iproc_pcie_cfg_retry`.
- Atlas domain: Representative Device Path / PCIe NVMe Storage Path.
- Implementation status: integration implementation candidate.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.