On the SpacemiT K3 there are two Linux drivers capable of operating the PowerVR BXM-4-64 (36.56.104.183) GPU:
drivers/gpu/drm/imagination) — primary target of this specification.img-rogue, DDK 24.2) — historically used in the board’s original BSP for hardware validation, clock/DVFS measurements, HWPerf, and physical register verification.This document explains exactly what is common in hardware, what changes in the host↔firmware ABI, and why the clean-room implementation must target the mainline contract.
[P])drm/imagination driver is open source (GPL-2.0-only OR MIT) and contains compile-time size and offset checks (pvr_rogue_fwif_check.h, pvr_rogue_fwif_client_check.h, pvr_rogue_fwif_shared_check.h, pvr_rogue_mips_check.h).firmware_version, 29-parameter device_info, and compchecks).pvr Vulkan / Zink) communicates directly with the mainline DRM driver.[P][O])| Aspect | Mainline (drm/imagination) — TARGET |
Legacy Vendor Driver (img-rogue) |
|---|---|---|
| Firmware filename | powervr/rogue_36.56.104.183_v1.fw |
Legacy firmware distributed in the BSP |
| FWIF ABI version | 1.1 (v3 header with device_info) |
Proprietary DDK 24.x ABI |
device_info in .fw container |
Present (version 1, 29 u64 parameters, 232 B payload) |
Vendor-driver-specific format |
DM identification in KCCB |
PVR_FWIF_DM_GP=0, GEOM=2, FRAG=3, CDM=4 |
Vendor-specific numbering |
| KCCB / FWCCB command | rogue_fwif_kccb_cmd (88 B) / rogue_fwif_fwccb_cmd (88 B) |
Vendor-specific format |
| cCCB command header | rogue_fwif_ccb_cmd_header (40 bytes) |
Vendor-specific format |
rogue_fwif_sysinit structure |
544 bytes (fixed offsets in pvr_rogue_fwif_check.h) |
Different layout |
rogue_fwif_osinit structure |
104 bytes | Different layout |
rogue_fwif_fwcommoncontext structure |
152 bytes | Different layout |
| Synchronization | UFOs + Sync Checkpoints (0xAC1/0x519/0xEFF) |
UFOs + DDK Sync Primitives / Checkpoints |
| Physical GPU mapping and CR registers | Identical (same 36.56.104.183 silicon) |
Identical (same 36.56.104.183 silicon) |
| Unit init, PM, BIF, SLC, MTS, CSW, SPM, HWR sequences | Identical at the hardware register level | Identical at the hardware register level |
During investigation on a SpacemiT K3 Pico ITX board, physical measurements (such as OPP frequencies 409–1228 MHz, active register snapshots CORE_ID, SLC_IDLE, ISP_CTL, APM latency, HWPerf capture, and reboot/power-cycle behavior) were collected in both mainline and vendor environments for cross-corroboration of hardware:
0x0020 = 0x00240038006800B7, ISP_CTL with 6 pipes, ticking CR_TIMER, 409→1228 MHz OPP transitions, HWPerf 6 mux blocks) enter this specification tagged as [O].[P]), verified by the *_check.h files.To avoid any ambiguity during implementation:
ROGUE_CR_*.CR[0xXXXX] (unicast access in core 0 bank, virtual base 0xCF800000) or BCAST[0xXXXX] (broadcast access via 0xCFA00000).pvr_rogue_fwif.h, pvr_rogue_fwif_shared.h, pvr_rogue_fwif_client.h, and pvr_rogue_mips.h.u32) are denoted as fw_addr (mapped by the MIPS TLB in the FW Heap range).u64, 40 bits) are denoted as dev_addr.u64, 36 bits) are denoted as phys_addr / dma_addr.