Skip to content

Commit fa3c69f

Browse files
committed
docs: extend architectural requirements with IEEE 802.11 rules, composition, and workflow
Based on the requirements guide at mgonzalezlopezudc/inet reports/inet-architectural-requirements-guide.md: - ieee80211-architectural-requirements.md: 14 AR-WLAN-* requirements specializing the general architecture for the 802.11 subtrees (standard traceability and capability gating, component boundaries and state ownership, variant isolation, typed frame representation, PHY mode/timing authority, explicit frame-exchange state machines, shared sequence/Block Ack rules, EDCA single definition, MU plan/PPDU split, owner-emitted events, focused tests + legacy regressions), with their own synergy analysis and enforcement map - enforcement/ieee80211-agent-review-checklist.md: T4 checklist for the WLAN rules, applied in addition to the general checklist - architectural-requirements.md: new 'How the requirements compose' section naming the seven emergent properties the rules jointly produce, new 'Contributor workflow' section (8-step design-map loop tying in sealing, ledgers, and enforcement), and a cross-reference to the domain-specific extension file
1 parent d8d8dea commit fa3c69f

4 files changed

Lines changed: 441 additions & 1 deletion

File tree

doc/architecture/architectural-requirements.md

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ user*, while these say *how the code base must be structured* to make that possi
1212
to keep it sustainable. They are distilled from the INET Developer's Guide and from
1313
recurring lessons in day-to-day INET/OMNeT++ development.
1414

15+
Domain-specific extensions refine these rules where one protocol family concentrates extra
16+
risk; the first is
17+
[ieee80211-architectural-requirements.md](ieee80211-architectural-requirements.md), whose
18+
`AR-WLAN-*` rules apply in addition to everything here under the IEEE 802.11 subtrees.
19+
1520
## Code Organization (AR-ORG)
1621

1722
### AR-ORG-DOMAINS — Layered, domain-partitioned source tree with acyclic dependencies
@@ -581,6 +586,64 @@ declaration — are enforceable by an **agent reviewer** run as a CI gate, leavi
581586
judgment (is a fidelity level worth adding?) to a human. The enforcement status of each requirement
582587
is tracked in the map below.
583588

