From owner-cvs-all@FreeBSD.ORG Mon Apr 7 12:23:52 2008 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CB9171065678; Mon, 7 Apr 2008 12:23:52 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from cmail.optima.ua (cmail.optima.ua [195.248.191.121]) by mx1.freebsd.org (Postfix) with ESMTP id D20928FC28; Mon, 7 Apr 2008 12:23:51 +0000 (UTC) (envelope-from mav@FreeBSD.org) X-Spam-Flag: SKIP X-Spam-Yversion: Spamooborona-2.1.0 Received: from orphanage.alkar.net (account mav@alkar.net [212.86.226.11] verified) by cmail.optima.ua (CommuniGate Pro SMTP 5.1.14) with ESMTPA id 103508096; Mon, 07 Apr 2008 15:23:50 +0300 Message-ID: <47FA1255.60002@FreeBSD.org> Date: Mon, 07 Apr 2008 15:23:49 +0300 From: Alexander Motin User-Agent: Thunderbird 2.0.0.0 (X11/20070424) MIME-Version: 1.0 To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org References: <200804061526.m36FQWid082581@repoman.freebsd.org> In-Reply-To: <200804061526.m36FQWid082581@repoman.freebsd.org> X-Enigmail-Version: 0.95.0 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 7bit Cc: Subject: Re: cvs commit: src/sys/netgraph ng_base.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Apr 2008 12:23:52 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi. Alexander Motin wrote: > mav 2008-04-06 15:26:32 UTC > > FreeBSD src repository > > Modified files: > sys/netgraph ng_base.c > Log: > Rewrite node's r/w/q-lock semantics using only atomics instead of mutex > and atomics combination. Mutex is now used only for queue protection. > Also avoid unneded extra swi scheduling calls. > > Revision Changes Path > 1.155 +76 -247 src/sys/netgraph/ng_base.c This patch broke tinderbox build on powerpc. But as soon as I have only replaced _add_ with _set_ and _subtract_ with _clear_ IMHO problem is powerpc atomic.h related. That atomic.h looks something strange: #define atomic_set_long atomic_set_32 #define atomic_clear_long atomic_clear_32 #define atomic_add_long(p, v) atomic_add_32((uint32_t *)p, (uint32_t)v) #define atomic_subtract_long(p, v) atomic_subtract_32((uint32_t *)p, (uint32_t)v) #define atomic_readandclear_long atomic_readandclear_32 Can somebody with powerpc experience check this? - -- Alexander Motin -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFH+hJV0kCgngV3usoRAjtBAJ9+f7dzmXv8xVcmLG3h3x22eg8B9gCfVuvE 5aDm6E5iX1r7tfsQ/kmR0GU= =14ws -----END PGP SIGNATURE-----