Skip to content

arm64: qcom: OnePlus 13 (dodge) bring-up (gpu2 + IPA) - #115

Closed
mrlund wants to merge 43 commits into
derekross:omamobilefrom
mrlund:dodge/pr-kernel-v1
Closed

mrlund wants to merge 43 commits into
derekross:omamobilefrom
mrlund:dodge/pr-kernel-v1

Conversation

@mrlund

@mrlund mrlund commented Oct 28, 2026

Copy link
Copy Markdown

arm64: qcom: OnePlus 13 (dodge) bring-up (gpu2 + IPA)

Base: omamobile
Branch: dodge/pr-kernel-v1 on https://github.com/mrlund/linux-omarchy-mobile
Config profile verified: gpu2 (CONFIG_QCOM_IPA=m, MSM DRM)
Companion device PR: derekross/omarchy-mobile#111

Summary

Subsystem-split series for the OnePlus 13 (SM8750 / Snapdragon 8 Elite):
board DT, display/panel, Adreno GPU (incl. A830 catalog + RSCC), IPA for
modem data, audio, Wi-Fi/BT, sensors/touch, and related bindings. Curated
from the private gpu2 tree; DIAG / trial / splash / fastrpc / only_adsp
experiments dropped. Modem (MPSS) and CDSP remoteproc nodes are enabled
to match the gpu2 runtime Martin runs today (IPA included); only the
skip_tme ath12k trial knob is dropped from source.

Suggested follow-up split for review (same commits, tip refs on the fork):

Tip ref Scope
dodge/pr-k-shared shared / early board
dodge/pr-k-gpu-soc GPU / SoC catalog
dodge/pr-k-pre-ipa pre-IPA board enablement
dodge/pr-k-ipa IPA

Feature matrix (kernel side)

Block In series Notes
Board DT yes sm8750-oneplus-dodge.dts
Display / panel yes AA569 DSC cmd mode
GPU yes Adreno path + A830 catalog; gpu2
IPA yes data path for modem
Audio yes AW882xx unmute in-tree
Wi-Fi / BT yes WCN7850
Touch / sensors yes Synaptics TCM2 SPI
Modem remoteproc DT yes (enabled) MPSS + CDSP okay, matches gpu2

Phone-smoke evidence

Non-persistent fastboot boot of the curated chain (LOCALVERSION
-dodge-gpu2, vermagic match to modules already on the phone). Slot B
left on the prior gpu2 flash image (nothing written to boot partitions).
Never set_active a.

Check Result
Display (DSI connected/On, Hyprland) pass
Touch (touchpanel input) pass
GPU (adreno bound, render node, freq) pass
Wi-Fi (wlp1s0 present) pass (iface up; see modem pass for radio-off)
Bluetooth (hci0 Powered) pass
Audio (ALSA card, ADSP) pass
Sensors / autorotate (monitor-sensor accel/prox/compass) pass
IPA probe pass
Modem register + cellular data (Wi-Fi off) pass (see second smoke table)
rtsar / Smart Transmit 0
Never-touch partition hashes unchanged across trial
Left on boot_b = gpu2 flash (trial non-persistent)

Diff-equivalence vs private gpu2 (curated-touched paths)

same=48 diff=4 only_curated=1 only_gpu2=0

Path Disposition
Documentation/devicetree/bindings/display/msm/gmu.yaml keep: adds qcom,adreno-gmu-830.1 (DTS uses it)
Documentation/devicetree/bindings/display/msm/gpu.yaml keep: adds A830 enum entry
Documentation/devicetree/bindings/net/bluetooth/qcom,wcn7850-bt.yaml keep: documents WCN7860 compatible
Documentation/devicetree/bindings/sound/awinic,aw882308.yaml keep: binding YAML gpu2 lacks
drivers/net/wireless/ath/ath12k/qmi.c intended drop: skip_tme module_param (trial); TME path default retained

All other curated-touched paths byte-identical to gpu2. Intended DIAG/trial
drops listed in pr-work/intended-drops.txt (PCI iATU dumps, Gen2/1-lane
trials, splash identity-map, DSI/DPU DIAG, only_adsp, etc.).

Provenance / missing author SoBs

All commits carry my Signed-off-by. Original authorship is kept. Where
the upstream/source history had no author Signed-off-by, that is
disclosed here for Derek to decide (carry / rewrite / drop) — I am not
inventing SoB lines:

  • dts, config, panel, touch (author index986): taken from
    sm8750-mainline/linux v6.16 (Link: in each commit) and ported to 7.3.
    The originals have no Signed-off-by from index986 (handle only).
  • gpucc/gxclkctl/adreno-smmu: ROCKNIX SM8750 patch 0033 — no personal
    author and no Signed-off-by
    . Backported with Link: + [mrlund: …].
  • GPU/GMU nodes (author Teguh Sobirin): ROCKNIX patch 0038 — his
    Signed-off-by from that patch is kept.
  • A830 catalog (author Teguh Sobirin): ROCKNIX patch 0049 — no
    Signed-off-by
    from him in that patch.
  • Everything else is my own work (plus Alexander Koskovich's IPA commits
    with his SoB).

Assisted-by: Grok Bot is on the commits an AI assistant helped with; I
reviewed and tested all of it. (Panel driver still carries generator/
source-tree comment markers — not open work.)

Phone smoke (boot_b, curated tip vs gpu2 baseline)

Trial via fastboot boot (non-persistent) then restore; LEFT_ON = boot_b gpu2 (7.3.0-rc6-dodge-gpu2).

Check Result
Display / DSI pass
Touch pass
GPU pass
Wi-Fi pass
BT pass
Audio pass
Sensors / autorotate pass
Modem + cellular (Wi-Fi off) pass (registered; ping 4/4)
Never-touch hashes (HASH-TRIAL-OK) pass
rtsar 0

Diff-equivalence vs gpu2: same=48, CONTENT_DIFF=4, ONLY_CURATED=1 (bindings + skip_tme drop + aw882308.yaml); drops justified. See pr-work/diff-equiv-final-table.md.

@derekross

Copy link
Copy Markdown
Owner

Thank you, @mrlund, and welcome. Getting the Adreno 830, IPA and WCN7860 running on a OnePlus 13 on top of our 7.3 base is a lot of work, and I appreciate how openly the description lists where each piece came from, including the commits whose original authors never signed off.

