Skip to content

kboot: accept the canonical T8142 display PIODMA alias - #165

Draft
DjDeveloperr wants to merge 2 commits into
mainfrom
fix/t8142-piodma-alias-pr1532-20261111
Draft

DjDeveloperr wants to merge 2 commits into
mainfrom
fix/t8142-piodma-alias-pr1532-20261111

Conversation

@DjDeveloperr

@DjDeveloperr DjDeveloperr commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

T8142 display handoff hardcodes disp0_piodma, so a device tree using only the schema-compliant disp0-piodma alias misses PIODMA reservations. Use the alias already resolved by dt_set_display(). This preserves the shared underscore-first rule when both spellings exist. A selected alias with an invalid target still refuses the handoff.

Draft at c01bd4ee. The real-libfdt regression passed all ten scenarios under ASan/UBSan, including canonical-only, both spellings with different targets, invalid targets, DART refusal and M1/M2 controls. The old hardcoded path compiled and failed the canonical-only assertion. The prior canonical-first version compiled and failed the mixed-alias assertion under the shared precedence requirement. Hosted CI passed 15/15 on c01bd4ee. These tests use synthetic ADT/DART and publisher boundaries.

Linux #1532 has landed. Compatible loader qualification and adoption still gate rollout of canonical-only DTBs. An affected T8142 hardware boot is required before this PR merges.

Prefer disp0-piodma on T8142 and retain disp0_piodma when the canonical alias is absent. A present invalid canonical target must not fall back to a different legacy device. Other SoCs keep their existing alias precedence.

Exercise the production dispatcher, carveout loop and admission routine with real libfdt: canonical/legacy aliases, conflicting and missing targets, DART refusal and M1/M2 controls. Unchanged main fails canonical-only and two unsafe mutations fail their intended runtime assertions under ASan/UBSan.

This source companion is not loader adoption or a hardware qualification. Linux #1532 must retain its current alias until an appropriate loader has been adopted and tested.

Signed-off-by: Diljit Singh <hey@djdev.me>
m0d16l14n1 added a commit to m0d16l14n1/linux that referenced this pull request Nov 15, 2026
…s the legacy one

The shared T8142 display file gave both Airs the legacy disp0_piodma alias,
which dt-schema rejects (an alias name is lowercase letters, digits and
'-'). The loader is its only T8142 user: the kernel looks the legacy name up
only on T8132 (iomfb_m4.c, apple-dart-dcp.h, J713 inherited mappings).

Name the alias disp0-piodma in the shared file, which aura prefers on T8142
since aurora-silicon/aura#165, and keep disp0_piodma in the J813 board file
for its earlier loaders, as integration/aurora has it. J815 only boots with
a loader newer than that anyway: the b13.1 Stage 1 cannot chainload on
T8142 without aurora-silicon/aura#250.

CHECK_DTBS: no alias warning on J815; J813's is unchanged.

Assisted-by: Claude Opus 5.5
Signed-off-by: Nick <nekreshen@yandex.ru>
@RyanTheTide

Copy link
Copy Markdown
Contributor

Thanks for this. dt_set_display() already resolves the PIODMA alias once for every SoC (disp0_piodma_alias, falling back between disp0-piodma and disp0_piodma), and the T8103/T8112/T600x/T602x branches pass it through; only the T8142 branch still hardcodes "disp0_piodma". Could the T8142 branch just pass disp0_piodma_alias too? That fixes canonical-only trees without a T8142-specific precedence. If canonical-first is the better order, it would be good to change the shared resolution for all SoCs and refuse when both aliases exist with different targets, as kboot_display_handoff.c already does for dcp6. The host regression should carry over unchanged.

Signed-off-by: DjDeveloperr <hey@djdev.me>
@DjDeveloperr

Copy link
Copy Markdown
Contributor Author

Done in c01bd4e, as you suggested: the T8142 branch now passes disp0_piodma_alias like the other SoCs, so the shared underscore-first rule applies and there's no T8142-specific precedence. The host regression carries over and now also covers "both spellings, different targets" (selects disp0_piodma), "invalid legacy does not fall back", and M1/M2 precedence unchanged. Hosted CI is 15/15 green on that head.

It stays draft until one T8142 boot with a canonical-only DTB (Linux #1532) shows the PIODMA reservations attached and the display up.

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.

2 participants