Skip to content

T1: expand runtime-ephemeral mask — DIG IGI + IQK outputs#75

Merged
josephnef merged 1 commit into
masterfrom
t1-canary-mask-expand
Jun 2, 2026
Merged

T1: expand runtime-ephemeral mask — DIG IGI + IQK outputs#75
josephnef merged 1 commit into
masterfrom
t1-canary-mask-expand

Conversation

@josephnef
Copy link
Copy Markdown
Collaborator

Summary

Closes the remaining post-init canary divergence clusters that aren't init drift — DIG runtime updates and IQK calibration outputs — so a clean canary diff actually means "nothing is off."

New mask entries

DIG IGI — bits 7:0 of the path AGC core word

  • BB 0xc50 (path A), 0xe50 (path B), 0x1850 (path C, 8814), 0x1a50 (path D, 8814)
  • Mask: 0x000000FF per register

The kernel's phydm DIG watchdog walks the per-path IGI value continuously based on RX noise floor. Devourer writes the 0x1c floor once at init (HalModule::phydm_SetIgiFloor_Jaguar) and leaves it. Upper bits of the AGC core word are static config and stay diffed.

IQK output coefficients — full word

  • BB 0x8b0
  • BB 0xc10 / 0xc14 / 0xc90 / 0xc94 (path A)
  • BB 0xe10 / 0xe14 / 0xe90 / 0xe94 (path B)
  • Mask: 0xFFFFFFFF per register

Both kernel and devourer run IQK after the port (Iqk8812a / Iqk8821a), but the tone-calibration sweep samples a noisy signal so the per-bit output varies between runs even on the same chip. Functional IQK correctness is validated by the on-air RX/TX matrix in tests/regress.py, not by bit-exact canary diff.

Escape hatch

--strict continues to bypass every mask, so replay testing or bit-exact debugging can still opt in.

Test plan

  • python3 -m pytest tests/test_canary_diff.py -v — 17 / 17 passing locally (was 13)
  • New tests: test_dig_igi_byte0_masked, test_dig_igi_upper_bits_still_diffed, test_iqk_output_regs_masked, test_iqk_output_unmasked_under_strict
  • Hosted CI green on the Canary diff unit tests job

Closes the remaining post-init canary divergence clusters that
aren't init drift:

  - BB 0xc50 / 0xe50 / 0x1850 / 0x1a50 byte 0 — DIG IGI for
    paths A/B/C/D. The kernel's phydm DIG watchdog walks the
    IGI value continuously based on RX noise floor; devourer
    writes the 0x1c floor once at init. Upper bits of the AGC
    core word stay diffed.
  - BB 0x8b0, 0xc10/0xc14/0xc90/0xc94 (+ path-B mirrors at
    0xe10/0xe14/0xe90/0xe94) — IQK output coefficients. Both
    sides run IQK but the tone sweep samples a noisy signal so
    the per-bit output varies between runs even on the same
    chip. Functional IQK correctness is checked by the on-air
    RX/TX matrix, not by canary diff.

`--strict` still bypasses every mask for replay/bit-exact
debugging. Test suite grows from 13 to 17 cases covering the
new mask entries.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@josephnef josephnef merged commit ac11213 into master Jun 2, 2026
6 checks passed
@josephnef josephnef deleted the t1-canary-mask-expand branch June 2, 2026 19:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant