Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Sep 2019 16:20:04 +0000 (UTC)
From:      Hans Petter Selasky <hselasky@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r352251 - head/sys/sys
Message-ID:  <201909121620.x8CGK4qS023459@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: hselasky
Date: Thu Sep 12 16:20:03 2019
New Revision: 352251
URL: https://svnweb.freebsd.org/changeset/base/352251

Log:
  Use %u instead of %d to print unsigned integer.
  While at it remove an empty line.
  
  MFC after:	1 week
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/sys/refcount.h

Modified: head/sys/sys/refcount.h
==============================================================================
--- head/sys/sys/refcount.h	Thu Sep 12 15:57:49 2019	(r352250)
+++ head/sys/sys/refcount.h	Thu Sep 12 16:20:03 2019	(r352251)
@@ -85,11 +85,10 @@ refcount_acquire(volatile u_int *count)
 static __inline void
 refcount_acquiren(volatile u_int *count, u_int n)
 {
-
 	u_int old;
 
 	KASSERT(n < REFCOUNT_SATURATION_VALUE / 2,
-	    ("refcount_acquiren: n %d too large", n));
+	    ("refcount_acquiren: n=%u too large", n));
 	old = atomic_fetchadd_int(count, n);
 	if (__predict_false(REFCOUNT_SATURATED(old)))
 		_refcount_update_saturated(count);
@@ -115,7 +114,8 @@ refcount_releasen(volatile u_int *count, u_int n)
 	u_int old;
 
 	KASSERT(n < REFCOUNT_SATURATION_VALUE / 2,
-	    ("refcount_releasen: n %d too large", n));
+	    ("refcount_releasen: n=%u too large", n));
+
 	atomic_thread_fence_rel();
 	old = atomic_fetchadd_int(count, -n);
 	if (__predict_false(n >= REFCOUNT_COUNT(old) ||



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201909121620.x8CGK4qS023459>