svn commit: r353633 - head/sys/ofed/include/rdma
Hans Petter Selasky
hselasky at FreeBSD.org
Wed Oct 16 08:56:08 UTC 2019
Author: hselasky
Date: Wed Oct 16 08:56:07 2019
New Revision: 353633
URL: https://svnweb.freebsd.org/changeset/base/353633
Log:
VLAN_TRUNKDEV() requires epochification in ibcore after r353292.
Sponsored by: Mellanox Technologies
Modified:
head/sys/ofed/include/rdma/ib_addr.h
Modified: head/sys/ofed/include/rdma/ib_addr.h
==============================================================================
--- head/sys/ofed/include/rdma/ib_addr.h Wed Oct 16 08:55:29 2019 (r353632)
+++ head/sys/ofed/include/rdma/ib_addr.h Wed Oct 16 08:56:07 2019 (r353633)
@@ -354,9 +354,13 @@ static inline u16 rdma_get_vlan_id(union ib_gid *dgid)
static inline struct net_device *rdma_vlan_dev_real_dev(struct net_device *dev)
{
- if (dev->if_type == IFT_ETHER && dev->if_pcp != IFNET_PCP_NONE)
- return dev; /* prio-tagged traffic */
- return VLAN_TRUNKDEV(__DECONST(struct ifnet *, dev));
+ struct epoch_tracker et;
+
+ NET_EPOCH_ENTER(et);
+ if (dev->if_type != IFT_ETHER || dev->if_pcp == IFNET_PCP_NONE)
+ dev = VLAN_TRUNKDEV(dev); /* non prio-tagged traffic */
+ NET_EPOCH_EXIT(et);
+ return (dev);
}
#endif /* IB_ADDR_H */
More information about the svn-src-all
mailing list