Imagination_BXM-4-64

Consolidated Register Map — SpacemiT K3 (36.56.104.183)

This document consolidates all hardware control registers (CRs) used by the host and firmware on the SpacemiT K3 PowerVR BXM-4-64 GPU.


1. Identification, Clocks, Power, and Reset

Offset Public Name (pvr_rogue_cr_defs.h) Width Usage on K3
0x0000/0x0004 ROGUE_CR_CLK_CTRL 64b Clock gating control (0x15155555 / 0x55555500 if disabled)
0x0020 ROGUE_CR_CORE_ID__PBVNC 64b RO — 0x00240038006800B7 (36.56.104.183); also used for dummy barrier reads
0x0028 ROGUE_CR_CORE_REVISION 32b RO — 0x00010000
0x0030 ROGUE_CR_DESIGNER_REV_FIELD1 32b RO — 0x00000000
0x0038 (no public name — Power HW Request) 32b Internal dust/unit power-gating control. bit0 = on/off, bit1 = trigger, bit9 = all, bits[10+i] = units, bits[24+d] = dusts. See power-management.md §2.1
0x0050 (no public name — Dust Power Mask) 32b ((1 << n_dusts) - 1) & 0xFF, with n_dusts = CR[0xF308] (1 on K3)
0x0100/0x0104 ROGUE_CR_SOFT_RESET 64b GPU block soft reset. 1 = reset asserted, 0 = released (MASKFULL = everything in reset). Firmware assert value: 0xFFEFFFF8F3FFFC1D = everything in reset except SYSARB(5), TLA(26), SLC(27), CPU/GARTEN(32), BIF1(33), and MMU(34) — the blocks that must remain alive for the firmware to write CR[0x0038] and poll. The pulse writes 0 (releases all). HWR asserts reset via OR (\|= 0x10610000 FB_TLCACHE/FBDC/FBC/BIF; \|= 0x80004 PBE/TPU); TA CSW fallback uses 0x804000 (GPP+TESS)
0x0128 ROGUE_CR_EVENT_ENABLE 32b 0x00000000 at init (events go via MTS)
0x0130 ROGUE_CR_EVENT_STATUS 32b Active event flags (supports software set: the exception vector does \|= 0x200 to re-arm MMU_PAGE_FAULT after fixing a TLB entry; clearing is W1C via 0x0138, or BCAST[0x0138] = mask). Bits: b2=CDM (0x4), b3=3D (0x8), b5=TA (0x20), b7=PM_OOM (0x80), b8=PM_3D_MEM_FREE (0x100), b9=MMU_FAULT (0x200), b10=POWER_COMPLETE (0x400), b11=POWER_ABORT (0x800), b12=GPIO (0x1000), b14=ISP_ZLS_END (0x4000), b15=USC_TRIGGER (0x8000), b19=SLAVE_REQ (0x80000)
0x0138 ROGUE_CR_EVENT_CLEAR 32b W1C — clears corresponding bits of 0x0130 (init: 0x41FC)
0x0160/0x0164 ROGUE_CR_TIMER 48b RO — GPU time counter (0x0160 lo 32b, 0x0164 & 0xFFFF hi 16b)
0x0890 ROGUE_CR_XPU_BROADCAST 32b Target core mask for broadcast writes (1 on K3 MC1)
0x08A8 (no public name — Host IRQ Assert) 32b Write 1 after barrier (0xBFC01800 = 1, ehb, sync + readback of 0xBFC01800 and 0x0020) to trigger hwirq 75 on the host CPU
0x08F0 (no public name — Slave Event Status) 32b Multicore slave request status
0xD200 (no public name — Clk Ctrl Aux) 32b 0x00000511 when DISABLE_CLKGATING_EN

2. MTS (Task Scheduler) and MIPS Wrapper

