STRUCT MTK_GEN3_PCIE(9)
β¨ struct mtk_gen3_pcie(9) β Kernel API Manual vibes β¨
okay so bestie, welcome to the struct mtk_gen3_pcie(9) page!! π this is the group chat where every single box of info about one PCIe port lives β all the fields, all the resets, all the lock drama. no cap, it's all here, and we're gonna go through it together π«Ά
πΈ NAME πΈ
struct mtk_gen3_pcie β literally just "PCIe port information", that's the whole vibe β¨
π SYNOPSIS π
struct mtk_gen3_pcie {
struct device *dev;
void __iomem *base;
phys_addr_t reg_base;
struct reset_control *mac_reset;
struct reset_control_bulk_data phy_resets[MAX_NUM_PHY_RESETS];
struct phy *phy;
struct clk_bulk_data *clks;
int num_clks;
u8 max_link_speed;
u8 num_lanes;
int irq;
u32 saved_irq_state;
raw_spinlock_t irq_lock;
struct irq_domain *intx_domain;
struct irq_domain *msi_bottom_domain;
struct mtk_msi_set msi_sets[PCIE_MSI_SET_NUM];
struct mutex lock;
unsigned long msi_irq_in_use[BITS_TO_LONGS( PCIE_MSI_IRQS_NUM)];
const struct mtk_gen3_pcie_pdata *soc;
};
like, look at her. she's got everything π
π Members π
devβ pointer to the PCIe device, the main character herself πbaseβ IO mapped register base, where the register magic happens β¨reg_baseβ physical register base, the real-world address bestie πΊοΈmac_resetβ MAC reset control, for when things need a little reset moment πphy_resetsβ PHY reset controllers (plural, she's got a whole array of them) πphyβ PHY controller block, iconic hardware energy π¦clksβ PCIe clocks, we love a timely queen β°num_clksβ PCIe clocks count for this port, the receipts π’max_link_speedβ maximum link speed (PCIe Gen) for this port, she's fast fr fr ποΈnum_lanesβ number of PCIe lanes for this port, staying in her lane(s) πirqβ PCIe controller interrupt number, the interrupt's own little id πsaved_irq_stateβ IRQ enable state saved at suspend time, so she remembers where she left off π΄irq_lockβ lock protecting IRQ register access, no cutting in line πintx_domainβ legacy INTx IRQ domain, the old-school icon πmsi_bottom_domainβ MSI IRQ bottom domain, bottom but still thriving πmsi_setsβ MSI sets information, the whole collection πlockβ lock protecting IRQ bit map, another lock, she's careful okay πmsi_irq_in_useβ bit map for assigned MSI IRQ, tracking who's taken πsocβ pointer to SoC-dependent operations, the plot twists live here π
π¦ SEE ALSO π¦
./drivers/pci/controller/pcie-mediatek-gen3.cstruct mtk_gen3_pcie_pdata(9)struct mtk_msi_set(9)mtk_pcie_config_tlp_header(9)mtk_intx_eoi(9)
go read those too, iykyk πβ¨
that's the whole page bestie, you ate that ππ this came to you from ./drivers/pci/controller, dated October 2026 β mwah, slay, periodt π
ππ₯
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms