HomeFreeBSD

Fix gateway setup for the interface routes.

Description

Fix gateway setup for the interface routes.

Currently rinit1() and its IPv6 counterpart

nd6_prefix_onlink_rtrequest() uses dummy null_sdl gateway address
during route insertion and change it afterwards. This behaviour
brings complications to the routing stack and the users of its
upcoming notification system.

This change fixes both rinit1() and nd6_prefix_onlink_rtrequest()

by filling in proper gateway in the beginning. It does not change any
of the userland notifications as in both cases, they happen after
the insertion and fixup process (rt_newaddrmsg_fib() and nd6_rtmsg()).

MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D20328

Details