diff --git a/drivers/net/ipvlan/ipvlan.h b/drivers/net/ipvlan/ipvlan.h
index c818b9bdab6ee2b291cf5f31927f97a39b015c95..adb826f55e604c2d766c44bc260d1ac9aa96bc07 100644
--- a/drivers/net/ipvlan/ipvlan.h
+++ b/drivers/net/ipvlan/ipvlan.h
@@ -180,7 +180,7 @@ int ipvlan_link_register(struct rtnl_link_ops *ops);
 
 static inline bool netif_is_ipvlan_port(const struct net_device *dev)
 {
-	return dev->rx_handler == ipvlan_handle_frame;
+	return rcu_access_pointer(dev->rx_handler) == ipvlan_handle_frame;
 }
 
 #endif /* __IPVLAN_H */