Skip to content

kboot: forward the A8X GPU's bridge settings to the device tree - #25

Merged
henrikklee merged 2 commits into
OrchardLinux:mainfrom
mattonik:a8x-gpu-bridge-settings
Dec 5, 2026
Merged

henrikklee merged 2 commits into
OrchardLinux:mainfrom
mattonik:a8x-gpu-bridge-settings

Conversation

@mattonik

@mattonik mattonik commented Dec 4, 2026

Copy link
Copy Markdown

The A8X's GPU (apple,t7001-gpu, iPad Air 2) writes its two bus bridges' register settings after every power-on. They belong to the device: /arm-io/pmgr has them as bridge-settings-9 and bridge-settings-10, 33 little-endian {offset, value} pairs each, offsets relative to the bridge. This adds them to the GPU node as apple,bridge-settings, big-endian cells relative to the node's "bridges" region (the second bridge at +0x80000), which is what the powervr driver's A8X support reads (OrchardLinux/linux#165). Without the property that driver refuses to probe: "bad or missing apple,bridge-settings". Nothing happens on boards without an apple,t7001-gpu node, or where the ADT lacks the two properties or has them at another length.

This is a port of the patch the series was developed with on HoolockLinux's m1n1 (it did not apply here: kboot.c moved). The function runs right after dt_set_gpu().

Checked: builds with Orchard's m1n1 container (USE_CLANG=1 ARCH=aarch64-linux-gnu CHAINLOADING=1), and the new strings are in the binary. The Hoolock-based predecessor, with the same rows, ran on an iPad Air 2 (J81): the property reached the node and powervr probed. This exact build has not been booted yet; a second J81 owner reproduced the series with the same ported change (see the comments on OrchardLinux/linux#165).

Once merged, boot/m1n1/upstream.lock in orchard can move to the merge commit.

🤖 Generated with Claude Code

The A8X's GPU (apple,t7001-gpu, iPad Air 2) writes its two bus bridges'
register settings after every power-on. They belong to the device:
/arm-io/pmgr has them as bridge-settings-9 and bridge-settings-10, 33
little-endian {offset, value} pairs each, offsets relative to the bridge.
Add them to the GPU node as apple,bridge-settings, big-endian cells
relative to the node's "bridges" region (the second bridge at +0x80000),
which is what the powervr driver's A8X support reads. Without the
property that driver refuses to probe.

Nothing happens on boards without an apple,t7001-gpu node, or where the
ADT lacks the two properties or has them at another length.

Tested on an iPad Air 2 (J81) with the A8X kernel series
(OrchardLinux/linux#165): the property reaches the node and powervr
probes (CORE_REVISION 0x00070500) under Orchard's launcher and Omarchy A.

Assisted-by: LLM
Signed-off-by: Martin Puškáč <martin@icebear.sk>
Drop the double blank line after the function and align the two
GPU_BRIDGE_* defines, as clang-format wants.

Assisted-by: LLM
Signed-off-by: Henrik Klee <henrik@goat-code.com>
@henrikklee
henrikklee force-pushed the a8x-gpu-bridge-settings branch from 2fa5c7b to 933c797 Compare December 5, 2026 00:40
@henrikklee
henrikklee merged commit 830cd98 into OrchardLinux:main Dec 5, 2026
7 checks passed
@henrikklee

Copy link
Copy Markdown

Merged. Welcome to OrchardLinux, Martin, and thank you for your first contribution! Passing the A8X GPU's bridge settings through from Apple's device tree is the missing piece that lets the iPad Air 2's GPU driver start, and the code is careful: it does nothing on other boards or when the data isn't there, and its output matches exactly what the driver in linux#165 reads.

  • Changed on your branch: one small formatting commit on top of yours (a double blank line removed and the two GPU_BRIDGE_* defines aligned), so the format check passes. Your commit is unchanged.
  • Nothing was left out.
  • Next: orchard keeps building its current m1n1 for now. It moves to this m1n1 together with the kernel side, once linux#165 lands, so the iPad Air 2 gets both halves at once.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants