svn commit: r285933 - head/sys/rpc

Konstantin Belousov kib at FreeBSD.org
Tue Jul 28 06:58:11 UTC 2015


Author: kib
Date: Tue Jul 28 06:58:10 2015
New Revision: 285933
URL: https://svnweb.freebsd.org/changeset/base/285933

Log:
  Remove useless acquire semantic from the atomic_add operation before
  sosend().  The only release on the xp_snt_cnt is done after sosend(),
  with an intent to synchronize with load_acq in svc_vc_ack().
  
  Reviewed by:	alc
  Tested by:	pho
  Sponsored by:	The FreeBSD Foundation
  MFC after:	2 weeks

Modified:
  head/sys/rpc/svc_vc.c

Modified: head/sys/rpc/svc_vc.c
==============================================================================
--- head/sys/rpc/svc_vc.c	Tue Jul 28 06:55:08 2015	(r285932)
+++ head/sys/rpc/svc_vc.c	Tue Jul 28 06:58:10 2015	(r285933)
@@ -860,7 +860,7 @@ svc_vc_reply(SVCXPRT *xprt, struct rpc_m
 		len = mrep->m_pkthdr.len;
 		*mtod(mrep, uint32_t *) =
 			htonl(0x80000000 | (len - sizeof(uint32_t)));
-		atomic_add_acq_32(&xprt->xp_snd_cnt, len);
+		atomic_add_32(&xprt->xp_snd_cnt, len);
 		error = sosend(xprt->xp_socket, NULL, NULL, mrep, NULL,
 		    0, curthread);
 		if (!error) {


More information about the svn-src-all mailing list