Lines Matching refs:fi
1116 static struct net_device *switchdev_get_dev_by_nhs(struct fib_info *fi) in switchdev_get_dev_by_nhs() argument
1129 for (nhsel = 0; nhsel < fi->fib_nhs; nhsel++) { in switchdev_get_dev_by_nhs()
1130 const struct fib_nh *nh = &fi->fib_nh[nhsel]; in switchdev_get_dev_by_nhs()
1165 int switchdev_fib_ipv4_add(u32 dst, int dst_len, struct fib_info *fi, in switchdev_fib_ipv4_add() argument
1172 .fi = fi, in switchdev_fib_ipv4_add()
1186 if (fi->fib_net->ipv4.fib_has_custom_rules) in switchdev_fib_ipv4_add()
1190 if (fi->fib_net->ipv4.fib_offload_disabled) in switchdev_fib_ipv4_add()
1193 dev = switchdev_get_dev_by_nhs(fi); in switchdev_fib_ipv4_add()
1199 fi->fib_flags |= RTNH_F_OFFLOAD; in switchdev_fib_ipv4_add()
1217 int switchdev_fib_ipv4_del(u32 dst, int dst_len, struct fib_info *fi, in switchdev_fib_ipv4_del() argument
1224 .fi = fi, in switchdev_fib_ipv4_del()
1233 if (!(fi->fib_flags & RTNH_F_OFFLOAD)) in switchdev_fib_ipv4_del()
1236 dev = switchdev_get_dev_by_nhs(fi); in switchdev_fib_ipv4_del()
1242 fi->fib_flags &= ~RTNH_F_OFFLOAD; in switchdev_fib_ipv4_del()
1253 void switchdev_fib_ipv4_abort(struct fib_info *fi) in switchdev_fib_ipv4_abort() argument
1263 fib_flush_external(fi->fib_net); in switchdev_fib_ipv4_abort()
1264 fi->fib_net->ipv4.fib_offload_disabled = true; in switchdev_fib_ipv4_abort()