|
|
@@ -63,11 +63,14 @@ make run-ehci-asix # pass through a real ASIX AX88772 dongle on EHCI
|
|
|
make run-net # like `make run` + a PCI NE2000 NIC on QEMU's user network (slirp; DHCP/DNS/NAT)
|
|
|
make run-rndis # xHCI + QEMU usb-net RNDIS tethering device on slirp (rndis netdev)
|
|
|
make run-ahci # like `make run` + an ICH9 AHCI controller and a 512 MB SATA disk (sata0)
|
|
|
+make run-amd # QEMU Opteron_G5 (FX-6350 family 15h model 2), 6 CPUs, OHCI + e1000
|
|
|
+make test-amd # headless AMD boot check (IOAPIC mask, 6 CPUs, PIT)
|
|
|
make uefi # build BOOTX64.EFI and the dual-boot usb-efi.img
|
|
|
make run-uefi # boot usb-efi.img under OVMF (x86-64 UEFI; serial log in /tmp/opencode)
|
|
|
make test-uefi # headless OVMF boot test (greps the serial log for the boot line)
|
|
|
make test-install # installer test: clone, reinstall, install self, /data, BIOS/UEFI boot
|
|
|
make rootfs # build cmds.img (the 8 MB rootfs partition image)
|
|
|
+make browser-host # Linux SDL3 host harness (browser-host + host-curl); dev-only
|
|
|
make nowm # diagnostic kernel with no WM; the boot console stays visible
|
|
|
make dev # serial kernel + rootfs reload (KXE2)
|
|
|
make kernel-dev # serial kernel-only reload (keeps the running rootfs)
|
|
|
@@ -94,6 +97,15 @@ make clean
|
|
|
|
|
|
- Build flags (in `Makefile`): `-m32 -march=i586 -ffreestanding -fno-pie -nostdlib
|
|
|
-fno-stack-protector -mno-sse -mno-sse2 -mno-mmx -O2`.
|
|
|
+- `make browser-host` is a development-only harness, not part of the images: it
|
|
|
+ builds `browser.c`, ngui, the image/TLS stack and QuickJS as a 32-bit Linux
|
|
|
+ program against the same `SYS_*` ABI (`host/syscall.c`, an SDL3 window,
|
|
|
+ host files/sockets and `fork/exec` for `curl __serve`). Run
|
|
|
+ `./browser-host [--size WxH] [--root DIR] URL|FILE`, or
|
|
|
+ `./browser-host --headless --wait 3000 --shot out.ppm URL` to render the
|
|
|
+ compat ladder without a display. It needs the multilib `lib32-sdl3`,
|
|
|
+ `lib32-wayland` and `lib32-libxkbcommon`; host sockets replace the NebOS TCP
|
|
|
+ stack and the kernel/WM paths are not exercised.
|
|
|
- QEMU guests default to 512 MB (`QEMU_MEM`, e.g. `make run QEMU_MEM=1G`),
|
|
|
matching `MM_MAX_PHYS` in `phys.h`; all run and UEFI targets pass `-m`.
|
|
|
- The command pack is the system rootfs: `cmds.pack` (NBPAK1), gzip-compressed
|
|
|
@@ -139,6 +151,13 @@ make clean
|
|
|
BIOS never read FATSize16. `make flash` needs the mingw toolchain because
|
|
|
it builds `usb-efi.img`.
|
|
|
|
|
|
+The Gigabyte 970A-DS3P / FX-6350 / GTX 960 target is **UEFI-first** and
|
|
|
+serial-less: boot `usb-efi.img` from USB, use the 970A's SB950 AHCI/OHCI/EHCI,
|
|
|
+the RTL8111E (`10ec:8168`) and the GTX 960 through its GOP. The boot console
|
|
|
+is the only early log; once DHCP works, `make netmon` is the serial substitute
|
|
|
+and `make net-dev`/`kernel-net-dev` reload over the network. `bootlog save
|
|
|
+/usb0p3/BOOTLOG.TXT` writes the captured boot log to the live stick's FAT ESP.
|
|
|
+
|
|
|
## Boot chain
|
|
|
|
|
|
1. `boot.S` — 512-byte boot sector (FAT16 BPB). Loads contiguous kernel sectors
|
|
|
@@ -162,7 +181,9 @@ make clean
|
|
|
pack; the CPU copy is used instead. `paging_prepare_cpu()` still clears
|
|
|
the CR4/EFER state a BIOS protected-mode call can leave behind. The
|
|
|
stage then picks the best VBE mode
|
|
|
- (≥16 bpp, LFB, fits VRAM, ≤1280px), writes mode info to `0x600` and the
|
|
|
+ (≥16 bpp, LFB, fits VRAM, ≤1920px, shadow ≤8 MB and ≤2 M pixels so a
|
|
|
+ full-screen RGB565 canvas fits the 4 MB window slot), writes mode info
|
|
|
+ to `0x600` and the
|
|
|
12-dword `struct boot_info` (magic/checksum/rsdp/flags/pack range) to
|
|
|
`0x500`, enters protected mode and jumps to `kernel_entry` (`entry.S`,
|
|
|
re-points ESP to the current stack top, then `kernel_main`). The pack
|
|
|
@@ -283,8 +304,11 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
Ring 0 is preemptible at tick boundaries unless `preempt_count` is set (FAT
|
|
|
and the shadow flush) or the BKL is held; voluntary blocks/yields go through
|
|
|
the `int 0x81` gate.
|
|
|
-- **SMP / ACPI**: `acpi.c/h` (RSDP → RSDT/XSDT → MADT; CPU/LAPIC list and
|
|
|
- LAPIC base; 4 MB table page mapping; malformed tables are ignored), `lapic.c/h`
|
|
|
+- **SMP / ACPI**: `acpi.c/h` (RSDP → RSDT/XSDT → MADT; CPU/LAPIC and IOAPIC
|
|
|
+ base lists; 4 MB table page mapping; malformed tables are ignored),
|
|
|
+ `ioapic.c/h` (masks the normal IOAPIC redirection entries after ACPI init so
|
|
|
+ the 8259/LINT0 path is deterministic; ExtINT entries are preserved),
|
|
|
+ `lapic.c/h`
|
|
|
(xAPIC MMIO access, BSP/AP init, INIT/SIPI/IPI, calibrated periodic timer),
|
|
|
`smp.c/h` (trampoline copy, AP stacks via `process_init_ap`, INIT-SIPI-SIPI
|
|
|
with a second SIPI retry, per-CPU `smp_ap_main`, `smp_stop_aps`, lazy
|
|
|
@@ -403,7 +427,7 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
`sys_wm.c` is the ABI bridge. `SYS_WIN_CREATE` gives a command its window
|
|
|
canvas mapped RW at `USER_WIN_BASE` (`0x50000000`); the WM maps each front
|
|
|
canvas in its own 4 MB `WM_CONTENT_SLOT`, which covers a full-screen
|
|
|
- 1280x1024 canvas minus the chrome. `SYS_WIN_PRESENT`
|
|
|
+ 1920x1080 RGB565 canvas (4.15 MB) minus the chrome. `SYS_WIN_PRESENT`
|
|
|
optionally takes a content-relative `struct wm_win_present`; the kernel
|
|
|
copies only that rectangle into the front canvas (with interrupts off, so
|
|
|
a half-drawn frame can never reach the screen), unions it into
|
|
|
@@ -435,7 +459,9 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
press/release edges with a capture window, so a click that starts in a
|
|
|
window still gets its release after the pointer leaves. The userland
|
|
|
`ngui.c/h` immediate-mode toolkit builds on those: clipped RGB565
|
|
|
- primitives, buttons, text input, procedural icons and scrolling panes.
|
|
|
+ primitives, buttons, text input, procedural icons and scrolling panes
|
|
|
+ (`ngui_scroll`; `hide_bar` keeps wheel/key scrolling without drawing a
|
|
|
+ scrollbar).
|
|
|
`files` (`ucmd_files.c`) is its first user; `gallery` (`gallery.c`) is the
|
|
|
live showcase of every control and primitive the toolkit exports. Buttons
|
|
|
fire on the release edge and keep `active` until `ui->released`: inferring
|
|
|
@@ -493,8 +519,13 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
through that alias once a WC MTRR covers the stolen range (only then -- a
|
|
|
cached framebuffer would stop updating the screen). Everything else keeps
|
|
|
the UC LFB: `paging.c` maps LFB pages cacheable only when `mtrr_set_wc()`
|
|
|
- says it covered them. `vga_fb_lfb_wc()` reports the effective path and
|
|
|
- `gfxbench` prints it. `nvidia.c`
|
|
|
+ says it covered them. On AMD family 15h, `mtrr_set_wc()` uses a separate
|
|
|
+ path: at most eight variable MTRRs, only a free entry, a zero high mask
|
|
|
+ (the LFB is below 4 GB) and **no write to `MSR_MTRRdefType`**. The Intel
|
|
|
+ path's read-modify-write of `MTRRdefType` reset the 970A-DS3P during the
|
|
|
+ first paging init; the AMD path is validated on the board and enables WC.
|
|
|
+ `vga_fb_lfb_wc()` reports the effective path and `gfxbench` prints it.
|
|
|
+ `nvidia.c`
|
|
|
identifies the card, maps BAR0/BAR1/BAR3 and reads the MCP7x stolen-VRAM
|
|
|
geometry; `nv50.c` probes the nv50-family display engine at boot (read-only,
|
|
|
serial/netmon). The ION/AT3IONT-I hardware cursor is deliberately not driven:
|
|
|
@@ -610,11 +641,14 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
first; their operations (and SYS_SPAWN of a RAM path,
|
|
|
`sys_fs_enter_path()`) do not wait for `vfs_scan_busy`
|
|
|
(`vfs_mount_is_ram()`), only disk paths do. The scan runs preemptible;
|
|
|
- the floppy/ATA/AHCI/SDHCI wait loops call `vfs_scan_poll(t0)` /
|
|
|
+ the floppy/ATA/AHCI/SDHCI wait loops (including the SDHCI command,
|
|
|
+ clock/reset and CMD1 power-up polls) call `vfs_scan_poll(t0)` /
|
|
|
`vfs_scan_relax(ms)`, which sleep (dropping the BKL) only for the scan's
|
|
|
owning process, with interrupts on and preemption enabled, and only once
|
|
|
a wait passes 2 ms; at boot in the idle context and in normal I/O they
|
|
|
- are no-ops. So `storage` no longer freezes the WM. `disk_probe()` skips
|
|
|
+ are no-ops. A USB disk read by the rescan claims the USB bus
|
|
|
+ (`usb_bus_claim()` in `usbmsc_read/write/flush`), so its HCD waits yield
|
|
|
+ as well (see the USB bullet). So `storage` no longer freezes the WM. `disk_probe()` skips
|
|
|
a floppy whose CMOS drive type (register `0x10`) is 0.
|
|
|
- **Installer**: `install.c/h` — the privileged `install <target> [source|self]`
|
|
|
command clones the live NebOS image or writes the running image. A clone
|
|
|
@@ -691,7 +725,8 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
layout, because it has no RFCTL but QEMU stores the register, so EXTEN
|
|
|
reads back set while the device still writes legacy descriptors),
|
|
|
`r8168.c`
|
|
|
- RTL8111/8168 (PCIe, polled, C+ mode, 64-entry RX ring), `ne2000.c`
|
|
|
+ RTL8111/8168 family, including the RTL8111E on the Gigabyte 970A-DS3P
|
|
|
+ (PCIe, polled, C+ mode, 64-entry RX ring), `ne2000.c`
|
|
|
RTL8029 (QEMU/ISA), `asix.c` AX88772 USB Ethernet (bulk over the USB
|
|
|
core, so an EHCI/xHCI dongle is usable) and `rndis.c` USB RNDIS tethering
|
|
|
(Android phones and QEMU `usb-net`; device-level config scan, RNDIS
|
|
|
@@ -754,8 +789,19 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
a dumped status/headers/body, chunked decoding (redirects are followed,
|
|
|
up to 5 hops); TLS 1.3 via `tls.c/h` + `tls_sha256.c`, `tls_chacha20.c`,
|
|
|
`tls_x25519.c`, `tls_rng.c`:
|
|
|
- `TLS_CHACHA20_POLY1305_SHA256` + X25519 only, stream-oriented record
|
|
|
- layer, leaf SHA-256 fingerprint printed for a manual check. Certificates
|
|
|
+ `TLS_CHACHA20_POLY1305_SHA256` + X25519, stream-oriented record
|
|
|
+ layer, leaf SHA-256 fingerprint printed for a manual check. The same
|
|
|
+ ClientHello also offers TLS 1.2 (RFC 5246) for servers without 1.3
|
|
|
+ (arstechnica.com's load balancer): ECDHE over X25519 or P-256
|
|
|
+ (`tls_p256.c`, Montgomery 8x32-bit limbs, ECDH only) with
|
|
|
+ ChaCha20-Poly1305 (`0xCCA8/0xCCA9`) or AES-128-GCM (`0xC02F/0xC02B`;
|
|
|
+ `tls_gcm.c`, 4-bit GHASH tables on `wpa_crypto.c`'s AES), the extended
|
|
|
+ master secret when echoed, an empty client Certificate on request and
|
|
|
+ the P_SHA256 PRF (`tls12_prf()` in `tls_sha256.c`). The ServerHello's
|
|
|
+ supported_versions picks the state machine; the TLS 1.3 middlebox CCS is
|
|
|
+ sent before the client Finished, not after the ClientHello (a 1.2 server
|
|
|
+ rejects it there). The 1.3 key share is X25519 only (no
|
|
|
+ HelloRetryRequest), and the ServerKeyExchange signature is not checked. Certificates
|
|
|
are **not verified** (phase A: encryption without authentication; a
|
|
|
MITM is undetected) and the DRBG (`tls_rng.c`: RDTSC jitter + ticks +
|
|
|
MAC) is deliberately weak. The crypto files are pure freestanding C
|
|
|
@@ -980,14 +1026,27 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
and USB3 root ports; halt/HCH reset sequence and BIOS/OS handoff)
|
|
|
implement it.
|
|
|
`lsusb.c` — the `lsusb` command (lists every controller and its tree).
|
|
|
- Every HCD delay goes through `usb_delay_ms()`: inside a scan
|
|
|
- (`usb_scan`/`usb_hotplug_poll`) owned by a sleepable process — `lsusb`,
|
|
|
- the kworker's HID rescan/hotplug enumeration — it sleeps and drops the
|
|
|
- BKL, so port resets no longer stall the system; elsewhere it busy-waits.
|
|
|
- While such a scan sleeps, `usb_scan_foreign()` makes the `usb.c`
|
|
|
- wrappers refuse other contexts (control/bulk transfers fail, interrupt
|
|
|
- polls return 0, `usb_port_connected` reports 1) and `usbhid_poll` skips
|
|
|
- its tick; USB NICs, the RTL8821AU and USB disks see a transient error.
|
|
|
+ A scan (`usb_scan`/`usb_hotplug_poll`) and every `usbmsc` command claim
|
|
|
+ the controllers for the calling process (`usb_bus_claim()`/
|
|
|
+ `usb_bus_release()`, nesting). Every HCD delay, and the ASIX/RNDIS/
|
|
|
+ usbmsc probe delays, go through `usb_delay_ms()`, and every HCD
|
|
|
+ completion/port-reset poll loop calls `usb_poll_relax(t0)` outside its
|
|
|
+ spinlock. When the claim belongs to a sleepable scan — `lsusb`, the
|
|
|
+ kworker's HID rescan/hotplug enumeration, or the `storage` rescan's
|
|
|
+ `vfs_mount_all()` reading a USB disk — the delay sleeps and the poll
|
|
|
+ yields once a wait passes 2 ms, both dropping the BKL; elsewhere
|
|
|
+ (pid 0 at boot, preemption off, interrupts-off syscalls, normal file I/O,
|
|
|
+ the installer) they busy-wait as before. The poll yields rather than
|
|
|
+ sleeping 1 ms because a sleep on an idle CPU wakes on the 100 Hz idle
|
|
|
+ tick, which made each slow transfer cost ~10 ms. So `lsusb` no longer
|
|
|
+ freezes the WM (in QEMU the longest BKL hold dropped from ~105 ms in
|
|
|
+ xHCI `port_reset` to under the 50 ms sampling threshold; on hardware
|
|
|
+ the ASIX probe alone used to spin ~450 ms). While another context owns
|
|
|
+ the bus, `usb_scan_foreign()` makes the `usb.c` wrappers refuse access
|
|
|
+ (control/bulk transfers fail, interrupt polls return 0,
|
|
|
+ `usb_port_connected` reports 1), `usb_hotplug_poll` skips its pass and
|
|
|
+ `usbhid_poll` skips its tick; USB NICs, the RTL8821AU and USB disks see
|
|
|
+ a transient error.
|
|
|
`usbmsc.c/h` — USB mass-storage class driver (BOT/SCSI) exposed as
|
|
|
`usb0..`; its device probe is registered next to ASIX and `blk_scan()`
|
|
|
registers the devices in the block registry.
|
|
|
@@ -1057,10 +1116,19 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
scales as well as the top bar's bare `43C` before the clock and, on
|
|
|
ThinkPads and the HP Chromebook, the AC/battery icon at the far right (a
|
|
|
plug while on AC, a level-filled battery on battery, with a percentage
|
|
|
- tooltip below it on hover) and `cpuinfo`'s value plus EIST state. Platforms
|
|
|
- without DTS (QEMU, Pentium) hide it.
|
|
|
+ tooltip below it on hover) and `cpuinfo`'s value plus EIST state.
|
|
|
+ AMD family 15h models below `0x60` (Bulldozer/Piledriver, the FX-6350)
|
|
|
+ read Tctl from `D18F3xA4` at PCI `0:18.3`: `raw = val >> 21`, `raw * 125`
|
|
|
+ m°C, minus 49 °C when bits 17:16 are both set, TjMax 70 °C. The probe
|
|
|
+ runs on the BSP before the timer; the 1 Hz sample runs from the kworker's
|
|
|
+ `thermal_housekeeping()` under the BKL (never from the per-CPU timer
|
|
|
+ interrupt, where a PCI config access could race another CPU) and is
|
|
|
+ published to every CPU. No AMD MSR is touched, so there is no early
|
|
|
+ `#GP` risk. A platform with neither Intel DTS nor AMD `D18F3xA4` hides
|
|
|
+ the temperature.
|
|
|
- **Board sensors**: `it87.c/h` — read-only probe of the IT87xx Super I/O
|
|
|
- (the AT3IONT-I exposes three temperatures and three fan tachometers), used
|
|
|
+ (the AT3IONT-I and the 970A-DS3P's IT8728F expose temperatures and fan
|
|
|
+ tachometers), used
|
|
|
by `SYS_SENSORS` and the ring-3 `sensors` command to cross-check the DTS
|
|
|
and show whether the fans turn. Nothing is written to the fan control.
|
|
|
`tpec.c/h` adds the ThinkPad embedded controller of the X201
|
|
|
@@ -1228,8 +1296,23 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
`z-index`, `transform: translate`/`scale`/`rotate` with
|
|
|
`transform-origin` (paint-time box and inline-image transforms), flex rows
|
|
|
with `justify-content` (including `space-evenly`)/`align-items`, two-column
|
|
|
- grids, table colspan and percentage columns, and basic `float: left/right`
|
|
|
- columns.
|
|
|
+ grids and `repeat(N, 1fr)`/`repeat(N, minmax(0,1fr))` equal-column grids
|
|
|
+ (Tailwind `grid-cols-N`; `grid_auto` = `BR_GRID_FIXED` + N), `aspect-ratio`
|
|
|
+ as the preferred height of an auto-height box (`aspect-video`/
|
|
|
+ `aspect-square` frames), table colspan and percentage columns, and basic
|
|
|
+ `float: left/right` columns. Inline and inline-block `<svg>` icons are
|
|
|
+ line runs like `<img>` (`RUN_SVG`), and an inline-block holding only
|
|
|
+ inline text with no box of its own stays in the text line instead of
|
|
|
+ starting a row of boxes. An absolutely positioned or block `<img>`
|
|
|
+ applies `max-width`/`min-width` against its containing block and keeps
|
|
|
+ the attribute aspect ratio unless CSS sets a height. A sticky box with a
|
|
|
+ `z-index` (a site header) is painted in the deferred stacked pass, above
|
|
|
+ the content after it. Rules are indexed by their unescaped class
|
|
|
+ (`.md\:flex` under `md:flex`), and `class`/`style` attributes keep up to
|
|
|
+ 2 KB (`BR_CLASS_MAX`): Tailwind class lists are 300-600 bytes, and the old
|
|
|
+ 120-byte cap silently dropped every responsive variant past it. A
|
|
|
+ stylesheet whose helper fetch fails is retried once synchronously
|
|
|
+ (`[css] retry` on the log) instead of leaving the page unstyled.
|
|
|
`@media (min-width/max-width)` blocks are evaluated against the browser
|
|
|
canvas width when the page is parsed; `@import`/`@keyframes` are skipped.
|
|
|
`@font-face` loads one regular TTF per family from a local path or HTTP URL
|
|
|
@@ -1313,14 +1396,36 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
malloc/free fragmented the first-fit heap until a page of 200 icons ran
|
|
|
out of memory. A background image is scaled to cover its laid-out box
|
|
|
(an icon is decoded at 56 px, not 1000), and up to 256 bitmaps within a
|
|
|
- 4 M-pixel budget (`BR_IMG_PIXEL_BUDGET`; 512 KB files / 8 MP decodes) are
|
|
|
+ 4 M-pixel budget (`BR_IMG_PIXEL_BUDGET`; 1 MB files / 8 MP decodes) are
|
|
|
kept until the page heap is reset. Background images load lazily like
|
|
|
`<img>` (measure-pass `block_top[]` against the scroll position), an
|
|
|
image job holds a fetch helper for at most `BR_IMG_JOB_TIMEOUT_MS` (30 s),
|
|
|
in-flight nodes are marked `-3` so rescans skip them, and a script that
|
|
|
sets `style`/`class`/`src` later (Angular `ng-style`) re-arms a node the
|
|
|
first scan had marked empty; DOM changes from scripts trigger a rescan.
|
|
|
- Rounded boxes paint their background image inside the corner arcs. Navigation calls `heap_reset()` and unmaps the whole
|
|
|
+ Rounded boxes paint their background image inside the corner arcs.
|
|
|
+ Images with a CSS/attribute box decode at those bounds:
|
|
|
+ `img_options.max_w/h` lets the JPEG decoder choose a 1/2, 1/4 or 1/8
|
|
|
+ scaled IDCT (Loeffler/IGJ 4x4/2x2/1x1) instead of decoding full size and
|
|
|
+ then box-filtering to the 1000 px layout cap. For remote `<img>` the warm
|
|
|
+ `curl __serve` helper does that decode (the request carries
|
|
|
+ `D <max_w> <max_h>` and the bitmap arrives as `/share/bf...px`), so the UI
|
|
|
+ thread only reads and copies it; local files and backgrounds still decode
|
|
|
+ in-process. `<img>` uses its
|
|
|
+ CSS/attribute width/height (or the parent layout box for
|
|
|
+ `max-width:100%`), backgrounds use their box, so a 1200x800 photo painted
|
|
|
+ at 400x267 decodes at roughly 600x400 and is scaled once. A per-image
|
|
|
+ display-size bitmap (`br_image.disp`) is built lazily from the capped
|
|
|
+ source and `img_draw`'s 1:1 opaque-copy and integer-alpha paths make later
|
|
|
+ paints memcpy. Image-driven repaints are coalesced to 100 ms;
|
|
|
+ helper-decoded `<img>` jobs only copy their px file, while local and
|
|
|
+ background jobs decode in a 40 ms batch per main-loop pass, so a page
|
|
|
+ no longer does a full layout+paint per image; a background decode keeps
|
|
|
+ the measured layout (only `page_cache_valid` is cleared) and a decode
|
|
|
+ below the fold does not invalidate the screen. At batch end the status
|
|
|
+ line and `/share/IMGSTAT` report wall, net (TLS), io, dec, scale, paint
|
|
|
+ and reflow totals plus one line per image.
|
|
|
+ Navigation calls `heap_reset()` and unmaps the whole
|
|
|
arena, so a large image no longer reserves a fixed 24 MB. `<script>`
|
|
|
blocks are collected by `browser_html.c`; inline bodies run directly and
|
|
|
`<script src>` bodies are fetched through the same local/network path as
|
|
|
@@ -1354,7 +1459,15 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
`pathname`/`search`/`hash`/`origin`) resolved against the page URL.
|
|
|
`document` exposes `createElement`/`createTextNode`/`createComment`/
|
|
|
`createDocumentFragment`/`createAttribute`, `documentElement`/`body`/
|
|
|
- `head` and `readyState`; `navigator`, `history`, `matchMedia`,
|
|
|
+ `head`, `readyState`, `currentScript` (set by the browser before each
|
|
|
+ classic script from `br_script.node`; null for modules) and the live
|
|
|
+ `scripts`/`images`/`forms`/`links`/`embeds` collections; `<template>`
|
|
|
+ is inert (`BR_TAG_TEMPLATE`, display none) and the prelude moves a
|
|
|
+ parsed template's children into its `content` fragment before any page
|
|
|
+ script runs (Alpine's `x-for`/`x-if`/`x-teleport` clone it); `parentNode`
|
|
|
+ of a child of node 0 (the tree root is the `<html>` element itself when
|
|
|
+ the page starts with one) is that element, not null (`node_parent_idx`),
|
|
|
+ which jQuery/Sizzle need to remove their probe elements; `navigator`, `history`, `matchMedia`,
|
|
|
`getComputedStyle`, `setTimeout`/`setInterval`/`clearTimeout` and
|
|
|
`requestAnimationFrame` exist, and due timers run from
|
|
|
`js_browser_tick()` in the browser loop. `location` carries the split
|
|
|
@@ -1499,12 +1612,22 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
API (`/api/me`, `/api/channels`, `/api/dms`, `/api/channels/public`,
|
|
|
`/api/users`, messages with `?limit=50`, `&before=` and `&after=`, POST
|
|
|
messages with a `clientId`, `/read`, `/join`, `/api/dms`) through one
|
|
|
- `struct uhttp` with a cookie jar. Message images and avatars use the same
|
|
|
- uhttp connection and cookie jar, are fetched one per main-loop pass, and
|
|
|
- are decoded by the in-tree image library (PNG/JPEG/GIF first
|
|
|
- frame/BMP/TGA/PNM/ICO/PAM). They live in a 16-entry, 6 MB message-image
|
|
|
- LRU plus a 64-entry avatar cache. The fetch is capped at 4 MB and the
|
|
|
- decoder at 4 MP / 12 MB of scratch.
|
|
|
+ `struct uhttp` with a cookie jar. Message images and avatars are
|
|
|
+ downloaded by a warm `curl __serve` helper (one worker, dispatched from
|
|
|
+ `chat_media_tick()`; its DNS/TLS log lines go to a private tty), with the
|
|
|
+ chat cookie jar written to `/share/bchat.jar` as the helper's optional
|
|
|
+ jar-path argument. The main loop only submits a request file and polls a
|
|
|
+ done marker, so the window no longer freezes for the download. Message
|
|
|
+ images also carry `D 480 320`, so the helper decodes them and chat only
|
|
|
+ copies the published bitmap; avatars still decode on the chat thread at
|
|
|
+ 32x32 (`img_options.max_w/h`), which keeps the square source the circular
|
|
|
+ mask expects while a large JPEG avatar gets a reduced IDCT instead of a
|
|
|
+ full 512x512 decode. The in-tree image library (PNG/JPEG/GIF first
|
|
|
+ frame/BMP/TGA/PNM/ICO/PAM) is the fallback for both. They live in a
|
|
|
+ 16-entry, 6 MB message-image LRU plus a 64-entry avatar cache. The fetch
|
|
|
+ is capped at 4 MB and the decoder at 4 MP / 12 MB of scratch. The helper
|
|
|
+ is stopped when the window loses focus, so its TCP socket does not pause
|
|
|
+ the net-dev watcher.
|
|
|
|
|
|
No WebSocket: the open conversation is polled every 2 s (5 s
|
|
|
unfocused), the directory every 12 s (20 s), polling waits 1 s after
|
|
|
@@ -1550,9 +1673,16 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
the LZ77 history, and one checksum pass at the end (the 3.7 MB pack went
|
|
|
from ~1.1 s to ~0.25 s in QEMU). The streaming API (`inflate_gzip`
|
|
|
with a source/sink and progress hook) keeps the bit-at-a-time decoder. `img_sniff()` is a
|
|
|
- cheap header probe; `img_decode()` returns `struct img_image`; `img_draw()`
|
|
|
+ cheap header probe; `img_decode()` returns `struct img_image`; its
|
|
|
+ `struct img_options` carries `max_pixels` and optional `max_w`/`max_h`
|
|
|
+ output bounds. JPEG honours the bounds with a scaled IDCT (1/2 4x4,
|
|
|
+ 1/4 2x2, 1/8 1x1, Loeffler/IGJ); other codecs ignore them and the caller
|
|
|
+ scales with `img_draw()`. The 4x4/2x2 paths are validated by
|
|
|
+ `test_jpeg_scaled()` against a box-filtered full decode. `img_draw()`
|
|
|
is a clipped, scaled (box-filter down, bilinear up) RGB565 blit with alpha
|
|
|
- over a checkerboard or over the destination (for the browser and chat). Progressive
|
|
|
+ over a checkerboard or over the destination (for the browser and chat),
|
|
|
+ with a straight row copy for a 1:1 opaque source and an integer 5/6/5
|
|
|
+ blend for a 1:1 alpha source. Progressive
|
|
|
JPEG (successive approximation), EXIF orientation, ICO/CUR, PAM, SVG
|
|
|
files in the browser (an SVG body is parsed into a detached subtree of
|
|
|
the page and drawn by the inline-SVG renderer into an RGB565 + alpha
|
|
|
@@ -1563,7 +1693,8 @@ it to `0x7E00`. The kernel region itself only has one wall (`_end` below
|
|
|
`SYS_READ_FILE`; it uses fit/1:1/zoom/pan, shows format/dimensions/size,
|
|
|
animates GIFs, and gives a clear error for unsupported variants. The chat
|
|
|
client decodes fetched message images and avatars into a 480x320 / 32x32
|
|
|
- cache and draws them with `img_draw()`. Host
|
|
|
+ cache (passing those bounds to `img_options.max_w/h`) and draws them with
|
|
|
+ `img_draw()`. Host
|
|
|
tests: `make test-images` (`img_test.c`, corpus in `testdata/images/`,
|
|
|
generator `tools/gen_img_tests.py`).
|
|
|
- **Network service**: `sys_net.c/h` — the NIC and the stack stay in the
|
|
|
@@ -1641,7 +1772,7 @@ TX/RX self-test), `netreset`
|
|
|
set the resolver) and `host <name>` (one DNS A query). `curl <url>` fetches
|
|
|
`http://` or `https:// host[:port]/path` with a minimal HTTP GET and dumps the
|
|
|
status line, headers and body (redirects are followed, up to 5 hops; numeric
|
|
|
-hosts skip DNS). `https` uses the phase-A TLS 1.3 client (no certificate
|
|
|
+hosts skip DNS). `https` uses the phase-A TLS 1.3/1.2 client (no certificate
|
|
|
verification; the leaf fingerprint is printed). On
|
|
|
boot, if a NIC is present, a DHCP client runs with a 4 s budget (requesting the
|
|
|
current address) and falls back to the static default when no server answers.
|
|
|
@@ -1832,7 +1963,14 @@ UHCI, OHCI and xHCI. A machine with EHCI and UHCI/OHCI companions therefore
|
|
|
enumerates high-speed devices on EHCI and low/full-speed devices on the
|
|
|
companions; a port reset hands a non-high-speed device back to its companion
|
|
|
before the companion is scanned. A single device address is per-controller,
|
|
|
-so addresses do not collide.
|
|
|
+so addresses do not collide. The first `SET_ADDRESS`/`GET_DESCRIPTOR` uses
|
|
|
+the USB default 8-byte EP0; the descriptor's real `bMaxPacketSize0` is
|
|
|
+adopted afterwards (a full-speed device may have an 8-byte EP0, and the old
|
|
|
+64-byte guess made the 970A's OHCI drop the mouse). A failed port
|
|
|
+enumeration is retried up to three times with a fresh port reset and a
|
|
|
+20 ms settle, and the boot scan gives OHCI a second pass 60 ms after the
|
|
|
+EHCI-first walk, because the EHCI handback can leave a companion port
|
|
|
+briefly reporting disconnected.
|
|
|
|
|
|
- **EHCI**: MMIO BAR0, page-allocated frame list/QH/qTD/bounce buffers, QH/
|
|
|
qTD descriptors in the identity-mapped kernel space. Control, bulk and
|
|
|
@@ -1866,15 +2004,29 @@ so addresses do not collide.
|
|
|
list (`HcControlHeadED` + CLF) and are polled via each TD's condition code
|
|
|
— a NAKed TD stays queued and is retried by the controller. Both HID EDs
|
|
|
(F = 0) are chained and referenced from all 32 HCCA interrupt-table slots,
|
|
|
- so their TDs are serviced every frame. No IRQs and no DoneHead handling:
|
|
|
- software just harvests retired TDs. **TDs must be initialized with
|
|
|
+ so their TDs are serviced every frame. No IRQs: software harvests retired
|
|
|
+ TDs and acknowledges `WDH` (`HcInterruptStatus` + HCCA DoneHead) each pass.
|
|
|
+ The ED/TD/setup and interrupt-buffer structures live in the dedicated
|
|
|
+ `ohci_dma_page`, mapped uncacheable by `paging_init()` (PDE 0 is split
|
|
|
+ before paging is enabled). The SB950's legacy OHCI DMA does not snoop
|
|
|
+ dirty CPU lines: without the uncached page the controller sometimes read
|
|
|
+ an empty ED, skipped the transfer and never re-armed the endpoint (the
|
|
|
+ mouse cursor froze with no error). Control transfers still use `wbinvd`
|
|
|
+ around their caller-supplied data buffers, which remain write-back.
|
|
|
+ **TDs must be initialized with
|
|
|
CC = NotAccessed (0xF)** — OHCI has no active bit, and a zero CC makes
|
|
|
software think a fresh TD already completed. TD data toggles are explicit:
|
|
|
DATA0 = `0x02000000`, DATA1 = `0x03000000` (`0` means "use the ED carry
|
|
|
bit"); a wrong value makes the first control transfer fail with a toggle
|
|
|
mismatch on real hardware while QEMU (which ignores toggles) is happy.
|
|
|
Control queues use a dummy TD as the tail anchor; the data stage is one
|
|
|
- TD (the controller splits it into MPS-sized packets itself).
|
|
|
+ TD (the controller splits it into MPS-sized packets itself). Before the
|
|
|
+ first reset, if `HcControl.IR` says the SMM owns the controller, the driver
|
|
|
+ requests ownership (`HcCommandStatus.OCR`, clear `HcControl.IR`) with a
|
|
|
+ bounded 200 ms wait. On AMD SB600/SB700/SB800/SB950 it also clears the
|
|
|
+ southbridge USB SMI enable (SMBus device `1002:4385`, config `0x64` bit
|
|
|
+ 15) once, so the firmware cannot take the OHCI ports back after handoff.
|
|
|
+ Both are no-ops on Intel/QEMU.
|
|
|
- **UHCI**: I/O ports, frame list at `0x3000`, control QH + two more QHs
|
|
|
(one per interrupt slot) serviced every frame while the controller keeps
|
|
|
running. The PCI scan checks **all functions** (real PIIX3/PIIX4/VIA
|
|
|
@@ -1953,10 +2105,15 @@ so addresses do not collide.
|
|
|
(500 ms delay, 33 ms rate) for the last make code; real PS/2 hardware
|
|
|
repeat keeps resetting the same timer.
|
|
|
`usbhid_poll()` (from `mouse_poll_update()`) also runs the hotplug
|
|
|
- watcher: root-port connect changes are enumerated (throttled to 250 ms),
|
|
|
- `CCS` low or a few TD errors detach a device. A full scan (`lsusb`) bumps
|
|
|
- `usb_generation()`, which makes `usbhid` detach and rescan, so `lsusb`
|
|
|
- can't leave the devices dead. The BIOS PS/2 legacy emulation is
|
|
|
+ watcher: root-port connect changes are enumerated (throttled to 250 ms).
|
|
|
+ A port read must report disconnected three times in a row before the
|
|
|
+ device is detached, and the TD error threshold is 50, so a single CCS
|
|
|
+ glitch or a short low-speed error burst cannot kill a working device.
|
|
|
+ Any detach sets `need_rescan`, which runs a clean full `usb_scan` from the
|
|
|
+ watcher: a false port-loss leaves no CSC to wake the per-port path, so
|
|
|
+ this is the only reliable recovery on the SB950. A full scan (`lsusb`)
|
|
|
+ also bumps `usb_generation()`, which makes `usbhid` detach and rescan, so
|
|
|
+ `lsusb` can't leave the devices dead. The BIOS PS/2 legacy emulation is
|
|
|
deliberately disabled (PCI config `0xC0`) because the kernel now owns
|
|
|
these devices.
|
|
|
- **Debug**: `ohci:` / `uhci:` / `ehci:` / `usbhid:` lines go to COM1 (and
|
|
|
@@ -2126,8 +2283,14 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
|
|
|
## Known issues (candidates for future tasks)
|
|
|
|
|
|
-1. `serial_puthex` (`serial.c`) uses `"01234589ABCDEF"` — digits **6 and 7 are
|
|
|
- missing** (bug).
|
|
|
+1. `power.c` still has no AMD P-state path. The FX-6350 (family 15h model 2)
|
|
|
+ runs at the BIOS P0 and `power`/`cpufreq` report unsupported; the CPU
|
|
|
+ temperature is supported through `D18F3xA4`. A minimal family-15h
|
|
|
+ governor would read `MSRC001_0064..006B` (COF = `100 * (FID + 0x10) >>
|
|
|
+ DID`) and write the 3-bit index to `MSRC001_0062`, but it is not required
|
|
|
+ for boot or the desktop. The AMD WC MTRR path is supported through the
|
|
|
+ separate free-entry/zero-high-mask path described above; the Intel/ION WC
|
|
|
+ paths are unchanged.
|
|
|
2. `vga.c` `draw_flush_debug_square()` — leftover debug artifact, still draws a
|
|
|
color-cycling 32×32 square in the corner on every flush.
|
|
|
3. No per-process address spaces or process isolation (paging is identity-mapped).
|
|
|
@@ -2152,7 +2315,7 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
with `--gc-sections`; the current full pack with the UI fonts, both
|
|
|
WiFi firmwares (7265D 1,036,312 bytes, ~442 KiB gzip; 6000 454,608 bytes,
|
|
|
~204 KiB gzip), the RTL8821A firmware and tables (31,898 + 11,668
|
|
|
- bytes) and `install/kernel.bin` is ~1.75 MiB gzip (~260 KB under the
|
|
|
+ bytes) and `install/kernel.bin` is ~1.88 MiB gzip (~120 KB under the
|
|
|
cap), inflating to ~3.6 MB, which adds about
|
|
|
half a second to the boot; the floppy lite pack is ~930 KiB gzip and
|
|
|
deliberately omits the firmware and `install/kernel.bin`. `libdeflate-gzip -12` is still preferred. Over
|
|
|
@@ -2162,8 +2325,11 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
board that exposes only MP tables stays UP (deliberate; there is no test
|
|
|
hardware).
|
|
|
10. There is no IOAPIC driver. The BSP keeps the 8259 PIC in LAPIC ExtINT mode;
|
|
|
- APs mask LINT0/LINT1 and only use their LAPIC timer/IPIs. Device IRQs never
|
|
|
- reach an AP, and `pit_irq_stub` should be treated as BSP-only.
|
|
|
+ after ACPI init, `ioapic_mask_all()` masks every normal IOAPIC redirection
|
|
|
+ entry (ExtINT entries are left alone in case the 8259 is routed through an
|
|
|
+ IOAPIC pin). APs mask LINT0/LINT1 and only use their LAPIC timer/IPIs.
|
|
|
+ Device IRQs never reach an AP, and `pit_irq_stub` should be treated as
|
|
|
+ BSP-only.
|
|
|
11. The BKL serializes all kernel execution: a long FAT/disk operation, a
|
|
|
non-network driver wait or a big shadow-buffer operation can stall syscalls
|
|
|
on the other CPUs for its duration. `bkl_pause()`/`bkl_resume()` is used
|
|
|
@@ -2183,10 +2349,15 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
whole file is read into memory (4 MB cap in the viewer) and very large
|
|
|
photos still need DCT-scaled/streamed decode before they fit the 64 MB
|
|
|
arena.
|
|
|
-15. `img_draw()`'s box-filter downscale runs on the CPU. It is fine for the
|
|
|
- viewer's static frames, but a browser showing many large inline images
|
|
|
- should cache a scaled bitmap (or use decode-at-display-scale) instead of
|
|
|
- rescaling on every repaint.
|
|
|
+15. `img_draw()`'s box-filter downscale runs on the CPU. The browser now
|
|
|
+ caches a display-size bitmap per image (`br_image.disp`) and paints 1:1;
|
|
|
+ remote `<img>` decodes in the warm `curl __serve` helper at the CSS box
|
|
|
+ (the UI only reads the published RGB565+alpha bitmap), so the UI thread
|
|
|
+ no longer runs the IDCT. Local images and backgrounds still decode
|
|
|
+ in-process; the viewer caches one image at its window size, and chat
|
|
|
+ caches 480x320/32x32 bitmaps. The in-process paths are still limited by
|
|
|
+ the full-size `img_estimate()` arena (24 MB browser, 12 MB chat), so an
|
|
|
+ image above the arena cap is rejected before the reduced decode runs.
|
|
|
16. `files` recognises images by file extension only (`.png .jpg .jpeg .gif
|
|
|
.bmp .tga .ppm .pgm .pbm .ico .cur .pam`); a magic-based fallback would
|
|
|
also open extensionless files in the viewer. Automatic decode-at-scale
|
|
|
@@ -2215,9 +2386,10 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
(8 slots x 1 KB), and the FAT listing cache another 5 KB. The command
|
|
|
pack is out of the kernel now; after the WiFi/netmenu/install code and the
|
|
|
per-connection TCP queues moved to the frame allocator, `_end` is
|
|
|
- ~0x897a0 (with the 6200/6300 DVM layer, the RTL8821AU driver and the
|
|
|
- 8×16 boot-console font), ~26 KB below the `0x90000` wall, and the
|
|
|
- remaining limit is kernel code/buffers only.
|
|
|
+ ~0x8a440 (with the 6200/6300 DVM layer, the RTL8821AU driver, the
|
|
|
+ 8×16 boot-console font, the IOAPIC/AMD-thermal additions and the safe
|
|
|
+ AMD MTRR path), ~23 KB below the `0x90000` wall, and the remaining limit
|
|
|
+ is kernel code/buffers only.
|
|
|
|
|
|
22. Browser limits: JavaScript runs inline and external classic scripts on
|
|
|
QuickJS (ES2025) with the DOM surface described above (creation/mutation/selectors/
|
|
|
@@ -2240,9 +2412,12 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
weak Math.random/clock mix (fine for PKCE nonces, like the TLS DRBG).
|
|
|
On QEMU's NE2000 the four parallel module downloads can overrun its
|
|
|
small RX ring and stall TLS handshakes into a 10 s timeout; use e1000.
|
|
|
- Also missing: `defer`/`async` ordering, `DOMParser`/
|
|
|
- `document.implementation.createDocument` (DOMPurify throws, so the
|
|
|
- Cloudron login footer is not rendered), canvas/2D contexts, user-state
|
|
|
+ `DOMParser` and `document.implementation.createHTMLDocument` return an
|
|
|
+ inert detached document (its nodes live in the page arena; markup goes
|
|
|
+ through the innerHTML fragment parser, head elements included), which is
|
|
|
+ enough for jQuery's probe and parseHTML but not a separate XML parser.
|
|
|
+ Also missing: `defer`/`async` ordering,
|
|
|
+ `document.implementation.createDocument`, canvas/2D contexts, user-state
|
|
|
pseudo-classes (`:hover`, `:focus`, ...), `:nth-child(... of S)` and
|
|
|
pseudo-elements other than `::before`/`::after`; generated content is
|
|
|
text only (no box, background, counters or `url()` images, and
|
|
|
@@ -2269,7 +2444,8 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
minimum since there are no scrollable inner boxes, and auto when the
|
|
|
containing height is indefinite -- they used to resolve against the
|
|
|
width), flex rows with wrap/grow/gap/justify/
|
|
|
- align, two-track and `repeat(auto-fit, minmax(...))` grids, inline-block
|
|
|
+ align, two-track, `repeat(N, 1fr)` and `repeat(auto-fit, minmax(...))`
|
|
|
+ grids (no `grid-column` spans), `aspect-ratio`, inline-block
|
|
|
runs, basic proportional table columns, table rowspan/colspan/percentage
|
|
|
columns and inline SVG (filled/stroked geometry, `use`/`symbol`,
|
|
|
transforms; gradients, patterns, clip paths, masks, filters, markers and
|
|
|
@@ -2308,12 +2484,20 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
the installed faces, and the `font` shorthand does not resolve a custom
|
|
|
family (use `font-family`).
|
|
|
Pages that need multi-row grid templates, `color-mix()` or full
|
|
|
- transforms can still lay out imperfectly. Images are decoded into a per-image `img_estimate()`-sized
|
|
|
- arena (reused per page) and kept as a box-sized display bitmap (256
|
|
|
- images within a 4 M-pixel budget, 512 KB files / 8 MP decodes); large
|
|
|
- screenshots still need a multi-megabyte decode arena that can fail on a
|
|
|
- fragmented heap, and the scaled bitmaps live until navigation. `img_draw` rescales the
|
|
|
- cached bitmap on every repaint. Lazy
|
|
|
+ transforms can still lay out imperfectly. Remote `<img>` decodes in the
|
|
|
+ fetch helper at its CSS/attribute box (the helper request carries
|
|
|
+ `D <max_w> <max_h>` and publishes an RGB565+alpha bitmap), so the UI
|
|
|
+ only reads it; local images and backgrounds use a per-image
|
|
|
+ `img_estimate()`-sized arena in-process (`<img>` passes its box through
|
|
|
+ `img_options.max_w/h`, backgrounds decode at their box), and the browser
|
|
|
+ keeps a lazily built display-size bitmap (`br_image.disp`) for 1:1
|
|
|
+ repaints (256 source images within a 4 M-pixel budget plus a 6 M-pixel
|
|
|
+ display-cache budget, 1 MB files / 8 MP decodes). The in-process
|
|
|
+ paths still size the arena for the full image, so a very large local or
|
|
|
+ background photo can fail the 24 MB cap before the reduced decode runs;
|
|
|
+ the scaled bitmaps live until navigation. Image repaints are coalesced
|
|
|
+ (100 ms) and jobs decode in 40 ms batches; `/share/IMGSTAT` records
|
|
|
+ net/io/dec/scale/paint/reflow. Lazy
|
|
|
image loading uses the last measured positions; adding an image can
|
|
|
reflow the content above it, and images below the viewport stay as
|
|
|
`[image]` until scrolled into range. The browser keeps up to four
|
|
|
@@ -2337,18 +2521,23 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
|
|
|
23. UEFI boot is x86-64 firmware only (no `BOOTIA32.EFI` yet) and the loader
|
|
|
is unsigned, so Secure Boot must be off. The loader needs a GOP mode with
|
|
|
- BGRX or RGBX 32bpp, width ≤ 1280, `pitch * height` ≤ 8 MB and the
|
|
|
- framebuffer below 4 GB; otherwise the kernel starts headless (serial only).
|
|
|
+ BGRX or RGBX 32bpp, width ≤ 1920, `pitch * height` ≤ 8 MB (1920x1080
|
|
|
+ fits at 8.29 MB) and the framebuffer below 4 GB; otherwise the kernel
|
|
|
+ starts headless (serial only). The same 2 M-pixel cap keeps a
|
|
|
+ full-screen RGB565 canvas inside the 4 MB window slot.
|
|
|
xHCI drives USB2 and USB3 root ports (USB3 hubs are not decoded), and
|
|
|
EHCI only high-speed root ports (no transaction translator for
|
|
|
low/full-speed devices behind a high-speed hub), so a full-speed device
|
|
|
behind a USB2 hub can still leave the UI without input (PS/2 may still
|
|
|
work).
|
|
|
- There is no IOAPIC setup: OVMF delivers the ISA IRQs through the 8259
|
|
|
- path, but a platform that routes them through the IOAPIC may need a
|
|
|
- mask-all step after ACPI init. UEFI runtime services are not used, so
|
|
|
+ OVMF delivers the ISA IRQs through the 8259 path; the kernel nevertheless
|
|
|
+ masks the IOAPIC's normal redirection entries after ACPI init, so
|
|
|
+ firmware-left vectors cannot collide with the PIC or LAPIC timer.
|
|
|
+ UEFI runtime services are not used, so
|
|
|
`reboot`/`poweroff` still use the legacy ports. The image is 17 MB: the
|
|
|
- 9 MB kernel + rootfs disk and the 8 MB ESP.
|
|
|
+ 9 MB kernel + rootfs disk and the 8 MB ESP. Maxwell GPUs such as the
|
|
|
+ GTX 960 use the firmware VBE/GOP framebuffer only; there is no native
|
|
|
+ NVIDIA driver, and `nv50_probe()` is gated to the ION/nv50 chipsets.
|
|
|
|
|
|
24. ThinkPad EC sensor and battery access (`tpec.c`) runs in legacy/SMM mode
|
|
|
because there is no ACPI interpreter: an SMI that touches the EC between
|
|
|
@@ -2489,7 +2678,10 @@ and the WM falls back to polling (`io_keyboard_irq_masked()`).
|
|
|
render inline up to the 4 MB fetch / 4 MP decode caps (first GIF frame;
|
|
|
WebP/AVIF/SVG are not decoded), file attachments are still text-only,
|
|
|
messages over 4 KB are truncated, history holds 240 messages, times are
|
|
|
- UTC and text is Latin-1. Network calls block the UI for their duration.
|
|
|
+ UTC and text is Latin-1. REST calls still block the UI for their
|
|
|
+ duration; message images decode in the `curl __serve` helper (480x320
|
|
|
+ bounds) and chat only copies the bitmap, while avatars decode on the
|
|
|
+ chat thread at 32x32.
|
|
|
|
|
|
35. WiFi limits (`iwl_trans.c`, `iwl_mvm.c`, `iwl_dvm.c`, `wifi.c`): Intel
|
|
|
7265 rev D/3165 (`iwlwifi-7265D-29`) and 6200/6300 (`iwlwifi-6000-4`)
|