Offset Public Name Width Usage on K3
0x0B00 ROGUE_CR_MTS_SCHEDULE 32b BG task scheduling doorbell (0 = reschedule, 0x20 = post-HWR, DM+OSID from host)
0x0B08 (no public name — MTS IRQ Task Ack) 32b Write 2 at the end of HW1 to acknowledge interrupt task completion
0x0B30 ROGUE_CR_MTS_BGCTX_THREAD0_DM_ASSOC 32b 0x00000001 at init
0x0B40 ROGUE_CR_MTS_INTCTX_THREAD0_DM_ASSOC 32b 0x0000FFFF at init
0x0B58 ROGUE_CR_MTS_DM0_INTERRUPT_ENABLE 32b 0x00089200 at init
0x0B68 ROGUE_CR_MTS_DM2_INTERRUPT_ENABLE 32b 0x000000A0 at init
0x0B70 ROGUE_CR_MTS_DM3_INTERRUPT_ENABLE 32b 0x00000008 at init
0x0B78 ROGUE_CR_MTS_DM4_INTERRUPT_ENABLE 32b 0x00000004 at init
0x0BE0 ROGUE_CR_MTS_GARTEN_WRAPPER_CONFIG 64b Configured by host (OSID 0 coherence/catalogue)
0x1800 ROGUE_CR_MIPS_WRAPPER_CONFIG 64b MIPS physical boot base (configured by host)
0x0878/0x087C ROGUE_CR_MIPS_ADDR_REMAP_RANGE_CONFIG 64b Programming one of the 32 range-remap entries: MODE_ENABLE(b0), ENTRY[5:1] (= index<<1), REGION_SIZE[9:7] (0 = 4 KB … 5 = 4 MB), TRUSTED(b11), BASE_ADDR_IN[31:12], OS_ID[34:32], and ADDR_OUT[59:36] in the high word (0x087C), written as phys >> 8
0x0880 ROGUE_CR_MIPS_ADDR_REMAP_RANGE_READ 32b Entry read trigger (REQUEST b0 + ENTRY[5:1])
0x0888/0x088C ROGUE_CR_MIPS_ADDR_REMAP_RANGE_DATA 64b Read-only: value read back from the entry (used in state dumps)
0x1820..0x1888 ROGUE_CR_MIPS_ADDR_REMAP1..5_CONFIG1/2 64b 5 remap windows (host); REMAP5 (0x1880/0x1888) = BRN 63553 workaround
0xBFC01800 (MIPS VA) (Fence / Write-Buffer Drain) 32b Write 1 + ehb + sync to drain MIPS write buffers to DRAM

3. BIF, MMU, and SLC

Offset Public Name Width Usage on K3
0x1200 ROGUE_CR_BIF_CAT_BASE0 64b Reserved for Firmware / OSID 0
0x1208..0x1238 ROGUE_CR_BIF_CAT_BASE1..7 64b × 7 7 dynamic LRU Page Catalogue banks for user contexts
0x1240/0x1244 ROGUE_CR_BIF_CAT_BASE_INDEX 64b Per-DM bank selector (1..7, stride 0x80000 per core): DM0 hi [2:0], DM2/GEOM lo [2:0], DM3/FRAG lo [10:8], DM4/CDM lo [18:16]
0x1248..0x1280 (BIF-PM Catalogue ctx 0 / ctx 1) 64b × 6 Parameter Manager catalogue bases (0x1248/1250/1260 and 0x1268/1270/1280)
0x12A0 ROGUE_CR_BIF_CTRL_INVAL 32b MMU cache invalidation (0x1C or flags & 0xF); poll until == 0
0x1338 ROGUE_CR_BIFPM_READS_EXT_STATUS 32b Poll in HWR: mask 0xFFFF == 0
0x1340 (BIF Pause / Stall) 32b Bit 0: pause BIF during HWR reset (\|= 1, then &= ~1)
0x1348 (BIF/PM Mem Inval) 32b Write 1 + poll bit 0 == 0 when KCCB_CMD_MMUCACHE flag 0x10
0x1350 ROGUE_CR_BIFPM_STATUS_MMU 32b Poll in HWR: mask 0xFF == 0
0x3818 ROGUE_CR_SLC_CTRL_FLUSH_INVAL 32b Trigger SLC flush/invalidation (e.g., 0x10)
0x3820 ROGUE_CR_SLC_STATUS0 32b Completion poll for 0x3818
0x3828/0x382C ROGUE_CR_SLC_CTRL_BYPASS 64b SLC bypass policy (configured at init based on CR[0x3970])
0x3898 ROGUE_CR_SLC_IDLE 32b RO — bits [7:0] = 0xFF when all 8 SLC subunits are idle
0x3970 (no public name — SLC Size Config) 32b RO — reports configured SLC size in KiB (>= 0x80 = 128 KiB on K3)

4. Parameter Manager (PM) and Sidekick

