motorola-rtwo: strip .dts to the minimum for early-panic bisection

Full .dts + fixed 7.2 kernel still resets in <2s with no output. Cut the
.dts to SoC + regulators + debug UART + HS-peripheral USB only - no
reserved-memory, no simple-framebuffer, no touch/SD/UFS/keys. If this
reaches the initramfs the fault was in a removed node; if it also resets
the problem is the kernel/config/boot image.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QF5HebjUsRaxbW4cBX6HJP
This commit is contained in:
2026-09-08 20:31:22 -03:00
co-authored by Claude Sonnet 5
parent cf417990f5
commit 2a8588f9e2
4 changed files with 13 additions and 156 deletions
+2 -2
View File
@@ -2,7 +2,7 @@
maintainer="snlavaise <snlavaise@gmail.com>"
pkgname=device-motorola-rtwo
pkgver=1
pkgrel=3
pkgrel=4
pkgdesc="Motorola Moto Edge 40 Pro"
url="https://postmarketos.org"
arch="aarch64"
@@ -36,6 +36,6 @@ package() {
}
sha512sums="
785cb3c8c9e56d78c63b6e0cce5c4eee429160220358cf76379dfde2badecedbb4d5d88472ded57852fc5dd8fa0dd827f6f4f9d88fd26fba956e2dd945a1260a deviceinfo
beca2835f2ea99426eed39607259aab0b4ef119bd9855a961476b6fbca6e55a4d7985407d46067df760919814b8b97dd1f6a350c1f6f1a7ebdc0fb839e6cc0e7 deviceinfo
c572e21cb0624b554a22a218b0c4faab9b6412654bed6bfef530f3068d076b21c573bd7f4b3ca65f510f8756f636a861191cce925ef49587db7d68d09558826c modules-initfs
"
@@ -23,7 +23,7 @@ deviceinfo_getty="ttyMSM0;115200"
# splash buffer, so there should be an early console on the panel. If the
# screen stays black, set this to "true" (and fix the framebuffer@ node).
# There is no DRM/mdss yet, so no mode setting / backlight control.
deviceinfo_no_framebuffer="false"
deviceinfo_no_framebuffer="true"
# Split the initramfs: a small base archive (fits in init_boot, 8 MB) plus a
# separate initramfs-extra loaded from the rootfs later.
@@ -5,7 +5,7 @@ maintainer="snlavaise <snlavaise@gmail.com>"
_flavor="postmarketos-qcom-sm8550"
pkgname=linux-$_flavor
pkgver=7.2
pkgrel=0
pkgrel=1
pkgdesc="Mainline kernel for Qualcomm SM8550 (Snapdragon 8 Gen 2) + Motorola rtwo"
arch="aarch64"
_carch="arm64"
@@ -99,5 +99,5 @@ sha512sums="
52d5aa7f94f6aa6141debf4ceb4fc7a2e75505a7cd38b8854e501be83c2b57863020f463f2fdb2fc93667e6cfe13274d077e5207a611e4797bd9404ee0e64c58 linux-postmarketos-qcom-sm8550-7.2.tar.gz
f9ae52489f6b9e6fef64952943cd09732a5bef90a0e8765db03c256483028368687d6d5a1d80dd813a513e7e80d91f8b47f49b91cff67266b76f1d6275a7fea0 config-motorola-rtwo.aarch64
ca36b981736b94d93120bea60d84614a5f943b0577a87ce0c650a7c065dc8b8b889eeee766b8fb941e15af4db5d426583d2d85e3e243faf89aa9cac472f78388 rtwo.config
d3b10b54539c85eab2f200544710a63771518a1fb6aa9fed0d453a69f85de03c36d6da392e0671d6bbe0b79443169042779897b1c00c771a89a19d1540473693 sm8550-motorola-rtwo.dts
0781703a9d4da45854c1472802753dca9baf3a44541f4cee19ee95d34b857b8fce329fbb3fa0871f19f19b86877ba7299361218b41e000fe82bd9219374b69bd sm8550-motorola-rtwo.dts
"
@@ -2,34 +2,17 @@
/*
* Motorola Moto Edge 40 Pro (codename "rtwo"), SM8550 / Snapdragon 8 Gen 2
*
* WIP mainline bring-up device tree for postmarketOS.
* MINIMAL bring-up device tree: SoC + PMIC regulators + debug UART + USB
* (high-speed peripheral). No reserved-memory, no framebuffer, no touch,
* no SD/UFS, no keys - everything that could fault early is stripped.
*
* Hardware facts gathered from the stock LineageOS 23.2 sources and the live
* DTB dumped from the device:
* - board-id / model "rtwo", XT2301-x, PVT, UFS (KIOXIA 256 GB) at 1d84000
* - debug UART: GENI SE7 @ac0000/a9c000 -> mainline &uart7 (qupv3_id_0)
* - touchscreen: Goodix GT9916 on SPI SE4 (spi@a90000 -> &spi4),
* reset TLMM24, irq TLMM25, avdd = pm8550 L9B, iovdd = pm8550 L10B
* - keys: volume-up on pm8550 GPIO6, volume-down = PMIC resin, power = pwrkey
* - SD card: sdhc_2, CD on pm8550 GPIO12, vmmc L9B, vqmmc L8B
* - panel: CSOT/Tianma Novatek NT37705 / NT37701A, 1080x2400 DSC cmd-mode,
* reset TLMM133, vdd L11B (1.23-1.28 V), vci L13B (3.0 V), vddio 1.8 V
* - cont_splash framebuffer at 0xb8000000
* - haptics: pm8550b (SoundWire), speakers: 2x WSA883x, WiFi/BT: WCN7850 "kiwi"
*
* Still TODO before this is a real port: DSI panel driver + &mdss, GPU zap
* shader, modem/remoteprocs, WiFi/BT (PCIe), charger (pmic-glink battmgr),
* NFC, fingerprint, camera (external wl2868c LDO on the i2c hub).
*
* Immediate goal: initramfs debug shell over USB (+ UART if wired), pstore
* console via ramoops, and ideally the bootloader framebuffer.
* If this reaches the initramfs (USB net / telnet works), the problem was
* in the removed nodes; add them back one at a time. If this also resets
* in <2s, the problem is the kernel/config/boot image, not the .dts.
*/
/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/regulator/qcom,rpmh-regulator.h>
#include "sm8550.dtsi"
@@ -50,63 +33,7 @@
};
chosen {
#address-cells = <2>;
#size-cells = <2>;
ranges;
stdout-path = "serial0:115200n8";
/*
* Bootloader continuous-splash framebuffer, reused as an early
* console (CONFIG_FB_SIMPLE). Needs no panel driver.
*
* Panel is 1080x2400 (NT37705). Format/base are a best guess
* from the stock cont_splash / disp_rdump regions. If the screen
* is garbled: try format "x8r8g8b8" -> "r5g6b5" (and stride
* 1080*2) -> drop the node. If it is offset/torn, the stride is
* wrong. If it shows briefly then freezes, the display clocks
* got gated - add "clk_ignore_unused" to the kernel cmdline.
*/
framebuffer0: framebuffer@b8000000 {
compatible = "simple-framebuffer";
reg = <0x0 0xb8000000 0x0 (1080 * 2400 * 4)>;
width = <1080>;
height = <2400>;
stride = <(1080 * 4)>;
format = "x8r8g8b8";
};
};
gpio-keys {
compatible = "gpio-keys";
pinctrl-0 = <&vol_up_n>;
pinctrl-names = "default";
key-volume-up {
label = "Volume Up";
gpios = <&pm8550_gpios 6 GPIO_ACTIVE_LOW>;
linux,code = <KEY_VOLUMEUP>;
debounce-interval = <15>;
linux,can-disable;
wakeup-source;
};
};
reserved-memory {
/* Bootloader crash/console log ring, kept across reboots */
ramoops@ae000000 {
compatible = "ramoops";
reg = <0x0 0xae000000 0x0 0x60000>;
console-size = <0x40000>;
record-size = <0x20000>;
no-map;
};
cont_splash_mem: cont-splash@b8000000 {
reg = <0x0 0xb8000000 0x0 0x2b00000>;
no-map;
};
};
vph_pwr: vph-pwr-regulator {
@@ -458,65 +385,16 @@
};
};
&pm8550_gpios {
vol_up_n: volume-up-n-state {
pins = "gpio6";
function = "normal";
bias-pull-up;
input-enable;
power-source = <1>;
};
};
&pm8550b_eusb2_repeater {
vdd18-supply = <&vreg_l15b_1p8>;
vdd3-supply = <&vreg_l5b_3p1>;
};
&pon_pwrkey {
status = "okay";
};
&pon_resin {
linux,code = <KEY_VOLUMEDOWN>;
status = "okay";
};
/* GENI QUP0 wrapper: hosts the debug UART (SE7) and the touch SPI (SE4) */
/* GENI QUP0 wrapper: hosts the debug UART (SE7) */
&qupv3_id_0 {
status = "okay";
};
&spi4 {
status = "okay";
touchscreen@0 {
compatible = "goodix,gt9916";
reg = <0>;
spi-max-frequency = <15000000>;
interrupt-parent = <&tlmm>;
interrupts = <25 IRQ_TYPE_LEVEL_LOW>;
reset-gpios = <&tlmm 24 GPIO_ACTIVE_LOW>;
avdd-supply = <&vreg_l9b_2p9>;
vddio-supply = <&vreg_l10b_1p8>;
touchscreen-size-x = <1080>;
touchscreen-size-y = <2400>;
};
};
&sdhc_2 {
cd-gpios = <&pm8550_gpios 12 GPIO_ACTIVE_LOW>;
vmmc-supply = <&vreg_l9b_2p9>;
vqmmc-supply = <&vreg_l8b_1p8>;
bus-width = <4>;
no-sdio;
no-mmc;
status = "okay";
};
&sleep_clk {
clock-frequency = <32000>;
};
@@ -525,29 +403,8 @@
status = "okay";
};
&ufs_mem_hc {
reset-gpios = <&tlmm 210 GPIO_ACTIVE_LOW>;
vcc-supply = <&vreg_l17b_2p5>;
vcc-max-microamp = <1300000>;
vccq-supply = <&vreg_l1g_1p2>;
vccq-max-microamp = <1200000>;
vdd-hba-supply = <&vreg_l3g_1p2>;
status = "okay";
};
&ufs_mem_phy {
vdda-phy-supply = <&vreg_l1d_0p88>;
vdda-pll-supply = <&vreg_l3e_1p2>;
status = "okay";
};
&usb_1 {
/*
* High-speed peripheral only for bring-up (USB networking in the
* initramfs). Drop the SuperSpeed PHY + the type-C role switch so dwc3
* comes up without pmic-glink / a connector. Restore usb-role-switch,
* the usb3-phy and &usb_dp_qmpphy once type-C is described.
*/
/* high-speed peripheral only, no type-C / SuperSpeed */
dr_mode = "peripheral";
maximum-speed = "high-speed";
/delete-property/ usb-role-switch;