From owner-freebsd-current@FreeBSD.ORG Tue Sep 18 19:16:15 2007 Return-Path: Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B028716A418; Tue, 18 Sep 2007 19:16:15 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from anuket.mj.niksun.com (gwnew.niksun.com [65.115.46.162]) by mx1.freebsd.org (Postfix) with ESMTP id 5C67913C428; Tue, 18 Sep 2007 19:16:14 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from niksun.com (anuket [10.70.0.5]) by anuket.mj.niksun.com (8.13.6/8.13.6) with ESMTP id l8IJGDaa016093; Tue, 18 Sep 2007 15:16:13 -0400 (EDT) (envelope-from jkim@FreeBSD.org) From: Jung-uk Kim To: freebsd-acpi@FreeBSD.org Date: Tue, 18 Sep 2007 15:16:07 -0400 User-Agent: KMail/1.6.2 MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200709181516.11207.jkim@FreeBSD.org> X-Virus-Scanned: ClamAV 0.90.2/4326/Tue Sep 18 14:30:43 2007 on anuket.mj.niksun.com X-Virus-Status: Clean Cc: freebsd-current@FreeBSD.org Subject: [PATCH] OsdSynch.c modernization X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2007 19:16:15 -0000 I have rewritten sys/dev/acpica/Osd/OsdSynch.c to match the modern ACPI-CA and -CURRENT: http://people.freebsd.org/~jkim/acpica/OsdSynch.diff Major changes are: 1. Semaphore is reimplemented with convar(9) instead of mutex(9). 2. Semaphore with ACPI_WAIT_FOREVER option actually waits forever now. 3. Obsolete and/or hidden debugging knobs and macros are removed. 4. ACPI-CA introduced AcpiOs*Mutex() to complement AcpiOs*Semaphore(): http://bugzilla.kernel.org/show_bug.cgi?id=6634 These functions are implemented and turned on by default. 5. Spinlock is reimplemented with sx lock and more closely implements the intended behaviour (e.g., save/restore interrupts). It is orthogonal to Nate's effort of rewriting acpi_ec.c but I'd like get more feedback *with* his last patch (revision D) because his patch will be committed sooner or later. ;-) Please test/review and let us know if there is any regression or not. Thanks! Jung-uk Kim