History

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.

Roopa Prabhu committed 11 years ago

Commit eea39941 parent c1c52db3 files · +5 −5Browse files

Showing the changes to net/switchdev/switchdev.c (1 of 3 files). Show all

Unified · Split

net/switchdev/switchdev.c+3−3
@@ -338,7 +338,7 @@ int netdev_switch_fib_ipv4_add(u32 dst, int dst_len, struct fib_info *fi, · 337 unmodified lines
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, · 19 unmodified lines
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, · 5 unmodified lines
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;