aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Petter Selasky <hselasky@FreeBSD.org>2019-10-15 11:14:14 +0000
committerHans Petter Selasky <hselasky@FreeBSD.org>2019-10-15 11:14:14 +0000
commit427c402de2dda60bae24956720bb2ab00f77b915 (patch)
tree32eccfbee4f12844b0a35ae2c406a5cd748df275
parent06656d75b172c1be5a108331f6d61f2e4ccda012 (diff)
downloadsrc-427c402de2dda60bae24956720bb2ab00f77b915.tar.gz
src-427c402de2dda60bae24956720bb2ab00f77b915.zip
Fix missing epochification of the LinuxKPI after r353292.
Sponsored by: Mellanox Technologies
Notes
Notes: svn path=/head/; revision=353548
-rw-r--r--sys/compat/linuxkpi/common/include/linux/netdevice.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/netdevice.h b/sys/compat/linuxkpi/common/include/linux/netdevice.h
index 141d71c7ff39..336215b9f7c5 100644
--- a/sys/compat/linuxkpi/common/include/linux/netdevice.h
+++ b/sys/compat/linuxkpi/common/include/linux/netdevice.h
@@ -2,7 +2,7 @@
* Copyright (c) 2010 Isilon Systems, Inc.
* Copyright (c) 2010 iX Systems, Inc.
* Copyright (c) 2010 Panasas, Inc.
- * Copyright (c) 2013-2017 Mellanox Technologies, Ltd.
+ * Copyright (c) 2013-2019 Mellanox Technologies, Ltd.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -60,11 +60,14 @@
static inline struct ifnet *
dev_get_by_index(struct vnet *vnet, int if_index)
{
+ struct epoch_tracker et;
struct ifnet *retval;
+ NET_EPOCH_ENTER(et);
CURVNET_SET(vnet);
retval = ifnet_byindex_ref(if_index);
CURVNET_RESTORE();
+ NET_EPOCH_EXIT(et);
return (retval);
}