diff options
Diffstat (limited to 'net/switchdev/switchdev.c')
-rw-r--r-- | net/switchdev/switchdev.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/net/switchdev/switchdev.c b/net/switchdev/switchdev.c index f4fd575aa2a3..19e4e72a1e39 100644 --- a/net/switchdev/switchdev.c +++ b/net/switchdev/switchdev.c | |||
@@ -309,8 +309,12 @@ int netdev_switch_fib_ipv4_add(u32 dst, int dst_len, struct fib_info *fi, | |||
309 | * IPv4 FIB offloading has been disabled completely. | 309 | * IPv4 FIB offloading has been disabled completely. |
310 | */ | 310 | */ |
311 | 311 | ||
312 | if (fi->fib_net->ipv4.fib_has_custom_rules | | 312 | #ifdef CONFIG_IP_MULTIPLE_TABLES |
313 | fi->fib_net->ipv4.fib_offload_disabled) | 313 | if (fi->fib_net->ipv4.fib_has_custom_rules) |
314 | return 0; | ||
315 | #endif | ||
316 | |||
317 | if (fi->fib_net->ipv4.fib_offload_disabled) | ||
314 | return 0; | 318 | return 0; |
315 | 319 | ||
316 | dev = netdev_switch_get_dev_by_nhs(fi); | 320 | dev = netdev_switch_get_dev_by_nhs(fi); |