Offset Public Name / Function Usage on K3
0x0190, 0x0198, 0x01B8 PM load/reset control 0x0190=1 (poll b0==0) HWRTData load; 0x0198=1 and 0x01B8=1 (poll b0==0) post-PR TA resume
0x01C0, 0x01C8 PM PR / 3D CSW state 0x01C0 = PR flag; 0x01C8 = 3D CSW resume (or 0)
0x0200..0x0234 Freelist loading (triggers 0x0200/0x0208, poll b0) See §6.1 for the exact map. The old map (“bases at 0x0210/0x0220, stack top at 0x0218/0x0228”) was wrong: 0x0210/0x0214 and 0x0218/0x021C are current_dev_addr (ctx 0/2 and ctx 1), 0x0220=0 + 0x0224 = stack top (ctx 0/2), and 0x0230/0x0234 = stack_top << 22 (ctx 1)
0x0248/0x024C VHeap Table base hwrtdata.vheap_table_dev_vaddr (64b)
0x0250, 0x0260 PM TA cycle control 0x0250=1 = TA resume (only on non-first kick) + poll b0; 0x0260=1 = TA flush on completion + poll b0. (0x0258 is unused)
0x0268, 0x0278, 0x0288, 0x0290, 0x0298, 0x02A0, 0x02B0..0x02E0 PM Contexts / M-List HWRTData load (0x0288=1 poll b0==0), PR resume (0x0290=1), 3D CSW (0x0298), HWR reset (0x02A0 &= ~3)
0x0328 Post-OOM/PR PM resume Write 1 when resuming TA
0x0338 ROGUE_CR_PM_PARTIAL_RENDER_ENABLE 1 during Partial Render, 0 in normal / post-HWR
0x0360, 0x0370, 0x03F8 PM 3D CSW state Poll 0x03F8 mask 0xC2 == 0xC2, save 0x0360 and 0x0370
0x0388, 0x03D0..0x03E0 PM 3D MemFree and RTA 0x0388 (memfree), 0x03D0/03D4 (PM ctx), 0x03D8 (current_rt), 0x03E0 (last RT)
0x03C8 ROGUE_CR_SIDEKICK_IDLE Poll in HWR: bit 5 (0x20) == 0x20
0x2078..0x20D0 Auxiliary PM-MMU freelist tables Trigger 0x20A8=1 / 0x20B0=1 (poll b0==0)

5. Data Masters: VDM/TE/PPP (DM2), ISP/PBE/ZLS (DM3), CDM (DM4), PDS/USC/TPU

Subsystem Main Offsets Key Functions
VDM (DM2) 0x0400 (start), 0x0408/040C (stream base), 0x0418/041C (call stack), 0x0420, 0x0428, 0x0430 (VDM_CONTEXT_STORE_STATUS), 0x0438..0x0460, 0x0468 (CSW store start) Vertex Data Master control and preemption
CDM (DM4) 0x0478 (start), 0x0480/0484 (stream base), 0x0488 (CSW store start), 0x0490 (CSW resume load, poll b0==0), 0x0498/049C (state base), 0x04A0 (CDM_CONTEXT_STORE_STATUS), 0x04A8..0x04C0, 0x04D8..0x04E0 Compute Data Master control and preemption
PDS 0x0600..0x06D8, 0x0700..0x0720 Exec base (0x0610/0614), event pixel (0x0618/0620/0628), bgnd (0x06A0..06BC), pixel merge (0x06D0), overalloc (0x06D8)
TE / PPP / RTA (DM2) 0x0C00 (TE_AA), 0x0C08..0x0C28, 0x0C38..0x0C48, 0x0C50 (flush 0x40000000, poll b30==0), 0x0C68 (FIRSTKICK init, poll b0==0), 0x0C78..0x0C98, 0x0CA8 (post-PR resume), 0x0CB0/0CB4 (RTC base), 0x0CB8 (RTC init=1 / flush=2), 0x0CC0 (CSW), 0x0CD8 (init poll b0==0), 0x0CE0, 0x0CF8 (non-PR resume), 0x0D20 (active RTs) Tiling Engine, PPP, and Render Target Array
ISP / ZLS (DM3) 0x0F00 (start), 0x0F08 (ISP_RENDER), 0x0F10..0x0F30, 0x0F38 (ISP_CTL), 0x0F48..0x0F6C (ZLS), 0x0F80/0F88, 0x0FA0..0x0FCC, 0x0FD8 (pipe count, max 6), 0x1000 (CSW store), 0x1008 (CSW save), 0x1020 (CSW resume), 0x1038 (ISP_STATUS), 0x3E40 (screen_pixel_max) 3D rasterization and 3D-TQ (6 ISP pipes on K3)
PBE (DM3) 0x1500 (init 0x80), 0x1510..0x154C (8× word0 MRT), 0x1550..0x158C (8× word1 MRT), 0x15A0..0x15DC (zeroed at init) Pixel Back-End (PBE2_IN_XE, up to 8 3D MRTs / 3 3D-TQ MRTs)
TPU 0x1710/1714, 0x1780..0x1810, 0x1790/1794 (3D border), 0x17A0/17A4 (TA border), 0x17A8/17AC (CDM border), 0x1850, 0x1858 (tpu_tag_cdm_ctrl), 0x1870..0x1900 Texture Processing Unit (XE_TPU2 + TPU_DM_GLOBAL_REGISTERS)
USC 0x4008/4010/4028 (64b exec bases), 0x4050 (temp overalloc), 0x4068 (init poll b0==0), 0x4070..0x4090 (pixel out + clears), 0x4098/0x40A0 (view_idx), 0x40A8 Unified Shading Cluster
Perf / Multicore / Aux 0x1608 (post-HWR 0x78001 + poll b0==0), 0x6000, 0x6028 (PERF_3D_CYCLE), 0x6030 (PERF_COMPUTE_CYCLE), 0xF308 (MULTICORE_SYSTEM=1), 0xF310/F318, 0xF330/F338 Performance counters and multicore control

