From owner-cvs-all@FreeBSD.ORG Fri Sep 14 01:12:40 2007 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 028F316A41A; Fri, 14 Sep 2007 01:12:40 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id E1B7E13C46A; Fri, 14 Sep 2007 01:12:39 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id l8E1CdhD096820; Fri, 14 Sep 2007 01:12:39 GMT (envelope-from attilio@repoman.freebsd.org) Received: (from attilio@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id l8E1CdrP096819; Fri, 14 Sep 2007 01:12:39 GMT (envelope-from attilio) Message-Id: <200709140112.l8E1CdrP096819@repoman.freebsd.org> From: Attilio Rao Date: Fri, 14 Sep 2007 01:12:39 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/amd64/isa clock.c src/sys/kern subr_lock.c src/sys/sys lock_profile.h 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: Fri, 14 Sep 2007 01:12:40 -0000 attilio 2007-09-14 01:12:39 UTC FreeBSD src repository Modified files: sys/amd64/isa clock.c sys/kern subr_lock.c sys/sys lock_profile.h Log: Currently the LO_NOPROFILE flag (which is masked on upper level code by per-primitive macros like MTX_NOPROFILE, SX_NOPROFILE or RW_NOPROFILE) is not really honoured. In particular lock_profile_obtain_lock_failure() and lock_profile_obtain_lock_success() are naked respect this flag. The bug leads to locks marked with no-profiling to be profiled as well. In the case of the clock_lock, used by the timer i8254 this leads to unpredictable behaviour both on amd64 and ia32 (double faults panic, sudden reboots, etc.). The amd64 clock_lock is also not marked as not profilable as it should be. Fix these bugs adding proper checks in the lock profiling code and at clock_lock initialization time. i8254 bug pointed out by: kris Tested by: matteo, Giuseppe Cocomazzi Approved by: jeff (mentor) Approved by: re Revision Changes Path 1.234 +1 -1 src/sys/amd64/isa/clock.c 1.17 +1 -1 src/sys/kern/subr_lock.c 1.15 +5 -3 src/sys/sys/lock_profile.h