589+
## How the requirements compose
590+
591+
The requirements above are not independent style preferences; they form a network of mutually
592+
reinforcing constraints, and their aggregate effect is larger than any rule alone. Seven compound
593+
properties are the actual goal — each names the requirements that jointly produce it, which is also
594+
a review aid: a change that weakens one rule usually attacks one of these properties, and the
595+
property says what else to check.
596+
597+
**A contract graph instead of a dependency tangle.** AR-ORG-DOMAINS, AR-ORG-CONTRACTS,
598+
AR-MOD-COMPOSITION, AR-MOD-PLUGGABLE, AR-COM-REGISTRY, AR-COM-DISPATCH, AR-EXT-NOCORE, and
599+
AR-EXT-ATTACH together produce *structural substitutability*: a component is replaceable not merely
600+
because an interface exists, but because its slot is interface-typed, its service is discoverable
601+
at runtime, its packet identity is explicit, and the core never learns its concrete type. This
602+
combination is what makes adding a protocol an extension rather than a central-core edit.
603+
604+
**A truthful data path from model to wire to evidence.** AR-PKT-CHUNKS, AR-PKT-DUAL, AR-PKT-TAGS,
605+
AR-PKT-ERRORS, AR-PKT-SIGNAL, AR-OBS-INTROSPECTION, and AR-OBS-FLOWS partition information by what
606+
it *is* — typed content is what the packet carries, tags are local metadata, Signals are physical
607+
transmissions, serializers are the wire boundary, region tags preserve identity through
608+
transformation. The emergent property is *evidentiary continuity*: a field inspected in a packet,
609+
serialized into a capture, processed by the PHY, and attributed to a flow is one representation
610+
throughout, so analysis tooling cannot report something the model did not actually represent.
611+
612+
**Composable but causally explicit behavior.** AR-COM-DIRECT, AR-LIFE-STAGES, AR-LIFE-OPERATIONS,
613+
AR-QUEUE-ROLES, and AR-QUEUE-STREAMING each put internal cooperation at its right semantic level:
614+
direct calls for same-instant coordination, scheduled messages for genuine events, stages for
615+
initialization order, queueing contracts for datapath transfer. The result is an event trajectory
616+
that corresponds to modeled behavior rather than implementation plumbing — which is what makes
617+
debugging, performance, and fingerprint signal quality good at the same time.
618+
619+
**Observability without observer effects.** AR-ORG-VIS-SPLIT, AR-OBS-SIGNALS, AR-OBS-NED-TRUTH, and
620+
AR-OBS-INTROSPECTION establish a one-way path: model owner → declared signal → recorder, visualizer,
621+
analyzer. Consumers subscribe from the outside and events are emitted once by their owner, so
622+
recording is additive, never behavioral; NED remains the machine-readable statement of what exists.
623+
Observability becomes an external capability instead of a hidden second implementation of the model.
624+
625+
**Fidelity as a controlled dimension.** AR-MOD-FIDELITY, AR-PKT-ERRORS, AR-PKT-SIGNAL,
626+
AR-EXT-FEATURES, and AR-CFG-PARAMS let a study choose detail deliberately: a coarse error model and
627+
a detailed analog model occupy the same contractual slot, and the choice is visible in
628+
configuration. Large scenarios buy affordable abstraction, focused studies buy detail, and neither
629+
requires replacing the surrounding architecture.
630+
631+
**Reproducible rather than anecdotal correctness.** AR-CFG-INFER, AR-CFG-PARAMS, AR-BUILD-OUTOFTREE,
632+
AR-BUILD-DECLARATIVE, AR-QUAL-DETERMINISM, AR-QUAL-FINGERPRINT, AR-QUAL-TESTS, and
633+
AR-QUAL-TRACEABILITY form a chain — unambiguous configuration → isolated, discoverable build →
634+
deterministic execution → matching tests plus trajectory fingerprints → traceable baselines — in
635+
which each link removes a different source of uncertainty. A fingerprint is meaningful only on a
636+
deterministic model; a deterministic run is useful only when its inputs are known; a passing test is
637+
persuasive only when its type matches the claim and its baseline has provenance.
638+
639+
**Complexity paid once, in infrastructure.** Registries, dispatchers, serializers, signals,
640+
lifecycle protocols, queueing contracts, and feature descriptors are up-front structure whose
641+
aggregate purpose is to make the *next* model cheaper to integrate: each new protocol reuses the
642+
same extension, observation, testing, configuration, and build paths instead of carving a bespoke
643+
path through the core. The architecture has a rising initial discipline cost and a falling marginal
644+
integration cost — without it, every new feature looks locally simple while adding one more special
645+
case to dispatch, inspection, build selection, and tests.
646+
584647
## Quality attributes and enforcement
585648

