summaryrefslogtreecommitdiff
path: root/sys/netinet
diff options
context:
space:
mode:
authorozaki-r <ozaki-r@NetBSD.org>2016-06-16 02:38:40 +0000
committerozaki-r <ozaki-r@NetBSD.org>2016-06-16 02:38:40 +0000
commit41c2e7d1cb5cc7b95dee4c56ba98ed974ee4deb5 (patch)
treec6a9865e3d02d1c169b9cb05884fc9560f4cef55 /sys/netinet
parent1a7bb65c12b2d37002f3e625910326dc3deb45ff (diff)
Use curlwp_bind and curlwp_bindx instead of open-coding LP_BOUND
Diffstat (limited to 'sys/netinet')
-rw-r--r--sys/netinet/ip_carp.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c
index 7b9adad30bb..b9d84b28912 100644
--- a/sys/netinet/ip_carp.c
+++ b/sys/netinet/ip_carp.c
@@ -1,4 +1,4 @@
-/* $NetBSD: ip_carp.c,v 1.67 2016/06/10 13:31:44 ozaki-r Exp $ */
+/* $NetBSD: ip_carp.c,v 1.68 2016/06/16 02:38:40 ozaki-r Exp $ */
/* $OpenBSD: ip_carp.c,v 1.113 2005/11/04 08:11:54 mcbride Exp $ */
/*
@@ -33,7 +33,7 @@
#endif
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ip_carp.c,v 1.67 2016/06/10 13:31:44 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ip_carp.c,v 1.68 2016/06/16 02:38:40 ozaki-r Exp $");
/*
* TODO:
@@ -933,9 +933,8 @@ carp_send_ad_all(void)
struct carp_if *cif;
struct carp_softc *vh;
int s;
- int bound = curlwp->l_pflag & LP_BOUND;
+ int bound = curlwp_bind();
- curlwp->l_pflag |= LP_BOUND;
s = pserialize_read_enter();
IFNET_READER_FOREACH(ifp) {
struct psref psref;
@@ -956,7 +955,7 @@ carp_send_ad_all(void)
psref_release(&psref, &ifp->if_psref, ifnet_psref_class);
}
pserialize_read_exit(s);
- curlwp->l_pflag ^= bound ^ LP_BOUND;
+ curlwp_bindx(bound);
}