6. Firmware-Private Registers (no public name)

This section is the detailed map; the tables in §1–§5 are the per-subsystem index. In case of discrepancy, this section takes precedence (it was verified register by register against the binary and hardware).

The blocks below do not exist in pvr_rogue_cr_defs.h or in the vendor KM header; they were derived from firmware behavior (Steps 3–7) and must be treated as implementation detail, not host ABI.

6.1 Parameter Manager — Freelist (per PM context 0/1/2)

Offset Width Role
0x0200 W1 + poll b0 global freelist load trigger (ctx 1)
0x0208 W1 + poll b0 local freelist load trigger (ctx 0/2)
0x0210/0x0214 64 freelist current_dev_addr (ctx 0/2)
0x0218/0x021C 64 current_dev_addr (ctx 1)
0x0220/0x0224 32+32 0 + current_stack_top (ctx 0/2)
0x0230/0x0234 64 current_stack_top << 22 (ctx 1)
0x0348/0x0350 R current_stack_top readback (ctx 0 / ctx 1), base for grow
0x0390/0x0394 32+32 allocated_page_count / allocated_mmu_page_count (ctx 0/2)
0x0398/0x039C 32+32 same (ctx 1)
0x03A0/0x03A4 R counter readback (ctx 0)
0x03A8/0x03AC R counter readback (ctx 1)
0x2078..0x2094 W local/global freelist, ctx 1
0x20A8 W1 + poll trigger (ctx 1)
0x20B0 W1 + poll trigger (ctx 0/2)
0x20B8..0x20D4 W/R local/global freelist, ctx 0/2

6.2 Parameter Manager — context, catalogues, and MList

Offset Role
0x0190 PM ctx 0 (TA) load trigger, poll b0
0x0198 “vheap mode” trigger
0x0290 mode trigger (after 0x03D0/0x03D4)
0x02A0 per-freelist request bits (handshake)
0x02A8 handshake busy bits
0x02B0 PM resume/start mode (1, 2, 3)
0x02B8 / 0x02C8 PMMListStackPointer (ctx 0 / ctx 1)
0x02C0 / 0x02D0 PMMListStackPointer readback
0x02D8/0x02DC PMMList dev addr (ctx 0, 64 b)
0x02E0/0x02E4 PMMList dev addr (ctx 1)
0x0268/0x026C PMAListStackPointer (ctx 0)
0x0278/0x027C PMAListStackPointer (ctx 1)
0x0270/0x0280 PMAListStackPointer readback
0x03D0/0x03D4 PM context selector ([16]/[8]) + vheap mode (split 24 b)
0x1248/0x1250/0x1260 VCE / TE / Alist cat base — ctx 0 (TA), 64 b each
0x1268/0x1270/0x1280 same — ctx 1 (3D), via BCAST

6.3 RTA and TE (DM2)

Offset Role
0x0C48 low word of TE cat base (not RTA)
0x0CB0/0x0CB4 render target cache base, 64 b (0 = single-RT mode)
0x0CB8 RTC initialization trigger
0x0CE0 RTA mode: 0 multi-RT, 1 RTA off, 3 single-RT
0x0D20 number of active RTs
0x03D8 current slice index (3D)
0x03E0 1 when current slice is the last (or RTA empty)

6.4 Context Switch per DM