586649
The requirements above are grouped by *architectural concern* — the axis a contributor uses to find
@@ -668,3 +731,32 @@ move every requirement as far up this ladder as it can go.
668731
| AR-QUAL-LOGGING | T3+T4 | `-Werror`/`clang-tidy` + agent review that programming errors throw, not log |
669732
| AR-QUAL-TRACEABILITY | T3 | fingerprint tags + source→config mapping (partial) |
670733
| AR-QUAL-ENFORCED || the CI gate set itself; measured by how many rows above reach T1–T4 (automated) |
734+
735+
## Contributor workflow
736+
737+
For a normal INET change, the requirements work as a design map rather than a reading assignment —
738+
the unit of review is not "does this patch look reasonable?" but "which architectural contracts does
739+
this patch touch, what evidence establishes compliance, and what will prevent a regression later?":
740+
741+
1. **Scope.** Identify the affected domain, contracts, module composition, packet content, tags,
742+
configuration surface, observability, build feature, and test coverage.
743+
2. **Seals.** If the change is under `src/inet/`, resolve exact and ancestor-directory seals first
744+
(see [sealing.md](sealing.md)) — a sealed path needs explicit permission before anything else.
745+
3. **Applicable rules.** Read only the requirement sections that apply (including the
746+
[IEEE 802.11 extensions](ieee80211-architectural-requirements.md) when in scope), plus both
747+
exception ledgers and [naming-conventions.md](naming-conventions.md) for every new or renamed
748+
artifact.
749+
4. **Smallest surface.** Establish state ownership and the smallest change surface before editing;
750+
prefer the smallest change that satisfies the contracts, ownership, observability,
751+
configuration, determinism, and testing requirements.
752+
5. **Existing mechanisms.** Implement through existing contracts, registries, signals, serializers,
753+
lifecycle APIs, and feature descriptors before inventing a new mechanism.
754+
6. **Validate in proportion to risk.** Run [enforcement/check-architecture.sh](enforcement/check-architecture.sh)
755+
(scoped to the touched subtree for focused work) and the test categories matching the claim;
756+
preserve the exact commands, configurations, and statuses for review.
757+
7. **Reconcile, don't re-litigate.** Record only genuinely new deviations as `AV-*`/`NV-*` ledger
758+
rows; deviations already in [architecture-exceptions.md](architecture-exceptions.md) or
759+
[naming-exceptions.md](naming-exceptions.md) are known, not findings. Fingerprint baselines
760+
change only with explicit approval and a reviewable explanation (AR-QUAL-TRACEABILITY).
761+
8. **Sealing last.** Sealing is the terminal state of this pipeline, not a shortcut around it: a
762+
complete audit, with every deviation fixed or ledgered, precedes recording a seal.

doc/architecture/enforcement/agent-review-checklist.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
The tier-4 gate from [architectural-requirements.md](../architectural-requirements.md) §*Quality
44
attributes and enforcement*. It enforces the **semantic** architectural requirements — the ones no
55
compiler or linter can express — by having an LLM reviewer judge a diff against each item. Run it as
6-
a CI step on every change (and locally before pushing).
6+
a CI step on every change (and locally before pushing). For diffs touching
7+
`src/inet/linklayer/ieee80211/` or `src/inet/physicallayer/wireless/ieee80211/`, additionally run
8+
the [IEEE 802.11 checklist](ieee80211-agent-review-checklist.md).
79

