From e919873ea02c86d14c499632a360e6ec3fe3cf61 Mon Sep 17 00:00:00 2001 From: Developerr86 <138863457+Developerr86@users.noreply.github.com> Date: Fri, 4 Dec 2026 23:02:33 +0530 Subject: [PATCH] devices/j2a: Record the 32 GB unit's progress since the import What changed on the 32 GB J2A between the import (orchard#468, linux#103) and 2026-12-04, measured with Omarchy A booting from the iPad's flash: a 45 s boot, the L2 cache on, the native resolution with a NEON copy, the app drawer, shell start and Firefox, buttons, Wi-Fi joining and rotation. The README gains "Unmerged code" (linux#162, linux#163, the fork's remaining kernel and image changes) and "Open work" (GPU first, then sound, camera, Bluetooth, writing the flash, power). device.toml keeps its states, since the code behind the new evidence is not in orchard's kernel yet; the notes record what was seen and which pull request it needs. Pages regenerated. Assisted-by: LLM --- devices/j2a/README.md | 70 +++++++++++++++++++++++++++++++++++++++++ devices/j2a/device.toml | 10 +++--- docs/devices/j2a.md | 10 +++--- 3 files changed, 80 insertions(+), 10 deletions(-) diff --git a/devices/j2a/README.md b/devices/j2a/README.md index d26b82df..0d30d607 100644 --- a/devices/j2a/README.md +++ b/devices/j2a/README.md @@ -76,3 +76,73 @@ stalls EP0 on the composite `g_cdc` gadget): `__data = 0x16094`, `__const = 0x730`), `apple-sgx` powered on all 4 cores (`SGX543MP4 rev 1.2.2`, `MASTER_CORE_ID = 0x01194401`), booted the microkernel (`host[0] 0x00000001`), and passed `bench 20` (20/20 2D fills in 6822 µs, 341 µs/fill, zero `BIF_FAULT`). + +## Since the import (2026-12-03 → 12-04, 32 GB unit, Omarchy A from flash) + +Measured by [@Developerr86](https://github.com/Developerr86) on the same 32 GB unit, booting Omarchy A from its own +flash (root written from iOS), on [Developerr86/linux `j2a-bringup`](https://github.com/Developerr86/linux/commits/j2a-bringup) +and the image script in [his fork](https://github.com/Developerr86/orchard/tree/j2a-bringup/devices/j2a/bringup/kit/omarchy-build). +His full write-up is section 11 of `docs/bring-up/j2a.md` there; the dated notes are `devices/j2a/bringup/NOTES.md`. + +| | At the import | 2026-12-04 | +|---|---|---| +| Boot to the desktop | 1 min 10 s | **45-47 s** | +| L2 cache (1 MiB PL310) | off: iBoot leaves it off | **on**, latency <4 4 2>, prefetch ([linux#162](https://github.com/OrchardLinux/linux/pull/162)) | +| Memory latency / memcpy at 256 KiB | 81-164 ns / ~340 MB/s | **27.6 ns / 1522 MB/s** | +| Resolution | 1536×2048, or half size to stay usable | **native 1536×2048**, scale 2 | +| Full-screen turned copy | 73.6 ms | **28.6 ms** (NEON, [linux#163](https://github.com/OrchardLinux/linux/pull/163)) | +| App drawer open | 9-10 s | **0.35-0.74 s** of shell CPU, first frame 0.6-1.0 s | +| Shell ready after login | 20-29 s | **5.7 s** (QML compiled with the image) | +| Firefox start (CPU in 75 s) | 70-76 s, 11 processes | **53-56 s**, 7 processes; 38-44 s once cached | +| Buttons | none | Home, Power, volume, side switch | +| Wi-Fi | networks listed | **joins WPA2 from Settings, reaches the internet** | +| Rotation | portrait only | **all four orientations** from the accelerometer, side switch as rotation lock | + +How (each tried live first, then built into the image): +- **Kernel:** the L2 cache on at latencies proven on this SoC (the ADT's `<2 2 1>` corrupts reads); a NEON 4×4 + transpose for simpledrm's turned copy; simpledrm also offering the scanout's own shape plus a `flip`, so + rotation is a mode change instead of pixman turning every frame (about 3× the cost per frame on the A5X); the + buttons from the ADT's `/buttons`. +- **Omarchy A (image script):** + - boot: pacman's keyring rebuild masked (4 min of CPU every boot on the read-only root) and the + ConditionNeedsUpdate stamps; + - process storms removed: a battery script every second, menu guards in login shells, picker pings, Python + brightness queries; + - the app drawer laid out from the screen (it re-laid itself out 3-4 times an open from its unmapped window), opaque + and complete in its first frame; + - the shell's QML compiled with the image and served through Qt's unit-cache hook (Quickshell's `qs:@` URLs bypass + Qt's disk cache); + - Firefox defaults for two A9 cores; + - the rotation daemon driving simpledrm's modes, with touch turned by a libinput matrix; + - the lock screen keeping one square wallpaper decode across turns (5.5 s of CPU per turn before); + - Home as on iOS, Power going dark without a PIN, the Wi-Fi password prompt keeping focus, and Settings' Wi-Fi page + no longer rebuilding every row on each scan (Settings 40-80 s → 2 s). + +## Unmerged code + +- **Kernel:** [linux#162](https://github.com/OrchardLinux/linux/pull/162) (L2) and + [linux#163](https://github.com/OrchardLinux/linux/pull/163) (simpledrm NEON copy, landscape and flip). The buttons + ([59cc455a](https://github.com/Developerr86/linux/commit/59cc455a1)) are the same pins as + [linux#152](https://github.com/OrchardLinux/linux/pull/152). Still only in his fork: debugfs counters for the + copy, touch and the SFTL ([ccf9eeb2](https://github.com/Developerr86/linux/commit/ccf9eeb2b), + [75f5d946](https://github.com/Developerr86/linux/commit/75f5d9468), + [96aa8bee](https://github.com/Developerr86/linux/commit/96aa8bee4)), and an `apple-sgx` upright presentation that + gave no felt gain ([899ef643](https://github.com/Developerr86/linux/commit/899ef643d)). +- **Omarchy A:** the image script's shell, Firefox and rotation changes + ([his fork](https://github.com/Developerr86/orchard/tree/j2a-bringup/devices/j2a/bringup/kit/omarchy-build)), + which belong in omarchy-a. Several are written against the J2A image and need a general form first, for example + the rotation daemon choosing simpledrm modes when they are offered. + +## Open work + +The iPad 3 is usable for light work now. Still to do: +- **GPU:** the most important. The kernel side runs (power, Apple's microkernel, 2D fills, a render node), but there + is no userspace driver for the SGX543 (Series5XT): GLES2 through Mesa has to be written. It would speed up the + shell (Qt Quick) and video, not Firefox (WebRender needs GLES 3). +- **Sound:** the CS42L63 plays and records (above); the desktop has no audio session on this image yet. +- **Camera:** [linux#140](https://github.com/OrchardLinux/linux/pull/140) and a firmware recipe for the H4ISP. +- **Bluetooth:** the BCM4330B1 patchram scans BLE (above); it needs the recipe and the image path. +- **Writing the flash:** the NAND driver and SFTL only read; the root is written from iOS and runs read-only under a + RAM overlay, so nothing persists across boots. A writer for 8 KiB pages is not started. +- **Performance and battery:** Firefox is still slow (software WebRender, about 40 s of CPU to start); GPU idle power, + the SoC's die sensor, the USB charge grant, suspend. diff --git a/devices/j2a/device.toml b/devices/j2a/device.toml index 0bef075c..4cb2f8c1 100644 --- a/devices/j2a/device.toml +++ b/devices/j2a/device.toml @@ -40,19 +40,19 @@ status = "supported" # GCC 11.4 and the J1 kit's config plus the J2A tree, but orchard's own clang build # has not booted on a J2A yet. [features] -display = "working" # 2026-12-03: iBoot's scanout, portrait (simpledrm with rotation = <90>; earlier simplefb with fbcon rotated). -screen_off = "missing" +display = "working" # 2026-12-03: iBoot's scanout, portrait (simpledrm with rotation = <90>; earlier simplefb with fbcon rotated). 2026-12-04 (32 GB): native 1536x2048 upright; landscape and upside down through simpledrm's second mode and flip need linux#163. +screen_off = "missing" # 2026-12-04 (32 GB): Power darkens the panel (omarchy-powerd, backlight off) with the buttons from Developerr86/linux 59cc455a1 (the pins of linux#152). backlight = "working" # 2026-12-04: PMU WLED cycled 1658 -> 400 -> 200 -> 1658 / 2047 on 64 GB unit. gpu_desktop = "missing" # 2026-12-04: SGX543MP4 rev 1.2.2 (4 cores) + 12H321 sgx543.fw microkernel booted and passed 20/20 2D fills (341 us each); Mesa desktop not yet run. touch = "working" # 2026-12-03: drove the Omarchy A desktop; touchscreen-inverted-y, lost-frame lift (apple-z2). -buttons = "missing" -accelerometer = "missing" # Needs linux#137 (not in orchard's kernel yet). 2026-12-04: ST LIS331DLH (i2c2 @ 0x19) read live values on a 64 GB unit with that change. +buttons = "missing" # 2026-12-03 (32 GB): Home, Hold, volume up/down and the side switch all reported through gpio-keys on Developerr86/linux 59cc455a1, the same pins as linux#152. +accelerometer = "missing" # Needs linux#137 (not in orchard's kernel yet). 2026-12-04: ST LIS331DLH (i2c2 @ 0x19) read live values on a 64 GB unit with that change. 2026-12-04 (32 GB): the same node drove Omarchy A's auto-rotation in all four orientations through iio-sensor-proxy. gyroscope = "missing" # Needs linux#137 (not in orchard's kernel yet). 2026-12-04: ST L3G4200D (i2c2 @ 0x68) read live values on a 64 GB unit with that change. light_sensor = "missing" # Needs linux#137 (not in orchard's kernel yet). 2026-12-04: TAOS TSL2581 (i2c2 @ 0x39) read live values on a 64 GB unit with that change. touch_id = "none" storage_read = "working" # 2026-12-03: Omarchy A ran from LwVM partition 3 through the read-only NAND driver and SFTL on 8 KiB pages (32 GB PPN 1.6); 64 GB PPN 1.3 geometry also probed read-only. storage_write = "missing" # the NAND driver is read-only: no program or erase path; the root is written from iOS. -wifi = "untested" # The firmware recipe does not install brcmfmac4330.bin yet; firmware was installed by hand for this test. 2026-12-04: BCM4330 wlan0 associated via WPA2-PSK (CCMP, -48 dBm, 65 MBit/s), obtained DHCP lease, and passed 4/4 gateway + internet ping (0% loss). +wifi = "untested" # The firmware recipe does not install brcmfmac4330.bin yet; firmware was installed by hand for this test. 2026-12-04: BCM4330 wlan0 associated via WPA2-PSK (CCMP, -48 dBm, 65 MBit/s), obtained DHCP lease, and passed 4/4 gateway + internet ping (0% loss). 2026-12-03 (32 GB): joined a WPA2 network from Omarchy A's Settings and reached the internet. bluetooth_input = "missing" # 2026-12-04: BLE scans worked with BCM4330B1 patchram carved from iOS by hand; the firmware recipe does not install it yet. bluetooth_audio = "missing" cellular = "missing" # baseband (n90) present in the ADT, left unclaimed. diff --git a/docs/devices/j2a.md b/docs/devices/j2a.md index 9aa6754c..9789c615 100644 --- a/docs/devices/j2a.md +++ b/docs/devices/j2a.md @@ -13,19 +13,19 @@ Generated by `tools/catalog/generate matrix` from `devices/j2a/device.toml`; do Driver: this board's device tree has not been read yet (`tools/catalog/generate kernel`). -- ✅ **Display**: 2026-12-03: iBoot's scanout, portrait (simpledrm with rotation = <90>; earlier simplefb with fbcon rotated). -- ❌ **Screen on/off** +- ✅ **Display**: 2026-12-03: iBoot's scanout, portrait (simpledrm with rotation = <90>; earlier simplefb with fbcon rotated). 2026-12-04 (32 GB): native 1536x2048 upright; landscape and upside down through simpledrm's second mode and flip need linux#163. +- ❌ **Screen on/off**: 2026-12-04 (32 GB): Power darkens the panel (omarchy-powerd, backlight off) with the buttons from Developerr86/linux 59cc455a1 (the pins of linux#152). - ✅ **Backlight**: 2026-12-04: PMU WLED cycled 1658 -> 400 -> 200 -> 1658 / 2047 on 64 GB unit. - ❌ **GPU desktop**: 2026-12-04: SGX543MP4 rev 1.2.2 (4 cores) + 12H321 sgx543.fw microkernel booted and passed 20/20 2D fills (341 us each); Mesa desktop not yet run. - ✅ **Touchscreen**: 2026-12-03: drove the Omarchy A desktop; touchscreen-inverted-y, lost-frame lift (apple-z2). -- ❌ **Buttons** -- ❌ **Accelerometer**: Needs linux#137 (not in orchard's kernel yet). 2026-12-04: ST LIS331DLH (i2c2 @ 0x19) read live values on a 64 GB unit with that change. +- ❌ **Buttons**: 2026-12-03 (32 GB): Home, Hold, volume up/down and the side switch all reported through gpio-keys on Developerr86/linux 59cc455a1, the same pins as linux#152. +- ❌ **Accelerometer**: Needs linux#137 (not in orchard's kernel yet). 2026-12-04: ST LIS331DLH (i2c2 @ 0x19) read live values on a 64 GB unit with that change. 2026-12-04 (32 GB): the same node drove Omarchy A's auto-rotation in all four orientations through iio-sensor-proxy. - ❌ **Gyroscope**: Needs linux#137 (not in orchard's kernel yet). 2026-12-04: ST L3G4200D (i2c2 @ 0x68) read live values on a 64 GB unit with that change. - ❌ **Light sensor**: Needs linux#137 (not in orchard's kernel yet). 2026-12-04: TAOS TSL2581 (i2c2 @ 0x39) read live values on a 64 GB unit with that change. - – **Touch ID** - ✅ **Internal storage read**: 2026-12-03: Omarchy A ran from LwVM partition 3 through the read-only NAND driver and SFTL on 8 KiB pages (32 GB PPN 1.6); 64 GB PPN 1.3 geometry also probed read-only. - ❌ **Internal storage write**: the NAND driver is read-only: no program or erase path; the root is written from iOS. -- 🤔 **Wi-Fi**: The firmware recipe does not install brcmfmac4330.bin yet; firmware was installed by hand for this test. 2026-12-04: BCM4330 wlan0 associated via WPA2-PSK (CCMP, -48 dBm, 65 MBit/s), obtained DHCP lease, and passed 4/4 gateway + internet ping (0% loss). +- 🤔 **Wi-Fi**: The firmware recipe does not install brcmfmac4330.bin yet; firmware was installed by hand for this test. 2026-12-04: BCM4330 wlan0 associated via WPA2-PSK (CCMP, -48 dBm, 65 MBit/s), obtained DHCP lease, and passed 4/4 gateway + internet ping (0% loss). 2026-12-03 (32 GB): joined a WPA2 network from Omarchy A's Settings and reached the internet. - ❌ **Bluetooth input devices**: 2026-12-04: BLE scans worked with BCM4330B1 patchram carved from iOS by hand; the firmware recipe does not install it yet. - ❌ **Bluetooth audio** - ❌ **Cellular**: baseband (n90) present in the ADT, left unclaimed.