Page MenuHomeFreeBSD

Fix epoch-related panic in ipdivert & refactor div_output.
ClosedPublic

Authored by melifaro on Jan 22 2020, 2:44 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Nov 20, 11:58 PM
Unknown Object (File)
Thu, Nov 20, 11:56 PM
Unknown Object (File)
Thu, Nov 20, 11:56 PM
Unknown Object (File)
Thu, Nov 20, 11:52 PM
Unknown Object (File)
Mon, Nov 3, 12:49 AM
Unknown Object (File)
Oct 22 2025, 12:08 PM
Unknown Object (File)
Oct 21 2025, 11:14 PM
Unknown Object (File)
Oct 21 2025, 11:14 PM
Subscribers

Details

Summary

Fix epoch-related panic in ipdivert, ensuring in_broadcast() is called within epoch. This got broken in r353292 back in October 2019.
As recent change requires calling in[6]_output() within epoch, it is easier to widen epoch coverage within div_output() instead of cherry-picking individual functions.

Simplify gigantic div_output() by splitting it into 3 functions, handling preliminary setup, remote "ip[6]_output" case and local "netisr" case. Leave original indenting in most parts to ease diff comparison.
Indentation will be fixed by a followup commit.

Test Plan

Tests are added separately in https://reviews.freebsd.org/D23316.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 28845
Build 26852: arc lint + arc unit