Yea and adding that together gives 0x40108000, which is the start of the PCIe config registers. This address refers to the first register in it, which is the DBI register I mentioned earlier (see also "6.1. PCIe endpoint configuration registers" from RP1 data sheet). Now the macro, does thisthat macro is relative to this:which is the offset from the start of the main (MM)IO BAR, 0x108000Code:
rp1->msix_cfg_regs = ioremap(rp1_io_to_phys(rp1, RP1_PCIE_APBS_BASE), 0x1000);
Code:
#define MSIX_CFG(x) (0x8 + (4 * (x)))Code:
static void msix_cfg_set(struct rp1_dev *rp1, unsigned int hwirq, u32 value){writel(value, rp1->msix_cfg_regs + REG_SET + MSIX_CFG(hwirq));}Statistics: Posted by wolfre — Mon Aug 25, 2025 2:48 pm