Skip to Content
axiomos-simContractsRP1 Driver Coverage

RP1 Driver Coverage

Relevant source files (branch fix/adapter-pid-readiness; not on main)

Not on main. This is a source-only inventory of the axiomOS RP1 driver at commit a6f48d1. It records register operations a simulator scenario may need to observe; it does not assert any hardware effect has been qualified. The pinned source is associated with a virt,cloud-profile build; no Pi-target producer manifest or Pi qualification evidence exists.

Address map assumed by the driver

The driver assumes firmware has pre-mapped RP1 peripherals; phys_to_virt converts physical addresses, and register helpers use volatile 32-bit accesses (PCIe helpers add dsb osh).

BlockPhysical base / RP1 offset
RP1 BAR1 peripheral aperture0x1f_0000_0000
BCM2712 PCIe2 root complex0x10_0012_0000
BCM2712 MIP00x10_0013_0000
RP1 IO_BANK0 (GPIO)0x000d_0000
RP1 PADS_BANK00x000f_0000
RP1 PWM0 / PWM10x0009_8000 / 0x0009_c000
RP1 PCIe APBS0x0010_8000

GPIO IRQ route sequence

initialize_gpio_route() performs:

The link status is checked once with no retry. The GIC uses IRQ 160, edge-triggered, priority 0x80. At this commit the only caller is the Pi5-gated bench::init() path; general platform init() does not call it. The interrupt handler snapshots PCIe pending pins, reads event bits, clears each via IRQRESET before dispatch to BPF, then IACKs RP1 vector 0.

Selected PCIe/config operations:

OperationOffsetCheck
PCIe link statusRC +0x4068Bits 4 and 5 set, else PcieLinkDown
RC bus numbersRC +0x18Write 0x0001_0100, read back
RP1 vendor/deviceconfig +0x00Must equal 0x0001_1de4
BAR0 / BAR1 / BAR2config +0x10/+0x14/+0x18BAR0 8 MiB, BAR1 0, BAR2 4 MiB in PCIe window
MSI-X tableBAR0 + table offset, 16-byte strideMask all, program vector 0 to 0xff_ffff_f000, unmask, read back
MIP host config / mask, VPU maskMIP0 +0x20/+0x30, +0x40/+0x50, +0x60/+0x70All read back
MSI-X local config 0APBS +0x008 via +0xc00/+0x800 aliasesEnable bit 0, IACK-enable bit 3

Outbound-window writes and RP1 command bits have no dedicated readback. PCI status write-one-to-clear effects are unresolved.

GPIO registers used

28 GPIOs, 8-byte per-pin stride, 32-bit accesses. Atomic aliases +0x2000 set and +0x3000 clear.

RegisterOffset / fieldsDriver behavior
STATUSpin +0x00Read-only; input bit 17; events bits 20-23
CTRLpin +0x04FUNCSEL 4:0; OUTOVER 13:12; OEOVER 15:14; IRQ enables 20-23; IRQRESET bit 28
Raw interrupt status+0x100Masked to 28 bits
PCIe interrupt enable / status+0x11c / +0x124Enable via aliases; pending bitmap
PADS_BANK0 pad+0x04 + 4*pinSchmitt bit 1, pull 3:2, IE bit 6, OD bit 7

Output setup forces OUTOVER low/high (2/3), OEOVER enabled (3), enables pad input and clears OD. Input setup disables OEOVER and enables pad input plus Schmitt. Only rising/falling edge interrupts are exposed; no drive-strength, debounce, or level-event API.

PWM registers used

RegisterRP1 offsetWrites
CLOCKS PWM0 CTRL0x18000 + 0x74AUXSRC = 2 (xosc), SRC = 1 (AUX), enable bit 11
CLOCKS PWM0 DIV_INT / DIV_FRAC0x18000 + 0x78/0x7c1 / 0
GLOBAL_CTRLcontroller +0x00Channel enables 0-3; SET_UPDATE bit 31
Channel CTRL0x14 + 0x10*n0x101 default
Channel RANGE0x18 + 0x10*n50_000_000 / Hz (50 MHz is an assumption)
Channel DUTY0x20 + 0x10*nrange * percent / 100, percent clamped to 100

API channels 1-4 map to hardware channels 0-3. Init writes GLOBAL_CTRL 0x8000_0000. No range, duty, or enable value is read back. enable_pwm0_clock() is called only in the bench PWM path; PWM1 clock setup is absent.

Remaining gates

A simulator needs BCM2712 PCIe2 root complex and MIP0 behavior plus RP1 BAR/config, GPIO, pads, PWM, and APBS/MSI-X behavior. The Renode audit found no stock BCM2712 root-complex or RP1 endpoint model. Remaining gates: a Pi-target identified producer manifest, confirmed datasheet semantics for ambiguous registers, modeled side effects and interrupt delivery, then independent Pi hardware observations. Source-derived simulator tests validate driver expectations only.

Last updated on