810
## How to run
911

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
# IEEE 802.11 Agent-Review Checklist (T4 enforcement)
2+
3+
The tier-4 gate for the WLAN-specific requirements in
4+
[ieee80211-architectural-requirements.md](../ieee80211-architectural-requirements.md). It applies
5+
**in addition to** the general [agent-review-checklist.md](agent-review-checklist.md) whenever a
6+
diff touches `src/inet/linklayer/ieee80211/` or `src/inet/physicallayer/wireless/ieee80211/`.
7+
8+
Use the same output format and ground rules as the general checklist (`PASS` / `FLAG` / `QUESTION`,
9+
precision over recall, respect the ledgers, scope to the diff).
10+
11+
## Checklist
12+
13+
**[AR-WLAN-STD-TRACE] Does new normative logic cite its IEEE revision and clause?**
14+
FLAG a new state transition, validity check, timing formula, or field semantic with no standard
15+
citation and no "modeling simplification" label. *Not a violation:* infrastructure code with no
16+
normative content.
17+
18+
**[AR-WLAN-STD-GATING] Is amendment-specific behavior gated by mode and capabilities?**
19+
FLAG newer-amendment behavior that executes based on code presence alone, without an operating-mode
20+
or negotiated-capability condition. *Not a violation:* behavior gated through the mode set, a
21+
station capability, or an established agreement.
22+
23+
**[AR-WLAN-ARCH-BOUNDARIES] Does one component reach into another's implementation state?**
24+
FLAG a `check_and_cast` of a peer component (MAC↔PHY, MAC↔mgmt, rate control↔anything) to a
25+
concrete type to read or write its state. *Not a violation:* calls through the `mac/contract/`
26+
interfaces or the mode APIs.
27+
28+
**[AR-WLAN-ARCH-OWNERSHIP] Does the change create a second writable copy of protocol state?**
29+
FLAG a new field mirroring association, sequence, retry, NAV, backoff, TXOP, Block Ack, or
30+
power-save state that another component already owns, kept in sync by assignment. *Not a
31+
violation:* a read-only query of the owner, or a value received in a notification and used
32+
immediately.
33+
34+
**[AR-WLAN-ARCH-VARIANTS] Is a variant added as scattered conditionals instead of a policy?**
35+
FLAG amendment/role/algorithm branching (`if (isHt)`-style) multiplying through shared logic where
36+
a replaceable policy module or mode object is the established pattern. *Not a violation:* a
37+
capability gate at a single entry point (that is AR-WLAN-STD-GATING working as intended).
38+
39+
**[AR-WLAN-FRAME-REPRESENTATION] Is on-air information represented outside the typed frame model?**
40+
FLAG wire-visible information carried in a tag past the transmission boundary, a frame field added
41+
in C++ instead of the `.msg` definition, hand-edited generated message code, or a new frame type
42+
without serializer + dissector + printer registration.
43+
44+
**[AR-WLAN-PHY-AUTHORITY / AR-WLAN-PHY-TIMING] Is PHY math or timing duplicated or hardcoded?**
45+
FLAG rate/duration/legality formulas reimplemented outside the mode classes, or a bare numeric
46+
timing constant (SIFS, slot, timeout, CW bound) in MAC/management/PHY logic instead of a derivation
47+
from the selected mode. *Not a violation:* standard-cited constants defined once inside a mode
48+
class.
49+
50+
**[AR-WLAN-MAC-EXCHANGE] Are frame-exchange decisions made outside the exchange's state machine?**
51+
FLAG response-matching, timeout, retry, or completion decisions added to Rx paths, queue callbacks,
52+
or timers outside the frame-sequence machinery that owns the exchange.
53+
54+
**[AR-WLAN-MAC-SEQUENCE] Is sequence/window arithmetic implemented ad hoc?**
55+
FLAG inline sequence-number comparison or Block Ack window arithmetic instead of use of the shared
56+
sequence-numbering, duplicate-removal, and Block Ack services (wrap-around correctness lives only
57+
in the shared code).
58+
59+
**[AR-WLAN-MAC-QOS] Is QoS classification or EDCA state duplicated?**
60+
FLAG a second TID/UP→access-category mapping, or per-AC contention/TXOP/retry state held outside
61+
the owning EDCA function. *Not a violation:* reading a frame's TID from its typed header field.
62+
63+
**[AR-WLAN-MAC-MULTIUSER] Does MU scheduling entangle with PPDU construction?**
64+
FLAG scheduler code that assembles PPDU internals or PHY code that makes user/resource-selection
65+
decisions, instead of exchanging a complete, validated, immutable transmission plan.
66+
67+
**[AR-WLAN-OBS-EVENTS] Is a semantic event emitted twice, or reconstructed by an observer?**
68+
FLAG the same semantic event (attempt, retry, timeout, agreement change, …) emitted by two
69+
components, a new state owner shipping without its signals, or an observer inferring MAC decisions
70+
from side effects instead of subscribing to the owner's signal.
71+
72+
**[AR-WLAN-QUAL-TESTS] Does a normative change ship without focused tests and legacy regressions?**
73+
FLAG new or changed normative behavior with no focused test of its correctness (boundaries,
74+
wrap-around, capability combinations, roles) or with no legacy fingerprint run demonstrating
75+
non-interference.
76+
77+
## Output footer
78+
79+
End with the same one-line verdict as the general checklist: `REVIEW: n PASS, n FLAG, n QUESTION`,
80+
with suggested `AV-*`/`NV-*` ledger rows for any `FLAG`.

0 commit comments

Comments
 (0)