diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-02-20 14:55:58 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-02-21 23:49:24 +0100 |
commit | cac56209a66ea3b0be67aa2966b2c628b944da1e (patch) | |
tree | 1f100b5a7ef31579afc6f9242c159cd6c131d780 /drivers/net/vrf.c | |
parent | ibmvnic: Correct goto target for tx irq initialization failure (diff) | |
download | linux-cac56209a66ea3b0be67aa2966b2c628b944da1e.tar.xz linux-cac56209a66ea3b0be67aa2966b2c628b944da1e.zip |
net: Allow a rule to track originating protocol
Allow a rule that is being added/deleted/modified or
dumped to contain the originating protocol's id.
The protocol is handled just like a routes originating
protocol is. This is especially useful because there
is starting to be a plethora of different user space
programs adding rules.
Allow the vrf device to specify that the kernel is the originator
of the rule created for this device.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/vrf.c')
-rw-r--r-- | drivers/net/vrf.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/vrf.c b/drivers/net/vrf.c index 239c78c53e58..951a4b42cb29 100644 --- a/drivers/net/vrf.c +++ b/drivers/net/vrf.c @@ -1174,6 +1174,7 @@ static int vrf_fib_rule(const struct net_device *dev, __u8 family, bool add_it) memset(frh, 0, sizeof(*frh)); frh->family = family; frh->action = FR_ACT_TO_TBL; + frh->proto = RTPROT_KERNEL; if (nla_put_u8(skb, FRA_L3MDEV, 1)) goto nla_put_failure; |