diff options
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/ip_fib.h | 2 | ||||
-rw-r--r-- | include/net/netns/ipv4.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/include/net/ip_fib.h b/include/net/ip_fib.h index cb6c12562899..3bf9ecb6b0d3 100644 --- a/include/net/ip_fib.h +++ b/include/net/ip_fib.h @@ -412,7 +412,7 @@ int fib_validate_source(struct sk_buff *skb, __be32 src, __be32 dst, #ifdef CONFIG_IP_ROUTE_CLASSID static inline int fib_num_tclassid_users(struct net *net) { - return net->ipv4.fib_num_tclassid_users; + return atomic_read(&net->ipv4.fib_num_tclassid_users); } #else static inline int fib_num_tclassid_users(struct net *net) diff --git a/include/net/netns/ipv4.h b/include/net/netns/ipv4.h index c0c0791b1912..da171544a33c 100644 --- a/include/net/netns/ipv4.h +++ b/include/net/netns/ipv4.h @@ -61,7 +61,7 @@ struct netns_ipv4 { #endif bool fib_has_custom_local_routes; #ifdef CONFIG_IP_ROUTE_CLASSID - int fib_num_tclassid_users; + atomic_t fib_num_tclassid_users; #endif struct hlist_head *fib_table_hash; bool fib_offload_disabled; |