HomeFreeBSD

routing: simplify decompose_change_notification().

Description

routing: simplify decompose_change_notification().

The function's goal is to compare old/new nhop/nexthop group for the route
and decompose it into the series of RTM_ADD/RTM_DELETE single-nhop
events, calling specified callback for each event.
Simplify it by properly leveraging the fact that both old/new groups
are sorted nhop-# ascending.

Tested by: Claudio Jeker<claudio.jeker@klarasystems.com>
Differential Revision: https://reviews.freebsd.org/D35598
MFC after: 2 weeks

Details

Provenance
melifaroAuthored on Jun 27 2022, 5:29 PM
Differential Revision
D35598: routing: simplify decompose_change_notification().
Parents
rG76f1ab8eff9e: routing: actually sort nexthops in nhgs by their index
Branches
Unknown
Tags
Unknown