I ran our kernel gate (tools/kernel-pr-check --build --merge on today's omamobile, the same check CI runs). The series merges cleanly, but four checks fail, and the review turned up a few more things. The first one would break other phones' builds:

  1. The last commit, "dodge: match gpu2 runtime", removes other phones' drivers from the build. It deletes the TOUCHSCREEN_SALIXP and DRM_PANEL_GOOGLE_TG4C entries from the touchscreen and panel Kconfig/Makefile (the Pixel Fold's cover touch, which our config builds as CONFIG_TOUCHSCREEN_SALIXP=m, and the Pixel 9a's panel), and it reverts the S6SY79x help text. The source files stay but no longer build. It also brings back trailing whitespace and space indentation (checkpatch reports 69 errors in that commit alone), joins the /memory reg list into one line, and removes the comment explaining why the modem and CDSP were disabled. Please drop the commit, and redo the parts you want (enabling the MPSS and CDSP, the ath12k and MHI changes) as their own commits on top of the curated ones. Its subject also needs a subsystem prefix.

  2. Sign-offs. Five commits have no Signed-off-by from their author: b17547a13e01 (Teguh Sobirin), and 62939e2d3bb9, 29b5f99b277b, f3d38e45bf4b and 819f4aa63ffe (index986). Our gate requires one, as upstream does. Please ask the authors whether they'll sign off. If they won't, I'll decide separately whether we can carry the code. In the four IPA commits from Alexander Koskovich, a blank line separates his Signed-off-by from yours, so his drops out of the trailer block (git interpret-trailers --parse shows only yours). An Assisted-by: Grok Bot line also sits inside his trailers, as if he had used it. Please keep his trailers exactly as he posted them, add a Link: to the posting, and put your own lines after his. net: ipa: fix IPA v5.5 configuration data has a struct dump where the explanation should be.

  3. Build warnings. The W=1 build warns in syna_tcm2.c:69 (touch_data set but not used), syna_tcm2_spi.c:355 (retval set but not used) and ath12k/qmi.c:4383 (ath12k_qmi_process_coldboot_calibration is unused). The DTB gains unit_address_vs_reg for /memory.

  4. The board's compatible is "OnePlus,13", "qcom,sm8750". The vendor prefix is oneplus, the board isn't in qcom.yaml, and the omarchy-mobile descriptor and BRINGUP say oneplus,dodge. Please use one documented compatible everywhere.

  5. arch/arm64/configs/sm8750.config belongs in omarchy-mobile, as device/dodge/kernel.config next to the descriptor. It is 992 lines, and at least four of its symbols (TOUCHPANEL_CUSTOM, OPLUS_FW_UPDATE, TOUCHPANEL_NOTIFY, INPUT_TRI_KEY) don't exist in this tree.

  6. Shared drivers. Our rule (CONTRIBUTING §6.2) is that new behaviour sits behind your board's or SoC's match data:

    • The dsi_host.c change forces RGB888 on every DSC panel that asks for RGB101010, and its comment says the cause isn't understood yet.
    • The sc8280xp.c change sets the I2S format on every MI2S link of every board that uses that machine driver.
    • The IPA v5.5 data change also reaches SM8550.
    • The pcie-qcom and MHI changes are core paths too.

    Each of these needs a per-SoC or per-board gate, or an upstream posting we can point to.

  7. A second Synaptics TouchComm driver. This tree already has synaptics_tcm.c (TOUCHSCREEN_SYNAPTICS_TCM_SPI). Before adding 4,300 lines for the same command protocol, please check whether the existing driver can take the S3910 with match data, and say in the commit why not if it can't. The new driver also cancels reflash_work in its remove path without ever initialising it, which warns on unbind.

  8. New nodes. Enabling remoteproc_mpss and remoteproc_cdsp should be its own commit, with the reason and what ran on the phone. The board commit's own comment explained the risk: probing the modem hands its memory to the modem VM.

The bigger question is scope, and that part is mine to answer. This PR is 46 commits across about ten subsystems, 9,800 lines, mostly Qualcomm SoC enablement: the GPU catalog, gpucc, IPA, ath12k, MHI and PCIe. Upstream is moving fast on SM8750, and the Qualcomm phones we have so far keep their kernels in their own repositories. I want to decide whether linux-omarchy-mobile should carry this stack, or only the OnePlus 13 board on top of what's upstream, before either of us puts more time into this branch. I'll come back to you on that. In the meantime, the split you suggest (dodge/pr-k-shared, -gpu-soc, -pre-ipa, -ipa) is the right shape, with one subsystem per PR as CONTRIBUTING §6.2 asks.

One more thing for the record: the smoke tables come from a fastboot boot of this chain with the modules already on the phone, and from slot B running a private -dodge-gpu2 build. Please say which tree each row came from. A tools/phone-smoke report from the boot that matches the PR head would be the strongest evidence.

CI is waiting for my approval because this is your first PR. I'll approve it so you can see the same results.

@mrlund
mrlund force-pushed the dodge/pr-kernel-v1 branch from 14599e9 to 8bce888 Compare October 29, 2026 08:17
@mrlund

mrlund commented Oct 29, 2026

Copy link
Copy Markdown
Author

Thanks Derek — and thanks for running the gate and for approving CI on a first PR.

Fixed the broken parts and pushed a rewritten dodge/pr-kernel-v1. Waiting on your scope call before putting more into the branch.

CI on the old head was red for exactly those: missing author sign-offs, checkpatch on the gpu2 commit, the three W=1 warnings, and the DTS compatible/schema warnings.

Done:

  • Dropped the last commit (dodge: match gpu2 runtime). Redid only the still-wanted MPSS/CDSP enable as its own commit (arm64: dts: qcom: sm8750-oneplus-dodge: enable CDSP and MPSS) with the modem/CDSP risk comment kept. Left ath12k/MHI out of that redo — not clearly needed beyond what the curated series already has, and it was tangled with the other-phone Kconfig/Makefile edits.
  • Koskovich IPA trailers: his Signed-off-by block kept exactly as posted, with a Link: to each lore posting, and my Signed-off-by / Assisted-by after his (no blank line breaking the block).
  • Rewrote the net: ipa: fix IPA v5.5 configuration data commit message (what changed and why; no struct dump).
  • Cleared the W=1 warnings (syna_tcm2.c:69 unused touch_data, syna_tcm2_spi.c:355 unused retval; the ath12k unused ath12k_qmi_process_coldboot_calibration went away with the gpu2 drop). Also dropped the unused reflash_work cancel in the new Synaptics driver.
  • Compatible → oneplus,dodge everywhere, with oneplus vendor prefix added to Documentation/devicetree/bindings/arm/qcom.yaml. Fixed /memory unit_address_vs_reg (memory@…).

Sign-offs. Asking the authors now whether they'll sign off (hashes after the rewrite):

  • Teguh Sobirin — b17547a13e01 (drm/msm/adreno: add the Adreno 830 catalog entry)
  • index986 — cc2707f8305d (OnePlus 13 dts), 5da3c5597788 (sm8750.config), 7eecaf48ec23 (AA569 panel), fefcc57cb9c1 (Synaptics TCM2)

If they won't, those five stay out or get rewritten, per your call.

Waiting on you for scope. Happy to split along the lines you liked (dodge/pr-k-shared, -gpu-soc, -pre-ipa, -ipa, one subsystem per PR) once you decide whether linux-omarchy-mobile carries the SM8750 stack or only the board on top of upstream. The shared-driver gating (dsi_host RGB888, sc8280xp I2S, IPA v5.5 reaching SM8550, pcie-qcom/MHI), the second Synaptics TCM driver vs the existing one, moving sm8750.config into device/dodge/kernel.config, and a phone-smoke report from a boot of this PR head all wait on that decision so we don't do the work twice.

@derekross

Copy link
Copy Markdown
Owner

Thank you, @mrlund, for the quick rework, and for holding off on the bigger changes until I've decided on scope. That saves us both time.

I re-ran our gate (tools/kernel-pr-check --build --merge on today's omamobile) on the new head and went through the range-diff against the old one. What's fixed:

  • The "match gpu2 runtime" commit is gone. Nothing in the series removes another phone's Kconfig or Makefile entries now, and all 37 removed lines across the series are deliberate changes to code the series touches.
  • The W=1 build of all 30 touched C files is clean, and the 347 device trees build with no new warnings.
  • checkpatch reports no errors, and every subject has a prefix.
  • Alexander Koskovich's IPA commits parse with his Signed-off-by and the Link: in the trailer block, then yours. The v5.5 fix now has a proper message.
  • The board's compatible is oneplus,dodge, documented in qcom.yaml.
  • The ath12k DMA-mask change is gated on the WCN7860 device ID.

Still open, so you have the full list when I come back on scope:

  1. Sign-offs. The gate still fails on the five commits you named (b17547a13e01 from Teguh Sobirin, and cc2707f8305d, 5da3c5597788, 7eecaf48ec23, fefcc57cb9c1 from index986). Thanks for asking the authors. Nothing else to do here until they answer.
  2. Three compatibles in the board DTS have no binding: oneplus,dodge-panel, synaptics,tcm-spi-hbp and oplus,dhall-ak09970, and the oplus vendor prefix isn't in vendor-prefixes.yaml. dtbs_check will report them once CI runs. The panel and touch bindings would come with their drivers. The hall sensor needs a binding or should come out of the DTS.
  3. Commit order. dt-bindings: arm: qcom: document OnePlus 13 (dodge) is commit 44, but the DTS that uses the compatible is commit 10, so checkpatch flags oneplus,dodge as undocumented in commit 10. Bindings go before their first user. Please move it, and do the same with the panel and touch bindings when they come.
  4. The CDSP and MPSS commit is now on its own, as I asked, but its message doesn't yet say what ran on the phone. It should also say what changes at every boot: the CDSP has auto_boot = true (it falls back to sm8650_cdsp_resource), so its firmware starts at each boot, and the MPSS has auto_boot = false but assigns its carve-out to the modem VM at probe (region_assign_vmid). That happens on every dodge kernel, whether or not the owner has turned on the modem in userspace. Please put both in the message, with the boot that showed them.
  5. As you said, the shared-driver gates, the second Synaptics driver, moving sm8750.config to device/dodge/kernel.config and a tools/phone-smoke report from a boot of this head all wait on my scope decision.

CI for this push is waiting for my approval again. I'll approve it so you see dtbs_check, which our local gate can't run.

I'll come back to you on scope. Thanks for your patience with a series this size.

@mrlund
mrlund force-pushed the dodge/pr-kernel-v1 branch from 8bce888 to f5e354e Compare October 30, 2026 10:19
@mrlund

mrlund commented Oct 30, 2026

Copy link
Copy Markdown
Author

Thanks @derekross. Going through the still-open points. The branch is now at f5e354e1c.

Up front: I edited index986’s commits that I carried — the board DTS cleanup, the memory node, and the touch prop rename in the Synaptics driver — and updated their [mrlund: …] notes. The five commits from other authors still have no author Signed-off-by; nothing else to do there until they answer. Hashes since your review 3:

Commit Was Now
Teguh Adreno 830 catalog b17547a13 b17547a13 (unchanged)
index986 board DTS cc2707f83 f2551d072
index986 sm8750.config 5da3c5597 983ae704b
index986 dodge panel 7eecaf48e 2dcdbdb4f
index986 Synaptics TCM2 fefcc57cb b552309e7

Short old to new for the pieces this round touched:

Was Now
board binding after the DTS f848f0d78 / panel 954199b62 / touch 9797d0cda sit before f2551d072 (add the OnePlus 13)
f2551d072 still had memory@81960000 + schema warnings same commit, rewritten: DT cleanup, drop the hardcoded map, [mrlund: …] updated
unbound oplus,dhall-ak09970 hall node and pinctrl dropped
CDSP/MPSS message thin f5e354e1c amended (auto_boot / region_assign, see 4)

1. Sign-offs. Still the five above. Waiting on the authors.

2. Three compatibles. oneplus,dodge-panel and synaptics,tcm-spi-hbp have bindings next to their drivers. oplus,dhall-ak09970 is gone from the board DTS (no in-tree driver; oplus is not in vendor-prefixes.yaml).

3. Binding order. Board / panel / touch bindings now precede their first users.

4. CDSP / MPSS message. Now states that the board CDSP compatible falls back to sm8650_cdsp_resource with auto_boot = true (firmware starts every boot), and that MPSS has auto_boot = false but still assigns its carve-out to QCOM_SCM_VMID_MSS_MSA at probe — so the assign runs on every dodge boot whether or not userspace starts the modem. Observed on the gpu2 slot-B boot: both remotes okay; CDSP loads; MPSS stays down until omamobile-modem.

5. Scope-deferred. Shared-driver gates, the second Synaptics driver, moving sm8750.config to device/dodge/kernel.config, and a modules-matched tip smoke all wait on your call.

Smoke

A tip pack that left both memory@a0000000 (stage2 live fill) and a leftover hardcoded memory@81960000 hung before Run /init / UFS / USB. Dropping the hardcoded node from the board DTS (stage2-dtb keeps a single filled memory node) fixed it; re-pack, then fastboot boot only. Tip boot uname 7.3.0-rc6-gf5e354e1cf2b, SSH about 26 s, live FDT one memory@a0000000. GPU / touch / Wi-Fi / BT / battery were not ok on that boot: the tip uname has no matching /usr/lib/modules/ tree on the rootfs (only 7.3.0-rc6-dodge-gpu2 and .held), those drivers are =m, and the module overlay unit failed — same rootfs with the matching gpu2 uname had them all ok. So touch, GPU, Wi-Fi, BT and battery are untested on the tip, not shown broken. Phone returned to slot B.

Check Result
storage / root / kernel-health / USB / session ok
display / buttons / thermal ok
GPU / touch / Wi-Fi / BT / battery not ok — modules path vs tip uname (above)

kernel-pr-check --merge --build at tip: merges; subjects / policy / W=1 C ok; 347 DTs W=1 + dtbs_check with no new warnings; binding check on the new yamls ok. Only failure: sign-offs on the five commits from other authors.

@derekross

Copy link
Copy Markdown
Owner

Thank you, @mrlund, for the clear old-to-new tables. They made this round quick to check.

I went through the new head and ran our gate (tools/kernel-pr-check against today's omamobile). What's fixed:

  • The board, panel and touchscreen bindings now come before the commit that adds the OnePlus 13.
  • oneplus,dodge-panel and synaptics,tcm-spi-hbp have bindings, and the hall sensor node is gone.
  • The hardcoded memory@81960000 map is gone, so sm8750.dtsi's memory@a0000000 is the only memory node. I built the board's DTB at the head with W=1: one warning, the same one sm8750-mtp gets from the SoC dtsi.
  • The CDSP and MPSS commit now says what changes at every boot (CDSP auto_boot, the MPSS carve-out assigned at probe).
  • checkpatch reports no errors, every subject has a prefix, and the series still merges cleanly onto today's base.

Still open:

  1. Sign-offs. The gate still fails on the five commits without their author's Signed-off-by: b17547a13e01 (Teguh Sobirin) and f2551d072f45, 983ae704bf04, 2dcdbdb4fd06, b552309e7420 (index986). You've now also edited index986's commits. That's fine with the [mrlund: …] notes, but the author still has to sign off before I can carry them.
  2. The CDSP and MPSS evidence disagree. Your reply says that on the gpu2 boot both remotes were up and the CDSP loaded. The commit message says the CDSP load and the MPSS assignment "were not re-checked", and that only remoteproc0 (the ADSP) appeared under /sys/class/remoteproc. Which is right? A read-only grep . /sys/class/remoteproc/*/name /sys/class/remoteproc/*/state from a boot with this commit, quoted in the message, would settle it.
  3. The board commit has compatibles that a later commit renames. At f2551d072f45 the board uses qcom,wcn7880-pmu and qcom,wcn7880-bt, which checkpatch flags as undocumented. Later commits change them to qcom,wcn7850-pmu and qcom,wcn7860-bt. Kernel PRs here are merged commit by commit, so please fold the final compatibles into the board commit.
  4. Sources. Two citations should point at something fixed. The board commit's Link: points at a tree in the sm8750-mainline repository rather than a commit, and the WCN7860 baud-rate sequence in hci_qca.c cites another port without a link. Please link the exact commits, and credit their authors the way the kernel does (Co-developed-by: with their sign-off, or at least the link and their name).
  5. Scope. The shared-driver gates, the second Synaptics driver, moving sm8750.config to device/dodge/kernel.config and a smoke report from a boot of this head are still waiting on my decision, as before. I'm adding one item to that list: msm_mdss maps the display TBU at a physical address written into the SM8750 match data. It's gated on the SoC, which our rule accepts, but upstream will most likely want that address from the device tree.

For the record, I checked what this series changes for the Pixels: nothing. Every driver it touches is Qualcomm-only except btqca/hci_qca, which the Pixel 7a's WCN6855 also uses. There the series only adds WCN7860 cases and appends the new type at the end of the enum, so the existing chips' paths and numbers stay as they were.

CI for this push is waiting for my approval. I'll approve it so you can see dtbs_check on the new head.

I'll come back to you on scope. Thanks again for your patience with a series this size.

@mrlund
mrlund force-pushed the dodge/pr-kernel-v1 branch from f5e354e to 1dc357e Compare October 31, 2026 14:22
@mrlund

mrlund commented Oct 31, 2026

Copy link
Copy Markdown
Author

Thanks @derekross, and thanks for approving CI. The branch is now at 1dc357e5ec2d.

1. Sign-offs. Still the same five — I won't invent them. I've asked Teguh and index986. Current hashes:

  • b17547a13 Teguh — Adreno 830 catalog
  • 88fc65ed0 index986 — board (OnePlus 13)
  • b88a38e68 index986 — sm8750.config
  • e5d7b9695 index986 — AA569 panel
  • b1c56fb42 index986 — Synaptics TCM2

Authorship and my [mrlund:] notes are unchanged.

2. CDSP / MPSS. RAM-only boot of this tip with matching modules from a tmpfs overlay. Remoteprocs were NONE before the overlay. After the one-hand omamobile-tip-modules-overlay (tip-aware adsp-battery — no hand modprobe), read-only state (I did not start the modem via omamobile-modem or otherwise):

uname 7.3.0-rc6-g1dc357e5ec2d
remoteproc0  modem  offline
remoteproc1  adsp   running
remoteproc2  cdsp   offline

So in this tree only ADSP actually runs on its own. The commit message has that table (captured on 9957f46a7; this tip only rewrites that message, the tree is identical — 9957f46a70c4^{tree} == 1dc357e5ec2d^{tree}).

3. Board compatibles. Final qcom,wcn7850-pmu / qcom,wcn7860-bt are in the board commit; enable commits are status-only. No wcn7880-* in the series.

4. Sources. Board Link: is the exact add commit (with a clear note where the tip hash differs from the file commit). Panel / touch / config use commit Links too. hci_qca credits Teguh in plain text and links ROCKNIX 686ac3c995c8. I've left Co-developed-by: off; if you're fine carrying his sign-off from the ROCKNIX patch, I'll add both.

5. Scope. Untouched, including the TBU address. Waiting on your call.

kernel-pr-check against today's base: only those five sign-offs fail; checkpatch has no errors; subjects/policy ok. Full-tree dtbs_check via kernel-pr-check --build on this tip vs today's omamobile: 347 device trees build with W=1 and dtbs_check, no new warnings. With yamllint (1.38.0) installed, dt_binding_check on the 8 bindings passes too. Focused dodge earlier still had no new warnings, and the one W=1 warning matches sm8750-mtp.

Device-side tip-image RAM boot of this kernel (UFS-off chain ~64 MiB, boot.img 65a69f36…, modules overlay 90716d0b…, packed at #111 7c3e09a, with device tip eb0b9a2 scripts on the phone) showed omamobile.slot_src=packed on the stage-2 cmdline. The only hand step was omamobile-tip-modules-overlay: after that, display / Wi-Fi / touch / ADSP+battery / BT / sound / sensors / session all came up (no hand insmod / unit restart). Remoteproc: modem offline, adsp running, cdsp offline, battery 100%. Sound card OnePlusdodge registered. Session ok (sddm bounce after DSI — tip starts greeter on simpledrm; on B, sddm.service.d waits for display-msm). Four clk WARNs during msm probe: WARN site is upstream msm DSI PHY (dsi0_phy_pll_out_dsiclk / dsi0_phy_pll_out_byteclk) after DSI PLL(0) lock failed in dsi_phy_driver_probe → orphan reparent. Same four on my gpu2 build (which carries this series), so that doesn't tell me whether the series is involved; I haven't worked out why the PLL doesn't lock at probe. No kernel change for it. Full phone-smoke table is in the #111 reply. Slot B is healthy again after return. A quiet pw-play test tone also ran cleanly on that tip RAM path the same afternoon: 2 s 440 Hz at vol 0.25, 15:03:23–15:03:25 CET, ADSP running, no xrun in the play window, heard from the speaker; then back to healthy B. BRINGUP button notes (confirmed 2026-10-31): Power alone opens the Omarchy power menu (no force-restart); forced restart is Power + Volume Up + Volume Down until reset (no hold time claimed); fastboot is Volume Down while powering on.

@derekross

Copy link
Copy Markdown
Owner

Thank you, @mrlund. The board commit now has the final WCN compatibles, the CDSP/MPSS message has the remote-processor table, and the Links point at commits. Our gate merges your head onto today's base, the touched C files build clean with W=1, and the 347 device trees show no new warnings. Two things remain apart from my scope decision:

  1. Five commits still need their authors' Signed-off-by: b17547a (Teguh Sobirin), and 88fc65e, b88a38e, e5d7b96, b1c56fb (index986).
  2. In "arm64: dts: qcom: sm8750: add Adreno 830 GPU and GMU nodes" the Assisted-by line sits above Teguh's Signed-off-by, as if he had used it. His posted patch ends with just his Signed-off-by, so please put your own lines after his.

On hci_qca: if his patch carries his Signed-off-by, Co-developed-by plus that Signed-off-by is fine with me.

@mrlund
mrlund force-pushed the dodge/pr-kernel-v1 branch from 1dc357e to 4d42223 Compare October 31, 2026 16:49
@mrlund

mrlund commented Oct 31, 2026

Copy link
Copy Markdown
Author

Thanks @derekross.

1. Trailer order. Fixed on the Adreno 830 GPU/GMU nodes commit: Teguh's Signed-off-by first, then my [mrlund:] note, my Signed-off-by, Assisted-by last.

2. hci_qca. His ROCKNIX patch (0045-Bluetooth-qca-add-WCN7860-support.patch under 686ac3c995c8) ends with Signed-off-by: Teguh Sobirin <teguh@sobir.in>, so I added Co-developed-by: Teguh Sobirin <teguh@sobir.in> plus that Signed-off-by on our hci_qca commit.

3. Sign-offs. Asked Teguh and index986 — no reply yet. Won't invent their Signed-off-by. If you're OK with a DCO 1.1 (b) fallback (I checked the published sources; licenses look fine for all five), I can re-sign the commits keeping their authorship, add my Signed-off-by under (b), and note that the original author didn't sign and where / under which license it was published. For the Synaptics driver, the copyright is Synaptics' (GPL-2.0); index986 only carried it, so (b) fits that one better than an index986 sign-off anyway. That would still leave their commits without an author Signed-off-by, so your gate would need to accept a (b) certification from me. Would you take that, or would you rather wait for them?

4. Scope. Still waiting on your call.

@derekross

Copy link
Copy Markdown
Owner

Thank you, the trailers and the Co-developed-by look right now, and the tree hasn't changed, so the earlier builds hold. On the five sign-offs, let's give Teguh and index986 a few days. If they don't answer, I'd take the other route: you as the author of those commits, the original author named in the body with a link to the exact commit, and the original copyright kept in the files. Please also drop the duplicate Assisted-by lines (one per commit is enough).

@HundredBillion

HundredBillion commented Nov 1, 2026 •

Copy link
Copy Markdown

I've got a One Plus 13 and I'll try to help push this along with PRs of my own. In the meantime, send this review to your AI and tell it to verify the findings and make the change requests or push back with evidence:

Review: OnePlus 13 (SM8750) bring-up
This review was performed against commit 4d42223 (46 commits on top of 6beaf6d). It is a code reading only: nothing was built or booted for this review.
Getting display, GPU, Wi-Fi, Bluetooth, audio, touch and cellular data running on a new phone is substantial work, and most of the board description, bindings, and Wi-Fi/Bluetooth support is in good shape. The comments below are in two parts:
The big picture: how this tree keeps phones apart, where this PR crosses those boundaries, and changes to the repo's structure and CI that would prevent it in future PRs.
Specific issues: each with a plain-language summary, followed by the file, the problem, and the expected fix.
Part 1: The big picture
How phones are kept apart today
This repository is a single kernel shared by every supported phone (the Pixels and, with this PR, the OnePlus 13). Phones are separated in three ways:
Each phone has its own hardware description file (a device tree, .dts). It lists the parts in that phone.
Drivers only switch on for hardware listed in that file. A driver written for the OnePlus 13 touchscreen never runs on a Pixel, because no Pixel file mentions it.
One shared kernel configuration. Before this PR, the tree has a single defconfig that builds drivers for the supported phones, and the right description file is chosen at boot. This PR adds a separate sm8750.config fragment for building the OnePlus 13 kernel on top of it.
This works well for code that belongs to a single phone. It does not protect shared drivers: code used by many phones and chips, such as the modem connection (MHI), the mobile data engine (IPA), Wi-Fi (ath12k), the display controller (msm DSI/MDSS) and the audio routing driver (sc8280xp). There is one copy of that code, so a change made for one phone also changes every other device that uses it, unless the change is deliberately limited to that phone.
Where this PR crosses the boundary
This PR contains several changes to shared drivers that apply to all hardware using them, not only to the OnePlus 13. Examples include an extra wait of up to 2 seconds in the modem connection (MHI) code, which runs for every MHI device, IPA tables that SM8550 and SM8650 phones also use, and a new field added to the modem setup message for most older IPA modems. None of these was tested on the other hardware. They are listed individually in Part 2.
The PR also imports two drivers from the phone maker's own kernel (touchscreen and speaker amplifier) where drivers for the same chip families already exist in the tree. Most of the serious bugs below are in that imported code.
Recommended changes to how the repo works
These are recommendations for the repository as a whole, not only this PR. Some of them belong in the CI tool (kernel-pr-check in omarchy-mobile).
Limit every shared-driver change to the hardware it is for. Any behavior change in a shared driver should be selected by per-device data attached to the device-tree match (of_device_id.data, ath12k hw_params, a separate ipa_data file, sc8280xp .codec_dai_fmt), not by changing the code path every device runs. CI could flag any diff under drivers/ that is not a new file, a new match-table entry, or code behind such a flag, so a reviewer must explicitly approve it.
Extend existing drivers instead of adding duplicates. If an in-tree driver covers the same chip family, support goes there. Vendor drivers needed temporarily for bring-up should be kept separate (an out-of-tree module or drivers/staging/) so they don't mix with code intended for merging.
Check that config fragments match the device tree. Build defconfig plus each fragment with scripts/kconfig/merge_config.sh and fail on its warnings (symbols that don't exist, values that don't take effect). Check that every compatible enabled in each phone's device tree has its driver enabled in that build (scripts/dtc/dt_to_config). Fragments should only add options, not contain mass =n lines.
Build and run dtbs_check on every commit, not only the merged result, so a commit that doesn't build or boot on its own is caught.
Require a scripted boot smoke test in the PR template. It should report that /sys/kernel/debug/devices_deferred is empty, that dmesg has no WARN/BUG, and that the device is still working after 60 seconds (unused power rails are switched off about 30 seconds after boot). It should also state the exact config used.
Longer term: one branch per SoC. Other mainline phone projects (Asahi Linux, the linux-msm community trees, postmarketOS's per-SoC kernels) keep each SoC or feature on its own branch, on a common upstream base, and build the release branch by merging those branches together. That would let the SM8750 stack live on its own branch, or follow upstream SM8750 work, without the Pixel kernels depending on it. This also answers the open scope question.
Part 2: Specific issues
Severity:
Blocking: should be fixed before merge.
Should fix: real defects, with a narrower or less certain impact.
Minor: cleanup.
Each item is marked confirmed (verified in the code) or needs verification (the code path is real, but whether it breaks real hardware depends on firmware or on boards not tested here). Line numbers refer to commit 4d42223.
Blocking
B1. The touchscreen driver duplicates an existing driver and trusts data from the touch chip
Plain language: The new touchscreen driver is a copy of the phone maker's driver. The tree already has a driver for this touch chip family that checks its inputs. The new one doesn't, so a bad report from the touch chip can corrupt kernel memory.
Files: drivers/input/touchscreen/syna_tcm2.c, syna_tcm2.h, syna_tcm2_spi.c
Existing driver: drivers/input/touchscreen/synaptics_tcm.c (TOUCHSCREEN_SYNAPTICS_TCM_SPI, compatible syna,s3908). It speaks the same TouchComm v1 protocol (0xa5 marker, continued reads, optional CRC-16) and clamps object counts to TCM_MAX_OBJECTS.
Preferred fix: drop syna_tcm2*, add S3910/this panel's support to synaptics_tcm.c with a new compatible and match data, and update the binding. If that is not possible now, the following must all be fixed in syna_tcm2*:
syna_tcm2.c:433, :443 and the other object_data[obj] writes: obj comes from device data and is used to index object_data[MAX_NUM_OBJECTS] (10) without a check. Reject reports where obj >= MAX_NUM_OBJECTS. The same applies to the FOREACH_ACTIVE_OBJECT loop (:401-407). It runs up to the firmware-reported active_objects count (set at :515), or, when the num_of_active_objects flag is false, keeps incrementing obj while offset < report_size * 8. Neither path is bounded by 10. Confirmed.
syna_tcm2.c:832, and use at :78-114: max_objects from the firmware app info is not clamped, and syna_dev_report_input_events loops to it over object_data[10] and prev_obj_status[10]. Clamp it to MAX_NUM_OBJECTS with a warning. Confirmed.
syna_tcm2.c:1377-1378: syna_tcm_v1_update_crc returns with in.buf_mutex still held when buf_size <= offset + 1, which deadlocks the next transfer. Unlock before returning, or use a single unlock exit label. The bounds checks in the same function are also off by one:
:1381 reads buf[offset + 2] when only buf_size > offset + 1 has been checked;
:1385-1386 checks >= offset + 1 and then reads buf[offset + 1].
Confirmed.
syna_tcm2.c:101-102: divides by firmware_max_x/firmware_max_y from firmware. This path is active because the OnePlus 13 DT sets synaptics,panel-coords. If the firmware reports 0, this is a divide-by-zero. Reject zero during probe, as synaptics_tcm.c does. Confirmed.
Touch report parser (syna_tcm2.c:419 onward): bits = config_data[idx++] can read one byte past the touch_config buffer when the config ends on a field opcode. Check idx < size before each read. Also, static end_of_foreach (:351) keeps its value between reports and should be a local. Confirmed.
syna_tcm2_spi.c:604-641, probe:
every error path leaks the platform_device_alloc device (no platform_device_put), and later failures also leak the regulator and the GPIOs already requested, so a manual rebind then fails with -EBUSY from gpio_request (pinctrl uses devm_pinctrl_get and is not leaked);
syna_spi_parse_dt treats any negative return from syna_of_get_named_gpio (including -EPROBE_DEFER) as "GPIO absent", and always returns 0 (:422);
failures in syna_dev_probe are not passed back, so the SPI device stays bound with no touchscreen;
a single static syna_spi_hw_if and fixed id 0 allow only one instance.
Fix this with devm_gpiod_get, devm_regulator_get, and a single device (no extra platform device). Confirmed.
syna_tcm2_spi.c:646-651, remove order: GPIOs are freed and regulator_put() is called on a still-enabled regulator before the platform device is unregistered. The platform remove then drives the freed reset GPIO and skips regulator_disable. Disable the IRQ, power off, then release resources (devm handles this if item 6 is done). Confirmed.
syna_tcm2.c:2251, :2259-2265, :2294-2305: the result of create_singlethread_workqueue is not checked, and the workqueue is never destroyed. tcm_dev is not freed on the error path. syna_dev_shutdown runs the full remove and kfree(tcm). Confirmed.
syna_tcm2_spi.c:188-207, :298, :379: psu is hard-coded to PSU_REGULATOR, so avdd_gpio is never requested, but syna_spi_power_on still drives it with raw values that ignore the device tree's GPIO_ACTIVE_LOW. vdd_gpio is never initialized (0) but is still driven. Confirmed in code; the hardware effect needs verification.
Binding mismatch:
the binding requires interrupts and references touchscreen.yaml, but the driver ignores both;
the driver reads the synaptics,irq-gpio property (syna_tcm2_spi.c:371) and takes its IRQ only from gpio_to_irq() on it (syna_tcm2.c:689-690);
it uses its own synaptics,panel-coords property instead of touchscreen-size-, and doesn't parse the inversion properties;
it uses deprecated -gpio vendor properties, the vendor prefix synaptics, instead of the registered syna,, and a compatible that doesn't name the chip.
The driver should use interrupts and the standard touchscreen properties. Confirmed.
Power management: syna_dev_suspend/syna_dev_resume are assigned (:2232-2233) but never called. The real PM ops (:2312-2346) only call disable_irq_nosync, so the IRQ thread can still be running SPI transfers when suspend returns, and touches held during suspend are never released. Use disable_irq (synchronous), put the controller to sleep, and release all touch slots. Dead code confirmed; the race needs verification.
Minor:
Kconfig lacks depends on GPIOLIB && OF;
the module declares two MODULE_LICENSE/MODULE_AUTHOR sets and shares syna_spi_device between its files as a non-static global (syna_tcm2_spi.c:74);
vendor leftovers should be removed: unused cdev/procfs/sysfs fields, HAS_REFLASH_FEATURE/HAS_TESTING_FEATURE/REMOVE_OPLUS_FUNCTION, gesture and SIG_
defines, KEY_SLEEP/ABS_PROFILE capabilities that are never reported, <linux/version.h>, and the hand-rolled CRC table (use crc_itu_t);
syna_tcm_buf_realloc fails on a NULL buffer and leaves a dangling buf on that path.
B2. The modem connection change affects every device that uses MHI
Plain language: A workaround for the OnePlus 13 modem was added to code that every Qualcomm Wi-Fi card and PCIe modem also uses. On those devices it adds up to a 2-second delay during startup and can misreport the modem's mode.
Files: drivers/bus/mhi/host/pm.c:816-817, :830-853, :860-861; drivers/bus/mhi/host/boot.c:606-621
Problem:
In mhi_pm_st_worker, the DEV_ST_TRANSITION_SBL case now polls BHI_EXECENV up to 20 times at 100 ms intervals for every MHI controller. That covers ath11k QCA6390/WCN6855, ath12k WCN7850 and mhi_pci_generic modems.
The poll treats MHI_EE_FP (firehose/flash mode) as mission mode, so a modem going SBL→FP gets MHI_CB_EE_MISSION_MODE where it previously got the FP transition. Transitions queued during the poll are delayed.
boot.c:606-621 queues an extra transition from the register for every controller, without checking MHI_REG_ACCESS_VALID.
The new "skip if already in this EE" checks mean a device already in FP that later reports AMSS without a reset skips the mission-mode transition.
Fix:
Add a controller-level opt-in flag (for example a new bool in struct mhi_controller, set only by ath12k for WCN7860) and run the poll and the extra transition only when it is set.
Remove MHI_EE_FP from the condition that queues DEV_ST_TRANSITION_MISSION_MODE.
Check MHI_REG_ACCESS_VALID before reading the register.
Consider moving the poll out of the state worker (a delayed work item), so other transitions aren't blocked.
Status: delay and FP mapping confirmed; early mission mode needs verification.
B3. The IPA "v5.5 fix" changes data used by SM8550 and SM8650 phones
Plain language: Settings for the OnePlus 13's mobile data engine were changed in a table that two other Qualcomm chips also use. If the old values were correct for those chips, their mobile data breaks.
File: drivers/net/ipa/data/ipa_data-v5.5.c:53-60, :89-90, :138, :171 (commit 0244a2b)
Problem:
The commit swaps the DDR/PCIe QSB max_writes/max_reads.
It moves AP_LAN_RX to channel 14 / endpoint 17, AP_MODEM_RX to endpoint 24, and MODEM_AP_RX to endpoint 22.
That table is used by qcom,sm8550-ipa, and SM8650 falls back to that compatible (sm8550.dtsi:3058, sm8650.dtsi:4419).
AP_MODEM_RX's endpoint ID is sent to the modem as ctrl_comm_dest_end_pt (ipa_qmi.c around line 335).
AP_MODEM_RX keeps channel 1 while its endpoint changes, which hasn't been checked against downstream.
Fix: revert the changes to the shared v5.5 tables. Give SM8750/Eliza their own copies of the endpoint and QSB tables, referenced from ipa_data_v5_5_eliza (which currently shares the v5.5 tables). If the old values are actually wrong for SM8550, that is a separate fix tested on SM8550.
Status: that it changes other SoCs is confirmed; whether it breaks them needs verification.
B4. A new field in the modem setup message now reaches older modems, and on two of them its counter range may not fit
Plain language: A new field in the modem setup message, added for the OnePlus 13, is now also sent to several older modems that have never received it. On two older chip versions, the range of counters it describes may be larger than the memory area set aside for them.
Files: drivers/net/ipa/ipa_qmi.c:399-413; fnr_idx_cnt = 52 added in ipa_data-v4.5.c, -v4.7.c, -v4.9.c, -v5.0.c, -v5.5.c (commit 7f0a6f6)
Problem:
The filter-stats TLV (0x23) is added to the existing INIT_DRIVER request. It is sent when the IPA version is ≥ 4.5, fnr_idx_cnt is non-zero, and a STATS_FILTER_ROUTE region exists. At this commit that covers SDX55 (v4.5), SM8350 (v4.9), SDX65 (v5.0), and SM8550/SM8650 (v5.5). If modem firmware rejects the field, INIT_DRIVER fails and mobile data stays down.
On v4.5 and v4.9 (ipa_data-v4.5.c:384-386, :422; ipa_data-v4.9.c:382-385, :420), STATS_FILTER_ROUTE is 0x800 bytes (128 counters of 16 bytes). The reported start_addr/size pair (size 52 × 16 = 0x340) fits inside the region. The request also reports start_index/end_index 128–179, though. If firmware treats those as counter positions from start_addr, counters run to 0xb40, which is 0x340 bytes past the end of the region. The Eliza layout (0xc40 / 16 = 196 = 128 + 68) suggests that interpretation; under it, the v5.0 and v5.5 regions (0xba0 = 186 counters) fit.
The value is also inconsistent: v4.7 gets 52 but has no filter/route stats region, so it has no effect, and v5.2 has the region but stays at 0.
Fix: set fnr_idx_cnt only in the SM8750/Eliza ipa_data. Leave all other versions at 0, which the existing check already handles safely.
Status: that the field now reaches these older modems is confirmed. Firmware rejection and the v4.5/v4.9 overrun need verification, because both depend on how modem firmware interprets the field.
B5. The kernel config fragment disables the GPU and never enables the speakers
Plain language: The settings file for this phone switches off a part the GPU needs and never switches on the speaker driver. A kernel built from it would have no GPU and no audio.
File: arch/arm64/configs/sm8750.config
Problems:
Line 38, CONFIG_SM_GPUCC_8750=n, overrides =m in defconfig. That symbol builds both gpucc-sm8750.o and gxclkctl-kaanapali.o (drivers/clk/qcom/Makefile:205), so the GPU, GMU and Adreno SMMU nodes wait on missing clocks forever. Confirmed.
CONFIG_SND_SOC_AW882308 is enabled nowhere and has no default (sound/soc/codecs/Kconfig:667), so the speaker codecs never register and the whole qcom,sm8750-sndcard waits, including the headset. Confirmed.
The file is a dump of a v6.16 vendor config, not a minimal fragment.
About 700 =n lines turn off options and drivers other boards use. For example, CONFIG_ARCH_ROCKCHIP=n (line 488; =y in defconfig) and CONFIG_DRM_ROCKCHIP=n (line 722; =m in defconfig). Some =n lines are overridden by other options' selects and do nothing, such as SND_SOC_MAX98357A=n.
About 33 symbols don't exist in this tree. Examples: ARM64_APPENDED_DTB, TOUCHPANEL_CUSTOM, OPLUS_FW_UPDATE, TOUCHPANEL_NOTIFY, SLIM_QCOM_CTRL, PHY_QCOM_SNPS_EUSB2, BT_HS, ANDROID, INPUT_TRI_KEY, EXT3_FS, and various ARCH_* and EFUSE entries. Confirmed.
Fix: replace the file with only the =y/=m options this phone needs beyond defconfig, including CONFIG_SND_SOC_AW882308=m and the new panel and touchscreen options, and no =n lines. Check it with scripts/kconfig/merge_config.sh -m arch/arm64/configs/defconfig arch/arm64/configs/sm8750.config and make sure there are no warnings. Please also state which config the smoke tests in the PR description were run with.
B6. The display panel never turns on its own power supplies
Plain language: The panel driver relies on its power rails having been left on by the bootloader. Linux switches off unused rails about 30 seconds after boot, so the screen can go dark.
File: drivers/gpu/drm/panel/panel-aa569-p-3-a0019-dsc.c:382-444
Problem: probe and prepare never request or enable the vddio, vci and vdd supplies. The binding (oneplus,dodge-panel.yaml) and the DT (sm8750-oneplus-dodge.dts:1476-1478, l12b/l13b/l11b, none regulator-always-on) declare them. With no consumer, regulator_late_cleanup can switch them off, and they are never turned off on unprepare.
Fix:
Use devm_regulator_bulk_get in probe.
In prepare, enable the supplies in the panel's documented order before releasing reset; in unprepare, disable them after asserting reset.
Handle errors so a failure in prepare disables what was enabled.
Status: confirmed.
B7. The panel driver's Kconfig selects the wrong helper
Plain language: The build settings for the panel driver name the wrong supporting library, so some kernel builds fail.
File: drivers/gpu/drm/panel/Kconfig:1451
Problem: select DRM_DISPLAY_DP_HELPER, but the driver calls drm_dsc_pps_payload_pack() (panel-aa569-p-3-a0019-dsc.c:266), which is built under DRM_DISPLAY_DSC_HELPER. In configs where nothing else selects the DSC helper, the build fails with an undefined symbol.
Fix: replace it with select DRM_DISPLAY_DSC_HELPER, matching the VTDR6130 entry at :1420.
Status: confirmed.
Should fix
S1. The MDSS driver reads a hard-coded hardware address on every display power-up
Plain language: The display code reads a fixed memory address that belongs to a different hardware block and isn't described anywhere. On some firmware this could freeze the phone.
File: drivers/gpu/drm/msm/msm_mdss.c:549, :593 (hf_qtb_base = 0x017d0000), :422 (devm_ioremap), :250 (readl, called from msm_mdss_enable() at :283)
Problem:
The address is only used for qcom,sm8750-mdss, so other SoCs are unaffected, but it applies to every SM8750 board.
The region isn't described in the DT (sm8750.dtsi has only apps_smmu: iommu@15000000, no TBU node), isn't claimed, and its power and clock dependencies aren't voted for.
Where firmware guards that space, or the TBU is powered down, the read can cause an external abort or bus hang on each display resume. The commit message says the mechanism is unconfirmed.
Fix: describe the TBU in the device tree and access it through an SMMU/TBU driver hook, or drop the read until the mechanism is understood.
Status: needs verification (depends on firmware).
S2. ath12k leaks memory on unbind and on each resume/recovery
Plain language: Two small memory leaks in the new Wi-Fi chip support. One grows every time the phone wakes from sleep.
File: drivers/net/wireless/ath/ath12k/qmi.c
:3289 (and ath12k_qmi_load_mem_file, around :3257): mem->size is set but m3_mem->total_size isn't, while ath12k_qmi_m3_free (:3250) frees total_size bytes. As a result, on unbind (ath12k_qmi_deinit_service) the phy_ucode20.elf buffer is freed with dma_free_coherent(dev, 0, …). At best that leaks the buffer; depending on the DMA backend, a size-0 free of a real allocation may do worse. Fix: set total_size along with size. Confirmed (the size-0 free); the exact consequence depends on the DMA backend.
:4122: ath12k_qmi_tme_lite_info_send calls dmam_alloc_coherent on every load_bdf, which runs on each boot, recovery and resume (the chip sets supports_suspend=true). The buffers are only released on driver unbind, and they come out of the 28-bit (256 MiB) DMA window, so allocations eventually fail. Fix: allocate once and reuse, or free after the QMI exchange. Confirmed.
S3. Two ath12k behavior changes apply to all chips
Plain language: Two Wi-Fi changes affect every chip the ath12k driver supports, not just the OnePlus 13's.
ath12k/qmi.c:4303-4312, :4337-4343: the COLD_BOOT_CAL_DONE_IND handler is registered for every chip and sets ab->qmi.cal_done = 1 permanently. That value is then sent in host_cap (:2328) on every later boot, where ath12k previously always sent 0. Fix: register the handler only for WCN7860 and reset cal_done where appropriate. Needs verification.
ath12k/core.c:1669: ath12k_coredump_collect now runs for crashes before FW_READY on all ath12k PCI chips. This can copy half-initialized target_mem while QMI setup is still in progress, and it overwrites (leaking) a still-queued ab->dump_data. Fix: gate it to WCN7860 and handle an existing pending dump. Needs verification.
ath12k/wmi.c:6990-6991: on REG_STATUS_DROP, pdev_idx is now set from reg_info->phy_id, so the existing complete_all(&ar->regd_update_completed) at :7044 now fires for all chips. This looks correct but should be called out in the commit message. Confirmed, benign.
S4. The IPA binding lists a fallback that would crash SM8750
Plain language: The hardware description says the new chip can be treated like an older one. A kernel that only knows the older chip would load the wrong memory layout for the new one. The Eliza commit message reports that the phone halts and reboots in that case.
Files: Documentation/devicetree/bindings/net/qcom,ipa.yaml:61-66, arch/arm64/boot/dts/qcom/sm8750.dtsi:2186
Problem: Eliza and SM8750 list qcom,sm8550-ipa as a fallback, but they need a different memory layout (68 filter/route counters, no AP_V4_FILTER/AP_V6_FILTER) and the new TLV.
Fix: make them standalone enum entries with no fallback, and update the DT.
Status: confirmed in the binding.
S5. Two IPA commits break bisect
Commit f7bc6b8 adds the IPA node to sm8750.dtsi with 4-cell GIC interrupt specifiers, while the GIC has #interrupt-cells = <3> (sm8750.dtsi:5727). The node is disabled there, so nothing fails yet. Once 925acbc enables it on the OnePlus 13, probe fails with -ENXIO until 03ad2a2 corrects the specifiers. Fix: squash 03ad2a2 into f7bc6b8. Confirmed.
S6. The speaker amplifier driver duplicates an existing driver
Plain language: The speaker amplifier driver is new code for a chip family the tree already supports.
File: sound/soc/codecs/aw882308.c
Problem:
The in-tree aw88081 driver uses the same register addresses 0x00–0x06 (ID/SYSST/SYSINT/SYSINTM/SYSCTRL/SYSCTRL2/I2SCTRL1).
It already handles several chip IDs (AW88083 at aw88081.c:1075) and loads profiles through the aw88395 ACF loader.
The new driver uses its own aw882308-.bin (reg,val) format and ignores every regmap
error after the ID read.
The binding (awinic,aw882308.yaml:19) fixes awinic,aw882308 as a permanent compatible, while the driver (aw882308.c:11) calls the name provisional and derives it from product ID 0x2308.
Fix: add 0x2308 to aw88081 with a variant table for the different field bit positions. If that isn't possible, check every regmap return value, and confirm the actual part number before the compatible is merged.
Status: needs verification (whether the variant fits aw88081).
S7. The sound card change isn't limited to SM8750
File: sound/soc/qcom/sc8280xp.c:196-203
Problem: the new MI2S case calls snd_soc_runtime_set_dai_fmt(I2S | NB_NF | BC_FC) and returns early for every compatible, and its return value is ignored. No regression was found on existing boards, because hw_params resets the CPU format and boards that set codec_dai_fmt use the same value. Still, it changes shared code when a per-board mechanism exists.
Fix: use .codec_dai_fmt in sm8750_priv_data (:562) instead, and check the return value.
Status: confirmed ungated, no known regression.
S8. Device tree details
sm8750-oneplus-dodge.dts:1527-1528: the node is labelled bq28z610 but uses compatible = "ti,bq27541". The bq27xxx driver has different register maps for the two (bq28z610: AP at 0x22, no NAC; bq27541: AP at 0x24, NAC at 0x0c). Use ti,bq28z610 if that is the actual part. Needs verification.
:1146, :1148: interrupts = <162 0x2008> and synaptics,irq-gpio = <&tlmm 162 0x2008> carry the downstream flag 0x2000, which isn't a valid flag. Use IRQ_TYPE_LEVEL_LOW / GPIO_ACTIVE_LOW. Confirmed.
:151: orientation-gpios = <&tlmm 61 …>; // qrd value is copied from the QRD reference board. Confirm it for this phone. Needs verification.
S9. Panel driver error handling
panel-aa569-p-3-a0019-dsc.c:268-278: if the PPS or compression_mode command fails, prepare returns without asserting reset (the init failure at :262 does). Assert reset, and disable the supplies from B6, on every error path. Confirmed.
:334-338, :352-356: backlight ops don't restore MIPI_DSI_MODE_LPM on error, and send DCS without checking that the panel is prepared. Restore the flag on all paths, and return early when unprepared. Confirmed.
:230, then :266-274: display-on and exit-sleep are sent before PPS and compression enable. This is harmless in command mode before the first frame but unusual, so consider sending PPS first. Minor.
S10. The DSI format override is a workaround
File: drivers/gpu/drm/msm/dsi/dsi_host.c:862-865
Problem: it forces an RGB888 DST format for command-mode DSC with RGB101010. No other upstream panel is affected. However, it applies regardless of widebus, while the existing check at :1752-1760 says downstream does this only without widebus.
Fix: limit it to the non-widebus case, or explain in the commit message why it applies with widebus.
Status: needs verification.
S11. Bluetooth baud-rate timing
drivers/bluetooth/hci_qca.c:1432: qca_peri_set_baudrate queues the WAKE_IND and baud-rate packets on txq without calling hci_uart_tx_wakeup, so they go out together with the later BT baud command and the intended 10 ms and 100 ms gaps have no effect. Call hci_uart_tx_wakeup() after queuing each one. Confirmed in code; on-wire impact needs verification.
Minor
a6xx_catalog.c:2259-2316: a830_ifpc_reglist saves CP_PROTECT_GLOBAL(0..46) and (63) but not GLOBAL(47) (0x27c02, :2203), which a830_protect_regs writes. The impact is reduced because the same value is in CP_PROTECT_PIPE(15). Add GLOBAL(47).
Not verified: whether A830 needs the A840-only RSC poll bit (a6xx_gmu.c:648, BIT(30) vs BIT(16)). Worth checking against downstream gen8_0_0.
Pre-existing, not from this PR: ipa_qmi.c:385 and :395 adds ipa->mem_offset to a size for hw_stats_quota_size/hw_stats_drop_size.
Checked and found correct
pcie-qcom.c iommu-map parsing: the existing 1-cell format behaves as before, and the fallback to 1 cell when the phandle lookup fails is safe. (A malformed iommu-map shorter than 3 cells is still read out of bounds, as before this PR.)
QMI encodings for TME-Lite, QDSS and IPA filter stats: sizes, types, offsets and maximum lengths match their structs, and no tlv_type collides.
Apart from the items in S3, the WCN7860 Wi-Fi and Bluetooth changes are limited by device ID, hw_rev or soc_type (DMA mask, regdb skip, QDSS, TME-Lite, phy_ucode, pci.c, hw.c/hal.c, btqca, hci_qca).
adreno_is_a830() is an exact chip-ID match, so no existing GPU is misclassified.
DSC geometry: slice height 22 (3168/22 = 144 slices), 2 × 720 = 1440 width, 10 bpc / 8 bpp, line_buf_depth = 11.
GMU/GPU binding changes match the DT node.
Eliza/SM8750 IPA memory regions are 8-aligned and fit in ipa-shared. The interconnect, clock and IMEM references point at nodes and IDs that exist in the tree.
No reserved-memory regions overlap, no GPIO is claimed twice in pinctrl, and the Adreno SMMU cell and interrupt counts are consistent.

mrlund and others added 15 commits November 1, 2026 09:32
qcom_pcie_config_sid_1_9_0() reads "iommu-map" as fixed 4-cell records
{bdf, phandle, sid, len}. SM8750 now uses #iommu-cells = <2> on
apps_smmu, so each record has 5 cells. The second record was read as
BDF 0x0001 with a garbage SID, BDF 0x0100 (the endpoint) got no
BDF_TO_SID entry, and its TLPs went out with the base SID 0x1400.

DMA still worked, because the root port and the endpoint share one
SMMU domain, but the ITS takes the DeviceID from that SID: endpoint
MSIs arrived as DeviceID 0x1400. The WCN7860 BHI interrupt (EventID 0)
landed on the root port's PME/AER vector and MHI timed out.

Read #iommu-cells from the IOMMU node and step through the records
with stride 3 + #iommu-cells.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
… rejected

ath12k_reg_chan_list_event() leaves pdev_idx at 255 on the
ATH12K_REG_STATUS_DROP path (e.g. firmware rejects the requested
country), so the 'out' label never finds an ar and never signals
regd_update_completed. ath12k_regd_update() then waits for the full
ATH12K_REG_UPDATE_TIMEOUT and logs 'Timeout while waiting for
regulatory update'. Resolve the pdev from the event's phy_id on the
DROP path when it is in range so the waiter is released.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The Adreno 830 GPU of SM8750 uses the chip-id compatible
qcom,adreno-44050000. It already matches the generic chip-id pattern.
Like the other A7xx/A8xx parts its clocks live in the GMU node, so add
it to that list. It is not added to the two-region list: the SM8750 GPU
node also describes the cx_dbgc region, which the generic three-entry
reg-names list already allows.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The SM8750 GMU (qcom,adreno-gmu-830.1) has the same single register
region and the same five clocks (ahb, gmu, cxo, memnoc, hub) as the
Adreno 840 GMU, so share the 840.1 constraints.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Document the Awinic AW882308 (chip id 0x2308) smart amplifier used for
the speakers and the earpiece of the OnePlus 13. It is controlled over
I2C, takes I2S/TDM audio and has an optional reset line. Unlike the
AW88395 family it needs no channel or firmware-name property, so it
gets its own schema.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
WCN7860 is the WCN7850 successor used with SM8750. Its Bluetooth part
is powered from the same PMU outputs, so document it in the WCN7850
schema.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Add the SM8750 GPU clock controller, the GX clock controller and the
Adreno SMMU. The Adreno 830 GPU and GMU nodes in the next commit need
them. They come from ROCKNIX SM8750 patch 0033, which takes them from
the upstream SM8750 gpucc DT series.

Link: ROCKNIX/distribution@620baca
[mrlund: backported ROCKNIX SM8750 patch 0033 (ROCKNIX, no original
 Signed-off-by) to 7.3-rc6]
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Backport of ROCKNIX SM8750 patch 0038 (Teguh Sobirin), based on the
upstream 'drm/msm: Support for Adreno 830 GPU' series. GPU disabled by default.

The GPU register range covers the A830 RSCC at GPU base + 0x50000:
a6xx_gmu_init() maps it there, and with only 0x40000 mapped the first
runtime suspend faulted in a6xx_rpmh_stop(). Stock kgsl lists the RSCC
at 0x3d50000 size 0x10000, so the range is 0x60000.

Link: https://github.com/ROCKNIX/distribution/blob/620bacab32a18f4338e290c898d44c45f6db145a/projects/ROCKNIX/devices/SM8750/patches/linux/0038-arm64-dts-qcom-sm8750-add-GPU-nodes.patch
Signed-off-by: Teguh Sobirin <teguh@sobir.in>
[mrlund: backported to 7.3-rc6; squashed in the fix that grows the GPU
 register range to 0x60000 so it covers the A830 RSCC]
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Backport of ROCKNIX SM8750 patch 0049 (Teguh Sobirin). chip id 0x44050000,
firmware gen80000_{sqe,gmu,aqe}. The GX GDSC and GXPD-vote fixes (ROCKNIX
0050/0051) are already in 7.3-rc6.

Link: ROCKNIX/distribution@620baca
[mrlund: backported ROCKNIX SM8750 patch 0049 to 7.3-rc6; the ROCKNIX
 patch carries no Signed-off-by from the author]
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Add oneplus,dodge to the SM8750 board compatible list.

Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Schema for the OnePlus 13 DSC panel driven by
panel-aa569-p-3-a0019-dsc.c. Placed before the board DTS and the
panel driver that use this compatible.

Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Schema for the Synaptics TouchComm SPI HBP controller used on the
OnePlus 13 (S3910). Placed before the board DTS and the syna_tcm2_spi
driver that use this compatible.

Vendor properties (panel-coords, tx-rx-num, *-gpio) match what the
carried Synaptics driver already reads; converting to standard
touchscreen-* / reset-gpios would be a larger driver change.

The oplus,dhall-ak09970 hall node has no driver in this tree and the
oplus vendor prefix is not in vendor-prefixes.yaml; it is dropped in
the board DTS rather than adding an unused binding.

Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Add a device tree for the OnePlus 13 (SM8750, codename dodge), carried
over from the sm8750-mainline v6.16 tree: regulators, UFS, USB, the
AA569 DSI panel, the Synaptics touchscreen, buttons, battery and
charger, and the ADSP. The CDSP and modem are described but stay
disabled. Later commits in this series enable Wi-Fi/Bluetooth, audio,
rmtfs and the GPU on top of it.

The memory map is left to sm8750.dtsi's memory@a0000000 (size 0); ABL
fills it on a normal boot, and the dodge chainload stage2-dtb fills it
from the phone's live FDT for kexec. A hardcoded memory@81960000 map
from the v6.16 tree is dropped so it does not sit alongside that node.

The WCN PMU and Bluetooth nodes use the final documented compatibles
(qcom,wcn7850-pmu and qcom,wcn7860-bt) from the start; they stay
disabled until later enable commits. The intermediate undocumented
wcn7880-* names never appear.

Link: sm8750-mainline/linux@0c17a4d644f0
[mrlund: Link is the sm8750-mainline commit that added
 sm8750-oneplus-dodge.dts (0c17a4d644f0). Taken from that tree's v6.16 tip
 commit 16cf517b2781 ("Very important fix") (index986, with contributions from
 others in that history; no Signed-off-by there) and ported to 7.3; CDSP
 and modem left disabled; DT cleanup for schema: dropped ddr_device_type,
 chip-name, panel_type, firmware_name, tp_ic_type, S3910_PANEL7 and TLMM
 input-enable on ts_int_active; renamed touchpanel,* to
 synaptics,panel-coords / synaptics,tx-rx-num; dropped oplus,dhall-ak09970
 hall node and its pinctrl (no in-tree driver, oplus not in
 vendor-prefixes.yaml); left i2c_hub_9 empty; dropped the hardcoded
 memory@81960000 map so only sm8750.dtsi's memory@a0000000 remains for the
 bootloader / stage2-dtb to fill; folded final wcn7850-pmu / wcn7860-bt
 compatibles into this board commit so there is no later rename]
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Config fragment used on top of the omamobile defconfig to build the
OnePlus 13 (dodge) kernel: the SM8750 pinctrl, display, touch, audio
and fuel-gauge options, plus early-boot builtins the qcom-abl chain
needs (UFS host/PHY, USB gadget/configfs, Type-C, TCSRCC, simpledrm,
and SM_GPUCC_8750 so Adreno SMMU/GPU clocks are present before the
modules overlay). dodge's initramfs ships no modules, so those cannot
stay =m.

Link: sm8750-mainline/linux@ff68fefaca26
[mrlund: taken from the sm8750-mainline v6.16 tree (no Signed-off-by
 there) and adjusted for 7.3; early-boot =y for the abl chain]
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Add a driver for the AA569 (P_3_A0019) 1440x3168 DSC panel used on the
OnePlus 13. The panel is driven in DSI command mode, as the stock
bootloader and kernel do; video mode leaves it blank.

The driver is carried over from the sm8750-mainline v6.16 tree and
adjusted for 7.3, which no longer has dsc_slice_per_pkt.

Link: sm8750-mainline/linux@23399a4ff9a1
[mrlund: taken from the sm8750-mainline v6.16 tree (index986, with fixes
 from AaronKel there; generated by linux-mdss-dsi-panel-driver-generator;
 no Signed-off-by there); switched to command mode, ported to 7.3, style
 fixes]
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
mrlund and others added 25 commits November 1, 2026 15:31
Two Awinic amplifiers (product id 0x2308) on hub I2C4 at 0x34 (left)
and 0x35 (right), active-low resets on TLMM 2 and 164. The compatible
is provisional until the part has a binding.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
MI2S codecs such as speaker amplifiers are clock consumers; set the
runtime format to I2S with the codec as consumer so the q6 I2S DAI
drives BCLK and WS.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Secondary MI2S on q6apm to the two speaker amplifiers, with the i2s1
pins in their active state.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The OnePlus 13 has a WCD939x on the RX and TX SoundWire masters (reset
on GPIO 101, supplies as on stock). Its built-in microphones are analog
mics AMIC1 and AMIC5 on MIC BIAS1. Describe the codec and route its
ADCs into TX codec DMA 3 so the card gets a capture PCM.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The OnePlus 13 has no 3.5 mm jack: analog headsets use USB-C audio
accessory mode through the WCD939x USBSS switch at 0xe on QUP I2C3
(no reset line, as on stock). Link it into the pmic-glink connector's
SBU port and the codec's headset port, and add the WCD playback link
from RX codec DMA 0 to HPHL/HPHR.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The Bluetooth half of the WCN7860 sits on QUP UART14, as on stock
(qcom,msm-geni-serial-hs at 0x898000 with the BT wake byte). Enable
the qcom,wcn7860-bt node. Power comes from the PMU node's bluetooth
target.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The panel's VCI supply (vreg_l13b_3p0) was constrained to 1.8 V. Stock
asks for 3.0 V on that rail, and the SM8750 MTP and QRD boards set
vreg_l13b_3p0 to 3.0 V. Use 3.0 V.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Stock allocates a 4 MiB rmtfs buffer (client-id 1) at boot. Mainline
needs a fixed carve-out for rmtfs, so reserve one at the same place
SM8650 uses, just below tz_merged. It is plain System RAM on stock.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
dsi_get_cmd_fmt() returns CMD_DST_FORMAT_RGB101010 for RGB101010
panels. On the OnePlus 13 AA569 panel (DSC, widebus, SM8750) the first
DCS command then times out. The panel works with RGB888, the format
used before the RGB101010 case existed, so keep RGB888 when DSC is
enabled.

The AA569 panel needs this override together with widebus; gating the
fallback to !widebus would break that panel. Other DSC+widebus boards
that truly need RGB101010 can revisit this later.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Minimal I2C/regmap codec driver for the two Awinic smart amplifiers
(product id 0x2308) on the OnePlus 13. Register tables come from
firmware files generated from the phone's own ACF; volume is capped
until speaker protection and calibration exist.

The amplifier is unmuted from the DAI trigger, once BCLK is running,
because it does not lock to a clock that starts after the unmute.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
On the OnePlus 13 the top speaker doubles as the earpiece, using the
stock Receiver tuning. Add an "Amp Profile" control (Speaker/Receiver)
that loads aw882308-<addr>[-receiver].bin. The table is applied in
hw_params while the amplifier is powered down and before the I2S setup,
which it would otherwise overwrite; applying it at unmute left the PLL
unlocked (SYSST 0x0011). The volume floor applies to both profiles.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
On the OnePlus 13 (SM8750) a warm reboot often comes up with a black
panel. The panel driver's first DSI command-mode DMAs (memory fetches by
VBIF client xin7) complete twice and the third never does: "cmd dma tx
failed", "Failed to initialize panel: -110", DSI STATUS0 0x20003, lanes in
stop state, no DSI error and no SMMU fault, the iova still translates.
A DSI soft reset, a DSI link/PHY power cycle, a panel rail cycle, a VBIF
halt and the MDSS BCR do not clear it, and commands sent through the DSI
TPG FIFO (no memory fetch) still go through. It is never seen after a
true cold start.

The stale state survives the warm reset in the fetch path behind VBIF,
in the display QTB500 TBU of the apps SMMU (mdp_hf_qtb): a single CPU
read of its SWID_LOW register (offset 0; the downstream qtb500 driver
uses the same read as its write_sync) before the first fetch prevents
the third-fetch hang. Reading it after the hang does not recover it, so
the read has to come before the first fetch. The likely mechanism is
that a config-port access resynchronises the QTB clock/idle handshake
that the bootloader's warm reset left stuck; this is not confirmed by
documentation. Two controls at the same point do not help, which rules
out a plain bandwidth or MDSS-side wake:
 - an extra mdp0-mem interconnect vote (400 MB/s avg, 1.6 GB/s peak),
 - a read of the MDSS VBIF.

Results on warm boots where the bootloader splash autorefresh had
stalled at takeover (INTF1 line count 0xc60, the boots that fail),
2026-10-23:

  arm                        stalled boots   other boots
                             good/bad        good/bad
  QTB read (this patch)      8/0             11/0
  no read (two controls)     2/2             15/0
  extra mdp0-mem icc vote    0/1             6/0
  VBIF read                  0/1             1/0

Do the read in msm_mdss_enable(), after the MDSS clocks and interconnect
votes are up and before any display master fetches, so it also runs on
every runtime resume (screen wake).

The QTB is not a resource of the MDSS device and mainline DT has no node
for the SM8750 TBUs, so for now its physical address is per-SoC match
data (sm8750_data.hf_qtb_base; SM8750 gets its own msm_mdss_data for
it, since it shared data_57k) mapped with devm_ioremap(). Upstream, this
should become a DT phandle to a TBU node, or a sync hook in arm-smmu-qcom
(to be settled with the SMMU maintainers).

The same read covers the stall after an MDSS_GDSC collapse, so the GDSC
does not have to be kept on.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
WCN7860 (PCI 17cb:110e) sets BHI_EXECENV to SBL, and later to AMSS,
before the host has an event ring that could carry the EE event, so
the event never arrives and the 90 s wait expires.

Opt in with mhi_controller.ee_reg_continue (ath12k sets it for
WCN7860 only). After the BHI load, continue from the register when it
already shows SBL or AMSS/WFW and REG_ACCESS_VALID. After the AMSS
download, poll BHI_EXECENV for up to 2 s and queue the mission-mode
transition for AMSS/WFW only (not FP). Controllers that leave the flag
clear are unchanged. Duplicate SBL / mission-mode transitions are still
ignored when the event and the register path both fire.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
WCN7860 (PCI 17cb:110e, "peach", the Wi-Fi/BT combo on SM8750 phones)
reports SOC hw version 2 like WCN7850. Its UMAC register map, window
register (0x3278), RX descriptor and 32-bit REO TLV rings are QCC2072's
instead.

Add ATH12K_HW_WCN7860_HW20 with the QCC2072 HAL map and hw_params
based on QCC2072 (firmware in WCN7860/hw2.0), and claim the device in
the wifi7 PCI driver. ATH12K_PCI_DEVICE_ID_WCN7860 goes in core.h,
because QMI also needs it.

Two differences from QCC2072:
- The host feature list is PERST_NO_PULL | AUX_UC_SUPPORT (0x50),
  without QDSS_CFG_MISS. With that bit set, the firmware starts
  initializing before the host has sent the aux ucode and QDSS config,
  refuses both with QMI error 90 and asserts in the aux MAC wakeup.
  The vendor driver sets the bit only when the QDSS file is missing.
- The DMA masks are limited to 28 bits. Without that, coherent
  allocations for this chip land at the top of the 32-bit space, while
  the vendor driver's DMA window for it is the low 384 MiB. The 28-bit
  mask keeps the firmware segments inside that window.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
WCN7860 needs more from the host before it reaches mission mode than
the other chips:

- TME-Lite: the vendor driver hands tmel_peach_20.elf to the firmware,
  by DMA address over QMI (WLFW_TME_LITE_INFO, 0x5B), after target
  capabilities and before board data. A failure is logged and the
  sequence continues, as the vendor driver does.
- M3: the M3 image is phy_ucode20.elf, loaded into DMA memory and
  announced with the usual M3 info request.
- QDSS trace config: qdss_trace_config_v2.cfg is sent after the aux
  ucode (WLFW_QDSS_TRACE_CONFIG_DOWNLOAD, 0x44). A missing file is not
  fatal.
- Regdb: board-2.bin has no regdb for this chip, so a failed regdb
  load does not stop the board data download.
- The cold-boot calibration done indication (0x3E) is handled, so a
  later host capability message reports cal_done.

All of it is keyed on the WCN7860 device id. Other chips take the
existing paths.

The aux ucode is loaded by the existing QCC2072 code, from
WCN7860/hw2.0/aux_ucode.bin (the vendor aux_ucode20.elf).

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
…READY

If the firmware crashes before QMI FW_READY, ath12k_core_reset() only
warns and returns, and the RDDM dump that the MHI layer captured is
lost. Collect it before returning, so early firmware crashes, like
those seen while bringing up WCN7860, can be analysed. Also log RDDM
entry at debug level.

Assisted-by: Grok
Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
WCN7860 (peach, the Wi-Fi/BT combo on SM8750 phones) is a WCN7850
derivative on UART. Its rampatch is an ELF image (gngbtfwXX.mbn) and
its NVM is gngbtnvXX.*, and the peripheral (UWB) core sharing the UART
needs its own baud rate packet before the speed change.

Add QCA_WCN7860 with the WCN7850 handling plus those differences and
the qcom,wcn7860-bt compatible. Power still goes through the WCN7850
power sequencer.

Based on the ROCKNIX SM8750 patch by Teguh Sobirin (From: Teguh
Sobirin <teguh@sobir.in>), which carries his Signed-off-by there.

WCN7860 is added next to WCN7850 in the regulator/power, enable-gpios
and power-off switches. Its soc data does not set
QCA_CAP_HFP_HW_OFFLOAD, which WCN7850 has; that stays off until it is
tested on WCN7860.

Link: ROCKNIX/distribution@686ac3c995c8
Co-developed-by: Teguh Sobirin <teguh@sobir.in>
Signed-off-by: Teguh Sobirin <teguh@sobir.in>
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Zap shader from the stock (OEM-signed) firmware, installed on the phone
as qcom/sm8750/OnePlus/gen80000_zap.mbn.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Document qcom,eliza-ipa for the Eliza platform, which uses IPA
version 5.5.1 (a minor revision of v5.5).

Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
Link: https://lore.kernel.org/linux-arm-msm/20260416-eliza-ipa-v1-1-f4109a8e43c4@pm.me/
[mrlund: drop the permanent SM8550-fallback claim; Eliza is made
standalone together with SM8750 in a later commit]
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Some IPA firmware versions on IPA 5.5 require ipa_filter_stats_info in
the init_modem_driver QMI request. For example on Eliza, if this is not
passed then shortly after IPA init the system will halt and reboot
shortly after.

Downstream this is marked as optional but does not seem to be the case
on newer IPA firmware versions.

Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
Link: https://lore.kernel.org/linux-arm-msm/20260416-eliza-ipa-v1-3-f4109a8e43c4@pm.me/
[mrlund: keep shared v4.5–v5.5 fnr_idx_cnt at 0 so older platforms keep
the previous QMI layout; Eliza's non-zero count is in its private data]
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
Add the configuration data required for Eliza, which uses IPA v5.5.
Eliza differs from the shared v5.5 tables in three ways: a larger Q6
FnR counter count (and the memory layout that follows), and private
QSB and GSI endpoint tables.

Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
Link: https://lore.kernel.org/linux-arm-msm/20260416-eliza-ipa-v1-4-f4109a8e43c4@pm.me/
[mrlund: keep private QSB and endpoint tables here instead of rewriting
the shared v5.5 tables; set fnr_idx_cnt to 68 for Eliza]
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Assisted-by: Grok Bot
SM8750 has IPA v5.5.2, like Eliza. The OnePlus SM8750 downstream
driver uses the same 68-counter Q6 FnR memory layout and the same
endpoint map as the Eliza data, so reuse ipa_data_v5_5_eliza.

List both qcom,sm8750-ipa and qcom,eliza-ipa as standalone
compatibles with no qcom,sm8550-ipa fallback. Move Eliza out of the
SM8550 fallback list while adding SM8750.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Add the IPA v5.5 node, based on SM8650. The values come from the
stock SM8750 device tree and the downstream sun-ipa.dtsi:

- IPA interrupt is SPI 655 (SM8650: 654)
- the config path ends at SLAVE_IPA_CFG on cnoc_main
- the modem tables live at IMEM 0x14683000, size 0x2000

Add the IMEM node that holds the modem tables.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
The GSI firmware comes from the modem partition (ipa_fws, PAS id 15).

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
Turn on the CDSP and modem remoteprocs now that firmware names and
carve-outs are wired. Keep the risk comment: probing the modem hands
its memory to the modem VM.

What the driver does for these board compatibles (see
drivers/remoteproc/qcom_q6v5_pas.c):

- CDSP falls back to sm8650_cdsp_resource (qcom,sm8650-cdsp-pas in the
  board fallback list). That desc has auto_boot = true, so the CDSP
  firmware is expected to start at each boot without userspace.
- MPSS uses sm8750_mpss_resource: auto_boot = false, but
  region_assign_idx/count/vmid hand the carve-out to the modem VM
  (QCOM_SCM_VMID_MSS_MSA) at probe. That assign happens whether or not
  the owner has enabled the modem in userspace.

On a RAM-only boot of this series (7.3.0-rc6-g9957f46a70c4, 2026-10-30),
after loading this kernel's qcom_q6v5_pas from a tmpfs modules overlay
(remoteprocs were NONE before that modprobe):

  /sys/class/remoteproc/remoteproc0 name=modem state=offline
  /sys/class/remoteproc/remoteproc1 name=adsp state=running
  /sys/class/remoteproc/remoteproc2 name=cdsp state=offline

CDSP auto-boot ran and failed with -2 (qcom/sm8750/OnePlus/cdsp.mbn not
installed). MPSS stayed offline; the carve-out assign at probe is from
the driver, not observed. So in this tree only ADSP actually runs.

Assisted-by: Grok Bot
Signed-off-by: Martin Lund <mrlund@hotmail.com>
@mrlund
mrlund force-pushed the dodge/pr-kernel-v1 branch from 4d42223 to 6cc4b65 Compare November 1, 2026 14:38
@mrlund

mrlund commented Nov 1, 2026

Copy link
Copy Markdown
Author

Thanks a lot for this, and great to hear you've got a 13 too. I went through every item, and most of it holds up.

Fixed in this revision:

  • sm8750.config is now a small additive fragment. The GPU clocks stay on, and the amp, panel and touch are enabled.
  • The panel now selects the DSC helper and manages its own vddio/vci/vdd supplies, with proper error paths.
  • Touch: firmware-supplied indices and counts are clamped, and the CRC lock and bounds and the divide-by-zero are fixed.
  • The MHI poll is opt-in per controller and only set for WCN7860. FP no longer counts as mission mode.
  • IPA: the shared v5.5 tables are back as they were. SM8750/Eliza get their own tables and the filter-stats field, and they no longer fall back to sm8550-ipa. The interrupt fix is folded into the commit that adds the node.
  • ath12k: both leaks are fixed, and the cal-done and early-coredump changes only apply to WCN7860.
  • The sound card format moved to sm8750's codec_dai_fmt, the touch IRQ flags are fixed, the BT baud path wakes the TX, and A830 saves GLOBAL(47).

Pushing back or leaving for now:

  • DSI RGB888 override: gating it to non-widebus would break the 13, since its panel is DSC with widebus and RGB101010. The commit message now explains that.
  • Porting touch into synaptics_tcm and the amp into aw88081 is a scope call for Derek. Happy to do both as follow-ups. Until then the touch probe/remove/workqueue/PM/binding cleanup and the amp regmap checks stay open. Better done with the port than twice.
  • The QTB read stays for now; without it the display doesn't come back after warm boot. I'll move it behind a proper TBU description as a follow-up. The fuel-gauge compatible and the orientation GPIO need hardware confirmation.
  • ath12k: the REG_STATUS_DROP change isn't called out in its commit message yet, and the early coredump doesn't handle an already-pending dump. Both are on my list.

I RAM-booted this tip on the 13 against Derek's latest main with the lean config. Display, GPU, touch, Wi-Fi, BT, audio (speaker) and battery all work. SEA stays at 0, and the only WARNs are four clk ones. Looking forward to your PRs.

@derekross

Copy link
Copy Markdown
Owner

Thank you, @mrlund, for working through @HundredBillion's review so quickly, and thank you, @HundredBillion, for such a thorough read. The rework fixes real bugs: the touch parser's unchecked indices and the lock it left held, the panel's missing supplies, the shared IPA v5.5 tables, the ungated MHI poll, and the config fragment that turned the GPU clocks off.

I promised you a decision on scope, and here it is.

What linux-omarchy-mobile carries. Its omamobile branch is meant to hold curated, upstream-ready commits on top of the upstream tag, and I rebase all of it at every base move. I can't test a single line of this series myself, and most of it is Qualcomm SoC enablement that upstream is actively working on: the Adreno 830 catalog, gpucc, IPA for SM8750/Eliza, the WCN7860 Wi-Fi and Bluetooth paths, the MHI and PCIe changes. On top of that are two vendor-derived drivers for chip families that already have drivers in the tree (the TCM2 touchscreen next to synaptics_tcm.c, the AW882308 amplifier next to aw88081), a display TBU read at a hard-coded address, and five commits whose authors haven't signed off. Carrying all of that in omamobile would mean rebasing 9,000 lines I can't check against upstream's own SM8750 work, every release.

So I'd like to handle the OnePlus 13 the way the Pixel 4 XL is handled: the SoC stack stays in your fork (mrlund/linux-omarchy-mobile, on our omamobile base, so it keeps our tools and conventions), and the device's README, BRINGUP and matrix row link to the exact branch or tag the phone runs. What comes into this tree is the OnePlus 13 itself (its bindings and board DTS, and drivers for its own parts once they're in the shape upstream would take), as each piece's SoC dependencies reach upstream or linux-next. A board PR that builds on our base without the SoC stack is very welcome at any time.

That means I'll close this PR rather than merge it. Nothing here is wasted: the fork keeps all of it, and the review history stays linked from the device notes.

For the record, here's where this head stands, so the fork starts from an accurate list:

  • Sign-offs. Five commits still have no Signed-off-by from their authors: 0ddbf2873a14 (Teguh Sobirin), and 9613d6de1c8c, 4982cffefc12, 0bb1e3421818, e52be4397171 (index986). If any of these come here later, the route I described on the 31st holds: you as the author, the original author named in the body with a link to the exact commit, and the original copyright kept in the files.
  • Still open from the review, by your own list: the touch driver's probe, remove, workqueue, PM and binding cleanup (or the port into synaptics_tcm.c), the amplifier's regmap checks (or the port into aw88081), the TBU read moving behind a device-tree description, ath12k's early coredump with a dump already pending, and the REG_STATUS_DROP change in its commit message.
  • Shared code that's still ungated: the dsi_host.c RGB888 override applies to any DSC panel with RGB101010 (your message now explains why it can't be limited to non-widebus, which is fair), and the new MI2S case in sc8280xp_snd_init() returns early for every board that uses the machine driver, which also skips the WCD jack setup on those links. If either goes upstream, it will need a per-SoC or per-board condition.
  • The Pixels: I checked again on this head, and nothing changes for them. The only shared driver a Pixel uses is btqca/hci_qca (the Pixel 7a's WCN6855): QCA_WCN7860 is appended at the end of the enum, and the new baud-rate sequence runs only for that type.

Our policy gate on this head agrees: subjects and the identifier checks pass, checkpatch reports no errors, and only the five sign-offs fail. I didn't rebuild the series this time; CI for this push is waiting for my approval, and I'll approve it so you have the build and dtbs_check results for the fork.

Thank you for your patience while I made up my mind, and for how openly you've documented every source. I'm glad the OnePlus 13 is part of the project, and I'm looking forward to the board PR.

@derekross derekross closed this Nov 1, 2026
@mrlund

mrlund commented Nov 2, 2026

Copy link
Copy Markdown
Author

Thanks Derek. The fork model makes sense, and I'll keep the SoC stack on mrlund/linux-omarchy-mobile the way coral does.

I've tagged the #115 tip as dodge-v3-20261101 (6cc4b65df980) and will point NOTES / BRINGUP / DEVICES at that tag in a follow-up PR on omarchy-mobile.

Separately, dodge/jack-fix-mi2s on top of the tag fixes the MI2S early-return in sc8280xp_snd_init() so WCD jack setup still runs for boards that set .wcd_jack. RAM-boot tested on the OnePlus 13 (speaker audio still works); the jack path itself only runs on boards with a WCD jack, which I can't test here. I'll fold it into the next fork tag.

Looking forward to board pieces landing as their SoC deps reach upstream.

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.

6 participants