From owner-freebsd-acpi@FreeBSD.ORG Thu Oct 15 05:23:54 2009 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 679611065670; Thu, 15 Oct 2009 05:23:54 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 378728FC28; Thu, 15 Oct 2009 05:23:52 +0000 (UTC) Received: from porto.topspin.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id IAA15955; Thu, 15 Oct 2009 08:23:50 +0300 (EEST) (envelope-from avg@icyb.net.ua) Received: from localhost.topspin.kiev.ua ([127.0.0.1]) by porto.topspin.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1MyIoX-0002WK-7n; Thu, 15 Oct 2009 08:23:49 +0300 Message-ID: <4AD6B1D5.3010003@icyb.net.ua> Date: Thu, 15 Oct 2009 08:23:33 +0300 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.23 (X11/20090823) MIME-Version: 1.0 To: Robert Noland References: <4AD6067E.2010503@icyb.net.ua> <1255555532.95374.147.camel@balrog.2hip.net> In-Reply-To: <1255555532.95374.147.camel@balrog.2hip.net> X-Enigmail-Version: 0.96.0 Content-Type: text/plain; charset=KOI8-U Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@FreeBSD.org, freebsd-acpi@FreeBSD.org Subject: Re: heci: a new driver for review and testing X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2009 05:23:54 -0000 on 15/10/2009 00:25 Robert Noland said the following: > On Wed, 2009-10-14 at 20:12 +0300, Andriy Gapon wrote: >> Some time ago I posted some ideas about HECI/MEI driver for FreeBSD: >> http://docs.freebsd.org/cgi/mid.cgi?4968E9A1.3080006 >> >> I actually got around to implementing it (in initial/basic form): >> http://people.freebsd.org/~avg/heci.tgz > > Your getting a WITNESS warning from malloc() while holding a lock at > like 941 of heci.c > > mec = (struct me_client *)malloc(sizeof(*mec), M_HECI, > M_NOWAIT | M_ZERO); > > fixes it. Shame on me! I have to admit that tested/used this module only on stable/7 (amd64) and without WITNESS/INVARIANTS. Thank you for catching this. I guess I should also add a check for malloc returning NULL. > It also locked up the machine when I tried to kldunload, but > haven't identified a root cause of that. Haven't seen it here. I will try to investigate. -- Andriy Gapon