netlink: make it working without INET6
(cherry picked from commit b958b862b1f43f5fef881c1f9aee6618d7d24197)