diff options
author | Roopa Prabhu <roopa@cumulusnetworks.com> | 2015-05-14 00:17:41 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-05-14 22:45:39 -0400 |
commit | eea39946a1f36e8a5a47c86e7ecfca6076868505 (patch) | |
tree | f20832edd2374880b6c3549838a4e525a6ed14ef | |
parent | c1c52db16e26a26b545821abae303310a074350f (diff) |
rename RTNH_F_EXTERNAL to RTNH_F_OFFLOAD
RTNH_F_EXTERNAL today is printed as "offload" in iproute2 output.
This patch renames the flag to be consistent with what the user sees.
Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | include/uapi/linux/rtnetlink.h | 2 | ||||
-rw-r--r-- | net/ipv4/fib_trie.c | 2 | ||||
-rw-r--r-- | net/switchdev/switchdev.c | 6 |
3 files changed, 5 insertions, 5 deletions
diff --git a/include/uapi/linux/rtnetlink.h b/include/uapi/linux/rtnetlink.h index 974db03f7b1a..17fb02f488da 100644 --- a/include/uapi/linux/rtnetlink.h +++ b/include/uapi/linux/rtnetlink.h | |||
@@ -337,7 +337,7 @@ struct rtnexthop { | |||
337 | #define RTNH_F_DEAD 1 /* Nexthop is dead (used by multipath) */ | 337 | #define RTNH_F_DEAD 1 /* Nexthop is dead (used by multipath) */ |
338 | #define RTNH_F_PERVASIVE 2 /* Do recursive gateway lookup */ | 338 | #define RTNH_F_PERVASIVE 2 /* Do recursive gateway lookup */ |
339 | #define RTNH_F_ONLINK 4 /* Gateway is forced on link */ | 339 | #define RTNH_F_ONLINK 4 /* Gateway is forced on link */ |
340 | #define RTNH_F_EXTERNAL 8 /* Route installed externally */ | 340 | #define RTNH_F_OFFLOAD 8 /* offloaded route */ |
341 | 341 | ||
342 | /* Macros to handle hexthops */ | 342 | /* Macros to handle hexthops */ |
343 | 343 | ||
diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c index e13fcc602da2..64c2076ced54 100644 --- a/net/ipv4/fib_trie.c +++ b/net/ipv4/fib_trie.c | |||
@@ -1764,7 +1764,7 @@ void fib_table_flush_external(struct fib_table *tb) | |||
1764 | /* record local slen */ | 1764 | /* record local slen */ |
1765 | slen = fa->fa_slen; | 1765 | slen = fa->fa_slen; |
1766 | 1766 | ||
1767 | if (!fi || !(fi->fib_flags & RTNH_F_EXTERNAL)) | 1767 | if (!fi || !(fi->fib_flags & RTNH_F_OFFLOAD)) |
1768 | continue; | 1768 | continue; |
1769 | 1769 | ||
1770 | netdev_switch_fib_ipv4_del(n->key, | 1770 | netdev_switch_fib_ipv4_del(n->key, |
diff --git a/net/switchdev/switchdev.c b/net/switchdev/switchdev.c index 46568b85c333..055453d48668 100644 --- a/net/switchdev/switchdev.c +++ b/net/switchdev/switchdev.c | |||
@@ -338,7 +338,7 @@ int netdev_switch_fib_ipv4_add(u32 dst, int dst_len, struct fib_info *fi, | |||
338 | fi, tos, type, nlflags, | 338 | fi, tos, type, nlflags, |
339 | tb_id); | 339 | tb_id); |
340 | if (!err) | 340 | if (!err) |
341 | fi->fib_flags |= RTNH_F_EXTERNAL; | 341 | fi->fib_flags |= RTNH_F_OFFLOAD; |
342 | } | 342 | } |
343 | 343 | ||
344 | return err; | 344 | return err; |
@@ -364,7 +364,7 @@ int netdev_switch_fib_ipv4_del(u32 dst, int dst_len, struct fib_info *fi, | |||
364 | const struct swdev_ops *ops; | 364 | const struct swdev_ops *ops; |
365 | int err = 0; | 365 | int err = 0; |
366 | 366 | ||
367 | if (!(fi->fib_flags & RTNH_F_EXTERNAL)) | 367 | if (!(fi->fib_flags & RTNH_F_OFFLOAD)) |
368 | return 0; | 368 | return 0; |
369 | 369 | ||
370 | dev = netdev_switch_get_dev_by_nhs(fi); | 370 | dev = netdev_switch_get_dev_by_nhs(fi); |
@@ -376,7 +376,7 @@ int netdev_switch_fib_ipv4_del(u32 dst, int dst_len, struct fib_info *fi, | |||
376 | err = ops->swdev_fib_ipv4_del(dev, htonl(dst), dst_len, | 376 | err = ops->swdev_fib_ipv4_del(dev, htonl(dst), dst_len, |
377 | fi, tos, type, tb_id); | 377 | fi, tos, type, tb_id); |
378 | if (!err) | 378 | if (!err) |
379 | fi->fib_flags &= ~RTNH_F_EXTERNAL; | 379 | fi->fib_flags &= ~RTNH_F_OFFLOAD; |
380 | } | 380 | } |
381 | 381 | ||
382 | return err; | 382 | return err; |