Repository navigation
Conversation
|
Looks right. Two small things:
Assisted-by: LLM (Claude:Opus 5.5) |
|
Assisted-by: LLM (Claude:Opus 5.5) |
|
Thanks, all three in 974032a:
AI-assisted (Assisted-by: LLM). |
|
Re-review of 974032a: Blockers: 1. From our last comments:
New:
HW row: J704 (macOS 27.2 stub, 26B123) booted on 974032a with no Assisted-by: LLM (Claude:Opus 5.5) |
|
Merge-train adversarial review (MERGETRAIN-LINUX2) at 974032a: NO BLOCKERS. Code read only, nothing built here. Before the merge it still needs Dj's verdict at this head; the missing rows are listed below. Full review#2585 drm/asahi: g17: Log an unsupported firmware build only when none matches @974032a4VERDICT: NO BLOCKERS Checked on the merge (drivers/gpu/drm/asahi/g17/mod.rs merged :1882-1966, fwid.rs):
Nits:
Missing rows:
|
DjDeveloperr
left a comment
There was a problem hiding this comment.
Pre-PR checklist review at 974032a49058: 1 blocker (§4 attribution), plus §5 evidence gap on the live head.
Code and Safety Audit (§1–§3, §6)
- Clean functionally. Verified against
drivers/gpu/drm/asahi/fwid.rs(digest_at()restores in-place zeroed entropy bytes and uses a separateKVVeccopy whenboot_filledis non-empty, and returnsNonebefore mutating on record-validation failure), so reusing a singleMeasuredacross candidate builds is sound. fwid::identify()remains used bydrivers/gpu/drm/asahi/g16/boot.rs:491and iscfg_attr-guarded against dead-code warnings.measure_text()logs bothEAGAINand otherfw-text/fw-dataerrors, andtools/asahi/g17-firmware-selection-tests.pymatches the newBuild::images/Measuredshape and type-checks thedev_info!/dev_err!format strings.- CI:
host-testsis green.
Blockers
- §4 commit trailers: Both commits (
876c53cc5d70,974032a49058) include anAssisted-by: LLMtrailer in the commit message. Per §4 of the pre-PR checklist, commits must carry human author/committer identity and humanSigned-off-by:only, with zeroAssisted-by:or AI trailers in commit messages (disclosure stays in the PR body only).
Non-blocking Nits
drivers/gpu/drm/asahi/g17/mod.rs:1927:core::ptr::eq(seen, image)relies onconst-promoted slices fromBUILD_25G83/BUILD_26B123(hw/t6041.rs:75-196) sharing an address across uses, which Rust does not guarantee forconst(unlikestatic). Comparing(seen.name, seen.text_sha256)(or promoting shared image arrays tostatic) would make deduplication guaranteed.drivers/gpu/drm/asahi/g17/mod.rs:1902:GPU firmware build: {}is logged before thecore_layout.corescheck, so a shared image whose first matching build doesn't admit the probed core layout logs that line twice; logging it at:1916alongsideGPU firmware: {}would avoid the duplicate.drivers/gpu/drm/asahi/g17/mod.rs:1896:Self::measure_text(dev)?now propagates measurement errors (EAGAIN/EINVAL/ENOMEM) directly instead of continuing and returningENODEV(and no longer re-measures on a transientEAGAIN). This is reasonable and logged; worth mentioning in the commit message when dropping the commit trailers.
§5 Evidence Needed on Live Head
- Re-prove on J704 (macOS 27.2 / 26B123, no
apple,firmware-version) at the updated head (the 5-boot row predates974032a4) showing onlyGPU firmware build:/GPU firmware:, desktop on GPU, and the regression row (0 SELinux denials, 0 failed units, 0 new kernel errors). - Ideally also one boot on another
Firmware::IdentifiedMac (T6040/T6041/T6050) taking the single-measurement path.
Assisted-by: LLM (Gemini 4 Neon)
firmware_variant() tries the identified builds in turn, the one the boot loader's apple,firmware-version names first. Each try measured the loaded TEXT again and, when it was not that build, logged "unsupported GPU firmware build", the build it was not, and "GPU firmware image not admitted: EINVAL", even when a later build then matched. Without apple,firmware-version (the installed aura does not write it on T8142), an M5 on macOS 27.2 logs three such errors for the 26A428 build before it admits 26B123. Measure the TEXT once and try each build against that measurement (Measured::find, which leaves the copy as it found it). Only when no build matches, log the measured identity and every supported build, before the existing "Unsupported GPU firmware image" line. A matched build still logs "GPU firmware build: ...". The TEXT is now copied and hashed once per probe rather than once per candidate build. Signed-off-by: termg <hello@termg.com>
…hared measurement Follow-ups to "Log an unsupported firmware build only when none matches": - measure_text() logged only EAGAIN. A missing fw-text or fw-data region (a DT or boot loader mismatch) now returned from the probe silently, where before it printed "GPU firmware image not admitted". Log every other error too. - A measurement error (EAGAIN, ENOMEM, EINVAL) now ends the probe with that error, where before each candidate build measured again and the probe ended with ENODEV after "Unsupported GPU firmware image". So a transient EAGAIN (TEXT changed between the two copies) is no longer retried by the next candidate; it is logged instead. - "GPU firmware build: <image>" is logged once, for the build that is taken, next to "GPU firmware: <build>". It was logged for every build whose image matched, so an image shared by a build whose configuration does not admit the probed cores logged it twice. - The "supported:" list walked every build's images, so an image shared by builds that differ only in their core layout (as T6041 25G83 is) was listed once per build. List each image once, comparing name and TEXT digest: the address of a const-promoted entry is not guaranteed to be shared. - g17-firmware-selection-tests.py compiles firmware_variant() against stub types, and its Build stub still had a single `image` with an identify_image() stub, so the host test stopped building (E0609 "no field images"). Model the new shape instead: Build::images, a stub measure_text() and a Measured whose find() records each image it is tried against, so the existing checks on the order of the candidates still hold. The stub dev_info!/dev_err! now build their messages, so the log lines are type-checked as well. Signed-off-by: termg <hello@termg.com>
974032a to
313c264
Compare
J704 (macOS 27.2 / 26B123 stub, no The same boot with the module without this PR logs I have no T6040/T6041/T6050 Mac, so the other Assisted-by: LLM (Claude:Opus 5.5) |
|
Re-checked at 313c264 (range-diff against 974032a). The
No code concerns from my side. What is left is a fresh run at this head, since the log path changed: the host test ( Assisted-by: LLM (Claude:Opus 5.5) |
|
Both are in now. CI Assisted-by: LLM (Claude:Opus 5.5) |
RyanTheTide
left a comment
There was a problem hiding this comment.
Approved at 313c264: host-tests green incl. g17-firmware-selection; J704 boot logs one 'GPU firmware build:' line, no unsupported/not-measured lines.
|
@DjDeveloperr could you re-review at Assisted-by: LLM (Claude:Opus 5.5) |
DjDeveloperr
left a comment
There was a problem hiding this comment.
Re-review at 313c264eb802 against the pre-PR checklist (§1–§6) and live integration/aurora (70a00e583b03): 0 blockers — approved.
Verified
- §1–§3 (Correctness, safety, no model gating): Clean.
firmware_variant()measures loaded TEXT once viaSelf::measure_text(dev)?and reusesMeasuredacross candidate builds viaMeasured::find()(verifiedfwid.rs:100-140restores in-place zeroed entropy bytes and hashes a separate copy whenboot_filledis non-empty).GPU firmware build:is logged once on the selected(build, image)pair; the no-matchsupported:list deduplicates by(name, text_sha256)rather than pointer identity;measure_text()logs bothEAGAINand otherfw-text/fw-dataerrors; andtools/asahi/g17-firmware-selection-tests.pymatchesBuild::images/Measuredand type-checks the log format strings. Not superseded onintegration/aurora. - §4 (Attribution & clean-room): Resolved. Both commits (
45f238024b4c,313c264eb802) carry human author/committer and humanSigned-off-by:only, with zero AI trailers in commits; disclosure is in the PR body. - §5 (Evidence): Exact-head J704 boot (macOS 27.2 / 26B123 stub, no
apple,firmware-version) confirms onlyGPU firmware build:/GPU firmware:are logged, KWin runs onrenderD128without GPU faults, and0 SELinux denials, 0 failed units, 0 new kernel errors; otherFirmware::Identifiedplatforms (T6040/T6041/T6050) are noted for owners who have that hardware. - §6 (Naming & live CI): Clean. Live CI
host-testsis green (run/45083862624).
Assisted-by: LLM (Gemini 4 Neon)
Problem
firmware_variant()tries each identified build in turn. Each try measured the loaded TEXT again, and a build that did not match loggedunsupported GPU firmware build,supported: <that build>andGPU firmware image not admitted: EINVAL, even when the next build matched. With noapple,firmware-versionon the GPU node (the installed aura doesn't write one on T8142), an M5 on macOS 27.2 logs those three errors for 26A428 before it admits 26B123. Raised on linux#2093.Change
Measured::find, which leaves the copy as it was.Unsupported GPU firmware imageline.GPU firmware build: ....Testing
Mac17,2 J704 on the macOS 27.2 (26B123) stub, with #2093 (f41fdbe) underneath, five boots. Before, the probe logged:
With this change:
Both roles acknowledged their InitData, and KDE ran on the GPU. The no-match path was checked by reading the code only.
Assisted-by: LLM (Claude:Opus 5.5)