Commit c3bccac2 authored by Thomas Graf's avatar Thomas Graf Committed by David S. Miller

ipv6: add special mode forwarding=2 to send RS while configured as router

Similar to accepting router advertisement, the IPv6 stack does not send router
solicitations if forwarding is enabled.

This patch enables this behavior to be overruled by setting forwarding to the
special value 2.
Signed-off-by: default avatarThomas Graf <tgraf@infradead.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 65e9b62d
...@@ -2964,7 +2964,8 @@ static void addrconf_dad_completed(struct inet6_ifaddr *ifp) ...@@ -2964,7 +2964,8 @@ static void addrconf_dad_completed(struct inet6_ifaddr *ifp)
start sending router solicitations. start sending router solicitations.
*/ */
if (ifp->idev->cnf.forwarding == 0 && if ((ifp->idev->cnf.forwarding == 0 ||
ifp->idev->cnf.forwarding == 2) &&
ifp->idev->cnf.rtr_solicits > 0 && ifp->idev->cnf.rtr_solicits > 0 &&
(dev->flags&IFF_LOOPBACK) == 0 && (dev->flags&IFF_LOOPBACK) == 0 &&
(ipv6_addr_type(&ifp->addr) & IPV6_ADDR_LINKLOCAL)) { (ipv6_addr_type(&ifp->addr) & IPV6_ADDR_LINKLOCAL)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment