Skip to content

DHCP: Only send the rapid commit option when configured to - #694

Merged
rsmarples merged 2 commits into
masterfrom
dhcp-rapidcommit
Aug 11, 2026
Merged

DHCP: Only send the rapid commit option when configured to#694
rsmarples merged 2 commits into
masterfrom
dhcp-rapidcommit

Conversation

@rsmarples

Copy link
Copy Markdown
Member

Fixes #692. Thanks to Ioannis Anagnostakis for the diagnosis.

Fixes #692. Thanks to Ioannis Anagnostakis for the diagnosis.
@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 28865255-2fc7-4485-8fed-bf37260d3bdd

📥 Commits

Reviewing files that changed from the base of the PR and between 5075222 and 6b58ab7.

📒 Files selected for processing (1)
  • src/dhcp-common.c
💤 Files with no reviewable changes (1)
  • src/dhcp-common.c

Walkthrough

The policy API separates numeric-option checks from DHCP-option checks. DHCPv4 uses the numeric predicate for Rapid Commit handling. DHCPv4 and DHCPv6 use the option-aware predicate when filtering requested options and overrides.

Changes

Policy request handling

Layer / File(s) Summary
Policy predicate API
src/dhcp-common.c, src/dhcp-common.h
Adds dho_policy_requested for numeric options and renames the existing dhcp_opt-based helper to dho_policy_opt_requested.
DHCPv4 request and Rapid Commit handling
src/dhcp.c
Uses dho_policy_opt_requested for parameter-request lists and uses dho_policy_requested when sending and accepting Rapid Commit messages.
DHCPv6 option-request filtering
src/dhcp6.c
Uses dho_policy_opt_requested when constructing and encoding Option Request options, including configured overrides.

Estimated code review effort: 3 (Moderate) | ~20 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: sending Rapid Commit only when configured.
Description check ✅ Passed The description links the pull request to issue #692, which directly matches the DHCP Rapid Commit changes.
Linked Issues check ✅ Passed The changes restore Rapid Commit ACK handling, require explicit configuration for requests, and address the IPv4 regression described in issue #692.
Out of Scope Changes check ✅ Passed All changes support the policy-helper refactor and DHCP Rapid Commit behavior required by issue #692; no unrelated changes are evident.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dhcp-rapidcommit

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@rsmarples
rsmarples merged commit 0406dd8 into master Aug 11, 2026
22 checks passed
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.

dhcpcd-10.5.0 breaks IPv4 on routers using Rapid Commit

1 participant