]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit - net/core/rtnetlink.c
net: rtnetlink: Don't export empty RTAX_FEATURES
authorPhil Sutter <phil@nwl.cc>
Tue, 23 Aug 2016 11:14:31 +0000 (13:14 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Aug 2016 00:09:28 +0000 (17:09 -0700)
commitf8edcd127b5fa2a82bec22b204b434dc363011b2
tree4c99280ad51a601f0c103ce42a60ade57e724402
parente7b48a32dc5db48ca14e6472b920102c7e53f5aa
net: rtnetlink: Don't export empty RTAX_FEATURES

Since the features bit field has bits for internal only use as well, it
may happen that the kernel exports RTAX_FEATURES attribute with zero
value which is pointless.

Fix this by making sure the attribute is added only if the exported
value is non-zero.

Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/rtnetlink.c