Skip to content
  • Dan Williams's avatar
    platform: work around missing kernel netlink notifications of default route changes · 42b43239
    Dan Williams authored
    It appears the kernel does not send notifications via netlink if the
    default route is removed in some cases.  This causes the platform
    route cache to become stale, and thus when the default route is
    reset by NM the platform thinks the route already exists, and does
    not add it.  But the route doesn't exist, becuase the kernel silently
    removed it without telling anyone.
    
    Fix that with a big hammer by flushing/refilling the route cache when
    devices are deactivated (deletion of their addresses causes the default
    route to be removed by the kernel) and when the default route is
    updated by NM itself.
    
    Pavel: if we find a more granular method, we should probably revert
    this as the cache refill can be expensive.
    42b43239