Offset Role
0x0408/0x040C VDM stream base (64 b, resume)
0x0418/0x0420 VDM call stack (2 × 64 b pairs, resume)
0x0428 VDM context state base (store destination)
0x0430 VDM context store status (bit 0 = completed)
0x0438/0x0440/0x0448 store task 0/1/2 destinations
0x0450/0x0458/0x0460 store/resume task 0/1/2 destinations
0x0468 VDM store trigger
0x0CC0 TA context state base
0x1000 ISP/3D store trigger (BCAST)
0x1020 ISP resume value, per core
0x0298 / 0x01C8 3D resume control / CSW flag
0x0F08 ISP_RENDER/CSW: [1:0] state, [4] = CSW enabled
0x03F8 ISP store completion status (& 0xC2 == 0xC2)
0x0360/0x0370 store counters/generation (read on finished)
0x0488 CDM store trigger (per core or BCAST)
0x0490 CDM resume trigger/status (returns to 0)
0x04A8/0x04B0 CDM context PDS0 (A/B) / PDS1
0x04B8/0x04C0 CDM terminate PDS (64 b) / terminate PDS1
0x04D8/0x04DC CDM resume PDS0 (A/B, 64 b)
0x04E0 CDM resume parameter

6.5 HWR and MMU fault

Offset Role
0x12B0 BIF fault MMU status (FAULT, FAULT_RO, DATA_TYPE, PAGE_SIZE, CAT_BASE[27:12]) — public name: ROGUE_CR_BIF_FAULT_BANK0_MMU_STATUS
0x12B8/0x12BC BIF fault REQ status (ADDRESS[51:4], TAG_ID[47:40], RNW) — ROGUE_CR_BIF_FAULT_BANK0_REQ_STATUS
0x6020 TA (DM2) progress counter
0x6028 3D (DM3) progress counter
0x6030 CDM (DM4) progress counter
0x0328 PM OOM ack (resumes TA)
0x0320 terminates/flushes TA on the OOM path with no reserved pages

6.6 HWPerf — counter blocks

All in BCAST. sel = selection/mask; base = first mux pair (8 B per mux, stride 8).

Block sel base counter enable
TA 0x7600 0x7608 —
RASTERISATION 0x7700 0x7708 —
HUB (BIF-PMCACHE) 0x7800 0x7808 —
TPU MCU L0 0x7900 0x7908 0x8028
USC 0x8100 0x8108 0x8030
PBE 0x83D8 0x8478 —

6.7 Cache and Per-DM Completion Flush

Registers written by the flush routine called before retiring the cCCB command (full sequence in data-masters.md §4.1). All in BCAST, except those marked as per core.

Offset Width Role GEOM 3D CDM
0x4000 32 unified store / initial drain 1 1 1
0x0688 32 per core per-core cache trigger 1 2 4
0x0668 32 DM cache block 5 3 9
0x1608 32 TPU/USC block (post-HWR uses 0x78001) 0x10001 0x38001 0x10001
0x1470 32 internal cache trigger (3D only) — 1 —
0x1478 32 internal cache trigger (3D only) — 1 —
0x1480 32 internal cache trigger (3D only) — 1 —
0x1488 32 final invalidate 1 1 1
0x1744 32 write filter 0x80 0x180 0x280
0x1740 32 ROGUE_CR_MCU_FENCE 0 0 0
0x1720 32 clean trigger (GP / others) 7/0x27 0xb/0x2b 0x13/0x33
0x1728 32 status of previous step (poll b0) — — —
0x3818 32 ROGUE_CR_SLC_CTRL_FLUSH_INVAL 2 (DM_TA) 6 (DM_TA\|DM_PIXEL) 8 (DM_COMPUTE)
0x3820 32 ROGUE_CR_SLC_STATUS0 (poll b2, per core) — — —

6.8 Multicore, Secondary Events, and PM in PR

Offset Width Role
0x08A8 32 USC_TRIGGER event ack (written 1 in GP handler)
0x0130 32 ROGUE_CR_EVENT_STATUS (per core)
0x0138 32 ROGUE_CR_EVENT_CLEAR (W1C; per core)
0x0B58/0x0B60/0x0B68/0x0B70/0x0B78 32 MTS_DM0..DM4_INTERRUPT_ENABLE — masks 0x89200 (GP), 0xA0 (DM2), 0x8 (DM3), 0x4 (DM4)
0xF308 32 ROGUE_CR_MULTICORE_SYSTEM — number of cores (1 on K3)
0xF330 32 MULTICORE_COMPUTE_CTRL_COMMON = (execute_count << 8) \| core_mask
0xF310 32 MULTICORE_FRAGMENT_CTRL_COMMON
0x0338 32 PM_PARTIAL_RENDER_ENABLE (1 during PR, 0 at end)
0x0388 32 3D PM mem-free enable (0, or num_cores == 1)
0x03D8 32 rta_ctl.current_render_target (published on kick)
0x03E0 32 1 if last active RT (kick) / restored on mem-free timeout
0x0FC0/0x0FC4 32 per core isp_oclqry_base (lo/hi), advancing by isp_oclqry_stride per core
0x0F88 32 isp_bgobjvals (bit 9 selects the PR background set)