diff --git a/AGENTS.md b/AGENTS.md index 741c323..0ffef24 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -57,7 +57,7 @@ All cross-compilation scripts run inside rootless Docker (`alpine:3.24` `armv7` - **No emojis**: never use emojis in source code, UI strings, logs, or commit messages (use Nerd Font PUA codepoints defined in `neoui.h` / `phone_data.h` / `dmenu.c` for UI icons). - **Unified theming**: never hardcode UI colors or font sizes in `dwm`, `dmenu`, `st`, or any DWM plugin. Read colors and proportional font sizes from `PluginTheme` (`src/neoui/neoui.h` / `src/dwm-plugins/theme.h`) / `.Xresources` (`theme.*`), and handle `RELOAD_THEME` on the plugin FIFO. - **Zero-lag plugin model**: phone UI apps must run as preloaded resident daemons (`--preload`) guarded by `/tmp/dwm_plugin_.lock`, sleeping at 0% CPU on `poll()` over `ConnectionNumber(dpy)` and `/tmp/dwm_plugin_.fifo`, and rendering into an offscreen `Pixmap` (`240x296` at `X=0, Y=24`) copied with `XCopyArea` to prevent flicker. -- **Multiline text rendering**: on the target Pango/Xft stack `pango_xft_render_layout()` only paints the first line of a long multiline layout, so wrapped bodies must be drawn line by line with `pango_xft_render_layout_line()` using a scroll offset and a bounded visible line count (see `sms_plugin.cpp`, `dialer_plugin.cpp`, `modem_plugin.cpp`, and `neoui_draw_text_wrapped()`). Where the widget has a fixed rectangle, clip with `XftDrawSetClipRectangles()` and reset the clip afterwards so the softkey bar still draws; keep measurement and rendering at the same layout width. `scripts/check-rebuild.sh` guards `sms_plugin.cpp`. +- **Multiline text rendering**: on the target Pango/Xft stack `pango_xft_render_layout()` only paints the first line of a long multiline layout, so wrapped bodies must be drawn line by line with `pango_xft_render_layout_line()` using a scroll offset and a bounded visible line count (see `sms_plugin.cpp`, `dialer_plugin.cpp`, `modem_plugin.cpp`, and `neoui_draw_text_wrapped()`). Where the widget has a fixed rectangle, clip with `XftDrawSetClipRectangles()` and reset the clip afterwards so the softkey bar still draws; keep measurement and rendering at the same layout width. Wrapped document views must also map link focus through the same row expansion used for rendering (`buildRenderRows()` / `ensureFocusedLinkVisible()` in `smallweb_plugin.cpp`), so focusing a link scrolls the viewport in both wrap modes. `scripts/check-rebuild.sh` guards `sms_plugin.cpp` and the xkopher focus path. - **SMS text accounting**: never treat `std::string::size()` (UTF-8 bytes) as an SMS character count. Use code-point-aware logic such as `smsTextMetrics()`: GSM-7 septets (160 per part, 153 when concatenated) or UCS-2 UTF-16 units (70 per part, 67 when concatenated). SMS log headers are parsed by `parseSmsHeaderLine()`, which strips `[SIM n]` tags; do not write those tags back into `sms.txt`. - **Documentation**: keep `README.md`, `MANUAL.md`, `SDK.md`, and `CHANGELOG.md` synchronized with any new user-facing features, SDK functions, or keybindings, and do not leave third-party `.md` files inside `src/` or `edl/`. - **Artifact sources**: `prebuilt/` is the single source of truth for compiled artifacts and `scripts/rootfs-packages.txt` for the `armv7` package set. Never edit `overlay/rootfs/` copies of binaries by hand; run `./scripts/sync-prebuilt-overlay.sh` after changing `prebuilt/`. @@ -76,7 +76,7 @@ Sync net time** (`src/sxmo-dmenu/dmenu.c` + `usr/bin/bananarchy-sync-net-time.sh`) forces the same burst manually and notifies the user, and the helper's `sync` mode reports the result. Keep DNS resolution outside the helper's `flock` so a long boot retry cannot swallow -network-up events, and keep `var/lib/chrony` owned by the `chrony` user. Deep standby is `bananarchy-suspend.sh` / `bananarchy-deep-standby.sh` / `sxmo_autosuspend.sh` / `sxmo_suspend.sh`, gated by `/etc/bananarchy-no-deep-standby` (shipped present = disabled) and inert because `CONFIG_SUSPEND` is off. A full custom module tree rebuild is deliberately **not** planned: this firmware has no PSCI `SYSTEM_SUSPEND`, so `CONFIG_SUSPEND` would only give s2idle (`freeze`), not `mem` / DDR self-refresh, for <1 mA of saving (see `BATTERY-OPTIMIZATION-ANALYSIS.md` §14). Never force `sxmo.noidle`/`sxmo.nosuspend` from the session scripts and never reintroduce the infinite `sxmo_not_suspendable` wakelock. `/etc/bananarchy/` is root-only. +network-up events, and keep `var/lib/chrony` owned by the `chrony` user. The status bar clock must be refreshed synchronously on unlock (`sxmo_hook_unlock.sh`) and by dmenu's `update_t9_status_indicator()` before `XStoreName()`; `sxmo_hook_statusbar.sh` forces a root-name refresh on `time` / `state_change`. `postmarketos-zram-swap` uses `/usr/bin/zramstart`, not `/etc/conf.d/zram-init`: keep `deviceinfo_zram_swap_algo="lz4"` in every `devices/*/deviceinfo*` file. Keep `vm.compaction_proactiveness=0` in `etc/sysctl.d/99-bananarchy-power.conf` and `etc/local.d/10-power-save.start`; see `BATTERY-OPTIMIZATION-ANALYSIS.md` §17. Deep standby is `bananarchy-suspend.sh` / `bananarchy-deep-standby.sh` / `sxmo_autosuspend.sh` / `sxmo_suspend.sh`, gated by `/etc/bananarchy-no-deep-standby` (shipped present = disabled) and inert because `CONFIG_SUSPEND` is off. A full custom module tree rebuild is deliberately **not** planned: this firmware has no PSCI `SYSTEM_SUSPEND`, so `CONFIG_SUSPEND` would only give s2idle (`freeze`), not `mem` / DDR self-refresh, for <1 mA of saving (see `BATTERY-OPTIMIZATION-ANALYSIS.md` §14 and §17). Never force `sxmo.noidle`/`sxmo.nosuspend` from the session scripts and never reintroduce the infinite `sxmo_not_suspendable` wakelock. `/etc/bananarchy/` is root-only. - **Image residue**: `rebuild-image.sh` strips `/var/cache/apk`, all `apk.log*` files, and unused gettext locale trees before `mke2fs` and aborts the build if any apk cache/log remains; never add an `apk` call after that guard. - **No on-device compiler**: `scripts/rootfs-packages.txt` ships no `gcc`/`g++`/`musl-dev`/`make` and no Janet runtime (`janet`, `janet-dev`, `jpm`); cross-compile native code with `scripts/build-*.sh`. On-device development uses the Yabasic FFI SDK (`neoui.yab` / `neonet.yab`), which requires `yabasic`, `libffi`, `libneoui.so`, and `libcurl.so.4` — never remove those. `scripts/check-rebuild.sh` guards both sides. - **Core tools**: `curl`, `bc`, `ed`, `rlwrap`, `mandoc`, `nano`, `less`, and `frotz` are pinned core tools asserted by `scripts/check-rebuild.sh`. Perl, Lua, optional Tcl extensions, and the `sqlite` CLI are excluded, while `tcl`, `python3`, `bash`, `luajit`, `gawk`, `jq`, `gojq`, and `quickjs` remain as hard runtime dependencies. diff --git a/BATTERY-OPTIMIZATION-ANALYSIS.md b/BATTERY-OPTIMIZATION-ANALYSIS.md index 048542f..5c26e7d 100644 --- a/BATTERY-OPTIMIZATION-ANALYSIS.md +++ b/BATTERY-OPTIMIZATION-ANALYSIS.md @@ -913,3 +913,128 @@ Fixes, without changing the long steady-state poll interval: failure. **Config -> Sync net time** calls it via `bananarchy-sync-net-time.sh` and shows a desktop notification, so the user can always force a sync without a shell. + +--- + +## 17. Battery longevity re-analysis (post-`85c6a7b` live measurement) + +A fresh 60 s idle window was measured on 2026-11-08 at ~10.3 h uptime with the +panel dark (`brightness=0`, `bl_power=4`), Wi-Fi connected to +`OffOurStreets_`, USB RNDIS up, and both SIM applications `ready`. The phone +was charging at `540000` uA with no `current_now` and no coulomb counter, so +all results below are wakeup/IRQ/context-switch counts, not discharge mA. +`capacity` was 44%, `health=Good`, `voltage_now=4054397` uV and +`voltage_ocv` returned `No data available`. + +### 17.1 Measurement caveat: modem registration anomaly + +`msm-modem-uim-selection status` reported +`NAS_REG_STATE=not-registered-searching`, `SEC_NAS_REG_STATE=not-registered`, +`mmcli -L` returned `No modems were found`, and the slot mapping was +`PRIMARY_GW_SLOT=2` / `SECONDARY_GW_SLOT=1` (swapped relative to the earlier +verified `1` / `2` state). `AT+COPS?` returned `+COPS: 0` with no operator. +This is a separate functional issue; no PIN verification was attempted. A +searching modem can draw more RF current than a registered idle modem, so the +radio-related conclusions below are conservative and need a battery-powered +A/B run once registration is restored. + +### 17.2 Baseline: the application processor is already near its floor + +60 s, screen off, Wi-Fi up, both SIM applications ready: + +| Source | Rate | +| --- | --- | +| `arch_timer` | 15.01/s | +| `arch_mem_timer` | 11.64/s | +| `mmc0` | 0.56/s | +| `smd-edge` | 0.52/s | +| `wcn36xx_rx` | 0.34/s | +| `wcn36xx_tx` | 0.11/s | +| `pm8916_vm_bms` | 0.02/s | +| CPU idle | 97.93% overall, 99.48% cpu0, 96.37% cpu1 | +| `cpu-sleep-0` entries | 12.47/s cpu0, 7.54/s cpu1 | +| WFI entries | 0.97/s cpu0, 1.05/s cpu1 | + +Top context-switch deltas were kernel threads (`rcu_preempt` 5.35/s, +`kcompactd0` 1.97/s, four `kworker` threads 1.11/1.10/0.50/0.47/s), then +`NetworkManager` 0.37/s, `wpa_supplicant` 0.26/s, `nmcli device monitor` +0.11/s, `dbus-daemon` 0.11/s, `udevd` 0.06/s and `init` 0.06/s. All 26 +preloaded `dwm-plugin` daemons and `Xorg` were absent from the top 30, which +confirms the zero-lag resident-plugin model is not the remaining drain. + +Runtime PM was already effective: `1c00000.gpu`, both SDHCI hosts, SPI, DMA +controllers, IOMMU and the modem `bam-dmux` were suspended; genpd `mx`, +`mx_ao`, `cx` and all GDSCs were off, with only `cx_ao` on. GPU devfreq was +`simple_ondemand` at 409.6 MHz with a 100 ms poll. 21 clocks remained enabled, +including `bimc_ddr_clk_src`, `gcc_mss_q6_bimc_axi_clk`, USB HS clocks and the +serial-console `gcc_blsp1_uart1_apps_clk`. Regulators with users were the dummy +regulator, `s2`, `l5`, `l7`, `l8` and `l13`. + +`/sys/power/state` was still 0 bytes, `/proc/device-tree/psci` absent, +cpuidle driver `qcom_spm` with WFI + `cpu-sleep-0`, `CONFIG_SUSPEND` off, +`CONFIG_NO_HZ_IDLE=y`, `CONFIG_HZ=300`, `CONFIG_PREEMPT=y`, +`CONFIG_PERF_EVENTS=y`, `CONFIG_FUNCTION_GRAPH_TRACER=y`, +`CONFIG_ENERGY_MODEL` off and `CONFIG_CPU_IDLE_GOV_MENU=y`. The ABI-breaking +config list from section 14 still applies; a full pmaports module tree rebuild +remains declined. + +### 17.3 Two low-risk wins found and implemented + +1. **The active zram swap used `zstd`, not the shipped `lz4` setting.** + `postmarketos-zram-swap` calls `/usr/bin/zramstart`, which sources + `/usr/share/misc/source_deviceinfo` and defaults + `deviceinfo_zram_swap_algo` to `zstd`; it ignores + `/etc/conf.d/zram-init`. Live `/sys/block/zram0/comp_algorithm` showed + `[zstd]`. All five `devices/*/deviceinfo*` files now set + `deviceinfo_zram_swap_algo="lz4"`, and the `zram-init` config carries a + compatibility note. This restores the intended U12/K13 CPU saving without + changing the kernel or module ABI. + +2. **Proactive compaction kept `kcompactd0` awake.** The default + `vm.compaction_proactiveness=20` produced 1.97 context switches/s from + `kcompactd0`. A controlled 60 s A/B with + `vm.compaction_proactiveness=0` reduced that to 0.02/s and raised measured + CPU idle from 97.93% to 99.22%; combined timer IRQs fell from 26.65/s to + 17.39/s. The A/B window also showed a 3.42/s `ci_hdrc_msm` USB IRQ from + SSH/charger activity, so this is a wakeup saving, not a measured mA + saving. `vm.compaction_proactiveness=0` is now set in + `etc/sysctl.d/99-bananarchy-power.conf` and + `etc/local.d/10-power-save.start`. + +### 17.4 DSDS eco A/B was inconclusive without discharge current + +With `DSDS_SECONDARY_MODE=eco` and `DSDS_PARK_DELAY=2`, the secondary GW +session parked cleanly (`secondary_parked=yes`, `SECONDARY_GW_SLOT=0`) and +restored on wake. The 60 s IRQ rates did not improve versus baseline +(`mmc0` 1.24/s, `wcn36xx_rx` 0.74/s, `smd-edge` 0.61/s), likely because the +modem was already searching and the measurement included policy/config file +writes. Eco mode remains an opt-in trade (SIM2 unreachable while parked); its +RF saving can only be quantified on battery power with a registered modem. + +### 17.5 Remaining opportunities, in priority order + +1. **Restore modem registration and the primary/secondary slot mapping.** + This is a functional prerequisite for any radio-power A/B measurement. +2. **Battery-powered A/B for `WIFI_LISTEN_INTERVAL=10`, `MODEM_DRX_MODE=6-9` + and `DSDS_SECONDARY_MODE=eco`.** All three are already configurable via + `/etc/bananarchy-power-policy.conf`; defaults stay conservative because + higher DRX modes and longer listen intervals delay inbound data, and + `AT$QCDRX=9` previously made the AT channel briefly unresponsive. +3. **Replace `nmcli device monitor` with NetworkManager dispatcher hooks.** + It accounts for 0.11 context switches/s and duplicates the dispatcher path + already used for DPM and time sync. +4. **`commit=60` on the rootfs mount.** Could cut a fraction of the 0.56/s + `mmc0` IRQs, but risks data loss on sudden power cut; deliberately not + shipped. +5. **Remove `earlycon console=ttyMSM0` from the cmdline.** Cmdline-only and + ABI-safe, would gate the 3.686 MHz UART clock, but removes the serial debug + lifeline; deliberately kept. +6. **PSCI `SYSTEM_SUSPEND` in lk2nd.** Still the only path to DDR self-refresh + and `mem` suspend. Until then `bimc_ddr_clk_src` stays enabled and no + kernel config change can fix it. +7. **AP-side Wi-Fi DTIM tuning.** Not controllable from the phone. + +The AP and userspace are already close to their idle floor. Further 24 h +battery life has to come from modem/Wi-Fi RF policy, DDR self-refresh, or a +battery-powered measurement campaign; another kernel config trim or full +module tree rebuild is not justified. diff --git a/CHANGELOG.md b/CHANGELOG.md index 318a0d6..bd48dc9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,53 @@ Release versions follow the `
` format (where `2026` is `a`, --- +## Unreleased — xkopher focus scrolling, fresh unlock clock, battery longevity re-analysis + +- **xkopher link focus visibility**: `smallweb_plugin.cpp` now builds display + rows through a shared `buildRenderRows()` helper and maps the focused link + to its first wrapped row via `ensureFocusedLinkVisible()`. Jumping to the + previous/next link always scrolls the viewport to the link in both `WRAP` + and `NOWRAP` modes; with wrapping off it also resets horizontal scroll so + the link label cannot remain off-screen. Toggling wrap re-applies the same + scroll, and Page End now uses display-row count rather than logical-line + count. `prebuilt/sxmo-x11` and `overlay/rootfs` `smallweb.so` were rebuilt. +- **Fresh status bar clock after unlock**: `dmenu.c` had republished the root + status from cached `sxmo_status` files whenever a menu opened or T9 mode + changed. Because `sxmo_hook_statusbar.sh periodics` is suppressed while the + panel is dark, this could show a pre-lock time for up to the 300 s periodic + interval. `update_t9_status_indicator()` now refreshes `099-time` with the + current local time and writes `sxmo_status_bar_cache` before `XStoreName()`. + `sxmo_hook_unlock.sh` additionally calls `sxmo_hook_statusbar.sh time` + synchronously after display-on, and `state_change` always refreshes the + time file and forces a root-name update. Live reproduction: deliberately + setting `099-time` to `00:00` and opening the Config menu rewrote the root + name to `00:00`; after the fix the same test shows the current time. +- **Battery longevity re-analysis**: `BATTERY-OPTIMIZATION-ANALYSIS.md` + section 17 records a fresh 60 s screen-off measurement (97.93% CPU idle, + 26.65 timer IRQs/s, 20 cpuidle SPC entries/s, 26 sleeping plugin daemons, + runtime-suspended GPU/SDHCI/SPI/DMA/IOMMU, 21 enabled clocks, no PSCI or + `/sys/power/state`). It also documents a modem registration anomaly + (`not-registered-searching`, `mmcli -L` empty, swapped GW slots) as a + measurement caveat; no PIN verification was attempted. +- **Two low-risk battery wins implemented**: all deviceinfo files now set + `deviceinfo_zram_swap_algo="lz4"` because the active + `postmarketos-zram-swap` service uses `/usr/bin/zramstart` (which defaults + to `zstd` and ignores `/etc/conf.d/zram-init`); live + `/sys/block/zram0/comp_algorithm` had shown `[zstd]`. + `vm.compaction_proactiveness=0` is now set in + `etc/sysctl.d/99-bananarchy-power.conf` and + `etc/local.d/10-power-save.start`: a controlled A/B reduced `kcompactd0` + from 1.97 to 0.02 context switches/s and raised CPU idle from 97.93% to + 99.22%. DSDS `eco` parking was A/B tested but inconclusive without discharge + current; the conservative defaults remain unchanged. +- `scripts/check-rebuild.sh` guards wrapped-row focus scrolling, dmenu clock + refresh, the synchronous unlock refresh, `lz4` deviceinfo and the + compaction sysctl. `prebuilt/sxmo-x11` was rebuilt for the two changed + plugins and mirrored with `scripts/sync-prebuilt-overlay.sh`; the image and + live phone were redeployed and verified. + +--- + ## Unreleased — manual network time sync from the Config menu - **Config -> Sync net time**: a new menu item in the built-in dmenu Config diff --git a/MANUAL.md b/MANUAL.md index a7cdb75..c986de4 100644 --- a/MANUAL.md +++ b/MANUAL.md @@ -23,7 +23,7 @@ This manual covers flashing, operating, and customizing **Bananarchy Linux** (`2 ### 1.3 Core architecture highlights 1. **Pure X11 (`Xlibre` + `sxmo-de-dwm`) for `240x320` QVGA displays**: - Uses a lightweight cross-compiled **Xlibre** server with `modesetting` KMS, partial-rectangle `ShadowFB` SPI updates, and zero Wayland overhead. - - **Patched `dwm`** provides a `240x320` vertical bottom-stack (`bstack`) layout, a 24px top status bar, a transparent `"Menu"` / `"Names"` desktop softkey bar, a native `ParentRelative` desktop datetime overlay (`Fira Code` 32pt `%H:%M` and 14pt `%a %d %b %Y` with 1px drop shadow, rendered directly by `dwm` with zero external Conky process overhead and automatic live timezone/wallpaper refresh), and `< 2 ms` handling of physical slider (`SW_LID`) and wake keys. + - **Patched `dwm`** provides a `240x320` vertical bottom-stack (`bstack`) layout, a 24px top status bar, a transparent `"Menu"` / `"Names"` desktop softkey bar, a native `ParentRelative` desktop datetime overlay (`Fira Code` 32pt `%H:%M` and 14pt `%a %d %b %Y` with 1px drop shadow, rendered directly by `dwm` with zero external Conky process overhead and automatic live timezone/wallpaper refresh), and `< 2 ms` handling of physical slider (`SW_LID`) and wake keys. The status bar clock is refreshed synchronously on unlock and whenever dmenu updates its input-method indicator, so it cannot keep showing a pre-lock time after the panel wakes. 2. **Preloaded resident DWM plugins (`< 2 ms` wakeup)**: - Core phone applications (`dmenu`, `xdrawer`, `dialer`, `calllog`, `callscreen`, `contacts`, `sms`, `files`, `camera`, `themes`, `passcode`, `modem`, `networks`, `ringtones`, `wallpapers`, `music`, `sip`, `email`, `irc`, `tox`, `smallweb`, `webarchy`, `gps`, `privacy`, `engmenu`, `locker`) run as preloaded resident daemons (`dwm-plugin --preload`) that sleep at 0% CPU and open instantaneously over FIFO/socket IPC. - All UI elements — including the `dunst` notification daemon (`bananarchy-sync-dunst-theme`) — share the **NeoUI SDK (`libneoui.so` + `/usr/include/neoui.h`)** and a single **XRDB theming engine** (`~/.xthemes/*.xth` -> `~/.Xresources`) with 21 preinstalled color schemes, proportional font sizing (`theme.baseFontSize`), and live reload without restarting X11. NeoUI exposes both C++20 classes and a C-compatible FFI (`neoui_*`) for building custom native or scripted (`yabasic` via `~/Projects/neoui.yab`, `~/Projects/neoui_demo.yab`, and `~/Projects/bulls_cows.yab`, paired with **NeoNet** in `~/Projects/neonet.yab` and `~/Projects/neonet_demo.yab` for `libcurl` HTTP/HTTPS and TCP/TLS/UDP socket networking) `240x320` GUI applications — see [SDK.md](./SDK.md) for the complete API reference and examples. @@ -274,6 +274,11 @@ All twenty-five phone applications are compiled as shared-object plugins (`/usr/ - **`1` and `7`**: scroll left / right (`4` columns when line wrapping is off) - **`3` and `9`**: jump to top / bottom of page - **`*`**: toggle line wrapping (`WRAP` / `NOWRAP`) + - **Link focus always scrolls the viewport**: jumping to the previous / + next link (or toggling wrap) scrolls the focused link into view using + the actual wrapped display rows, in both `WRAP` and `NOWRAP` modes. + With wrapping off, horizontal scroll is reset to the start of the link + label. Page End also uses display rows rather than logical lines. - **`#`**: toggle light / dark reader theme - **`0`**: reload current page - **`Call (green)`**: open URL address bar (`*` cycles input mode; `Call` inside the address bar toggles `Gopher TLS`) diff --git a/README.md b/README.md index aa493ce..291c433 100644 --- a/README.md +++ b/README.md @@ -16,9 +16,9 @@ ## Key features ### System and hardware support -- **Mainline Linux 6.12 kernel**: custom patches and out-of-tree drivers for Qualcomm **Adreno 304 (`FD304`, 96 KB GMEM)** 3D GPU acceleration (`drm/msm` + `qcom-iommu`), Qualcomm QDSP6/Q6Voice audio routing, Dual-SIM modem control, the rear 2MP GalaxyCore `GC2395` / `GC2385` / `GC2365` camera (`/dev/video0`), the `SY7807` flashlight LED (`white:torch`), physical keypad/slider events, and clean PM8909 poweroff. The kernel image is built from `config-bananarchy-msm8909.armv7` with the known-good pmaports module ABI, and ships with idle-blanking power management; `BATTERY-OPTIMIZATION-ANALYSIS.md` records the measured idle state and explains why suspend-to-RAM is unavailable on this firmware (PSCI `SYSTEM_SUSPEND` missing) and why a full custom module tree rebuild is not worthwhile. Runtime Wi-Fi listen-interval, modem DRX and DSDS secondary-SIM power policies are configurable in `/etc/bananarchy-power-policy.conf`; see `MANUAL.md`. +- **Mainline Linux 6.12 kernel**: custom patches and out-of-tree drivers for Qualcomm **Adreno 304 (`FD304`, 96 KB GMEM)** 3D GPU acceleration (`drm/msm` + `qcom-iommu`), Qualcomm QDSP6/Q6Voice audio routing, Dual-SIM modem control, the rear 2MP GalaxyCore `GC2395` / `GC2385` / `GC2365` camera (`/dev/video0`), the `SY7807` flashlight LED (`white:torch`), physical keypad/slider events, and clean PM8909 poweroff. The kernel image is built from `config-bananarchy-msm8909.armv7` with the known-good pmaports module ABI, and ships with idle-blanking power management; `BATTERY-OPTIMIZATION-ANALYSIS.md` records the measured idle state and explains why suspend-to-RAM is unavailable on this firmware (PSCI `SYSTEM_SUSPEND` missing) and why a full custom module tree rebuild is not worthwhile. Section 17 adds a post-`a1107` re-analysis and two low-risk wins: the active zram swap now uses `lz4` instead of `zramstart`'s `zstd` default, and `vm.compaction_proactiveness=0` removes ~2 `kcompactd0` wakeups/s. Runtime Wi-Fi listen-interval, modem DRX and DSDS secondary-SIM power policies are configurable in `/etc/bananarchy-power-policy.conf`; see `MANUAL.md`. - **Alpine Linux Edge base**: full access to the Alpine package ecosystem with `< 95 MB` idle RAM usage on 512 MB devices and full local root access out of the box. -- **Network time synchronisation**: `chronyd` uses `iburst` with long `minpoll 12 maxpoll 16` polls; `bananarchy-time-sync.sh` re-resolves the NTP pool and requests an immediate burst over chronyd's root-only Unix socket when NetworkManager brings a connection up, so the clock is set within seconds of boot or a Wi-Fi reconnect without shortening the battery-friendly steady-state interval. **Config -> Sync net time** forces a burst manually and reports the result when autosync is slow. See `MANUAL.md` section 5.7. +- **Network time synchronisation**: `chronyd` uses `iburst` with long `minpoll 12 maxpoll 16` polls; `bananarchy-time-sync.sh` re-resolves the NTP pool and requests an immediate burst over chronyd's root-only Unix socket when NetworkManager brings a connection up, so the clock is set within seconds of boot or a Wi-Fi reconnect without shortening the battery-friendly steady-state interval. **Config -> Sync net time** forces a burst manually and reports the result when autosync is slow. The status bar clock is also refreshed synchronously on unlock and by dmenu itself, so it cannot show a stale pre-lock time. See `MANUAL.md` section 5.7. - **Pure X11 graphical stack with GPU acceleration**: cross-compiled **Xlibre** (`X11Libre/xserver`) display server offloading 2D/3D screen rendering to the **Adreno 304 GPU** via **Glamor, DRI3, GLX, and Mesa Freedreno (`FD304`, OpenGL 3.1 / OpenGL ES 3.0)** over `panel-mipi-dbi` KMSRO, paired with a customized **Sxmo (`sxmo-de-dwm`)** window manager (`240x320` vertical stack layout, native `ParentRelative` desktop clock and softkey bar without Conky overhead, `< 2 ms` slider/key wake latency, and zero Wayland overhead). ### Keypad-first user experience and native DWM plugins @@ -43,7 +43,7 @@ Instead of spawning slow shell scripts for everyday phone tasks, Bananarchy runs - **Email client (`xemail` / `xmail` / `email.so`)**: multi-account `IMAP4rev1`, `POP3`, and `SMTP` client (`Inbox`, `Compose`, `Accounts`) supporting implicit TLS, `STARTTLS`, and plain TCP, SASL `PLAIN`/`LOGIN`, MIME RFC 2047/Base64/Quoted-Printable decoding, offline inbox cache, full-screen message reader, and composer. - **IRCv3 client (`xirc` / `irc.so`)**: multi-server IRC client (`Buffers`, `Chat`, `Servers`) with OpenSSL TLS, IRCv3 capability negotiation (`CAP LS 302`: `sasl`, `server-time`, `message-tags`, `multi-prefix`, `away-notify`, `account-notify`, `chghost`, `cap-notify`), `SASL PLAIN` authentication, slash commands, and resident background mode with highlight vibration alerts. - **Tox / Trifa P2P messenger and audio call client (`xtox` / `tox.so`)**: encrypted P2P messenger (`Friends`, `Chat`, `My Tox ID`) built on `c-toxcore` (`libtoxcore.so.2`) with DHT + TCP relay bootstrap, friend requests, persistent message history, and `ToxAV` 48 kHz Opus voice calls integrated with `xcallscreen`. - - **Kopher SmallWeb browser (`xkopher` / `kopher` / `xsmallweb` / `smallweb.so`)**: multi-protocol SmallWeb client for **Gopher** (`gopher://`) with optional TLS (`gophers://`), **Gemini** (`gemini://`), **Spartan** (`spartan://`), and **Nex** (`nex://`), featuring WAP-style default keypad controls from [Kopher](https://code.luxferre.top/luxferre/kopher.git), user-adjustable keybindings (`~/.config/sxmo/smallweb_controls.tsv`), 10 bookmarks, and custom homepage support. + - **Kopher SmallWeb browser (`xkopher` / `kopher` / `xsmallweb` / `smallweb.so`)**: multi-protocol SmallWeb client for **Gopher** (`gopher://`) with optional TLS (`gophers://`), **Gemini** (`gemini://`), **Spartan** (`spartan://`), and **Nex** (`nex://`), featuring WAP-style default keypad controls from [Kopher](https://code.luxferre.top/luxferre/kopher.git), user-adjustable keybindings (`~/.config/sxmo/smallweb_controls.tsv`), 10 bookmarks, custom homepage support, and link focus that always scrolls the viewport to the focused link in both wrapped and unwrapped modes. - **Webarchy Web browser (`webarchy` / `xwebarchy` / `webarchy.so`)**: full-featured HTML5/CSS3/JS web browser built on WPE / WebKit (`webkit2gtk-4.1` + `libwpe-1.0`) with Adreno 304 hardware acceleration (`WEBKIT_HARDWARE_ACCELERATION_POLICY_ALWAYS`, WebGL, accelerated 2D canvas, and 512 MB RAM pressure tuning), default KaiOS 4.0 User-Agent (`Mozilla/5.0 (Mobile; rv:123.0) Gecko/123.0 Firefox/123.0 KAIOS/4.0`) with preset and custom User-Agent override (`~/.config/sxmo/webarchy_ua.txt`), `UTF-8` default encoding fallback, `Noto Sans` / `Noto Serif` (`font-noto` + `font-noto-emoji`) as the default non-monospace browser fonts and `Fira Code` with OpenType ligatures as the monospace font, full GStreamer multimedia (`MediaSource` / MSE, WebAudio, inline HTML5 `