From owner-freebsd-acpi@FreeBSD.ORG Mon Jan 21 11:06:42 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 13D20B7D for ; Mon, 21 Jan 2013 11:06:42 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id E16F270A for ; Mon, 21 Jan 2013 11:06:41 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.6/8.14.6) with ESMTP id r0LB6fxh053989 for ; Mon, 21 Jan 2013 11:06:41 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.6/8.14.6/Submit) id r0LB6fBu053987 for freebsd-acpi@FreeBSD.org; Mon, 21 Jan 2013 11:06:41 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 21 Jan 2013 11:06:41 GMT Message-Id: <201301211106.r0LB6fBu053987@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-acpi@FreeBSD.org Subject: Current problem reports assigned to freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 11:06:42 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o kern/174766 acpi [acpi] Random acpi panic o kern/174504 acpi [ACPI] Suspend/resume broken on Lenovo x220 o kern/171305 acpi [acpi] acpi_tz0: _CRT value is absurd, ignored (256.0C o kern/164329 acpi [acpi] hw.acpi.thermal.tz0.temperature shows strange v o kern/163268 acpi [acpi_hp] fix driver detach in absence of CMI o kern/162859 acpi [acpi] ACPI battery/acline monitoring partialy working o kern/161715 acpi [acpi] Dell E6520 doesn't resume after ACPI suspend o kern/161713 acpi [acpi] Suspend on Dell E6520 o kern/160838 acpi [acpi] ACPI Battery Monitor Non-Functional o kern/160419 acpi [acpi_thermal] acpi_thermal kernel thread high CPU usa o kern/158689 acpi [acpi] value of sysctl hw.acpi.thermal.polling_rate ne o kern/154955 acpi [acpi] Keyboard or ACPI doesn't work on Lenovo S10-3 o kern/152438 acpi [acpi]: patch to acpi_asus(4) to add extra sysctls for o kern/152098 acpi [acpi] Lenovo T61p does not resume o i386/146715 acpi [acpi] Suspend works, resume not on a HP Probook 4510s o kern/145306 acpi [acpi]: Can't change brightness on HP ProBook 4510s o i386/143798 acpi [acpi] shutdown problem with SiS K7S5A o kern/143420 acpi [acpi] ACPI issues with Toshiba o kern/142009 acpi [acpi] [panic] Panic in AcpiNsGetAttachedObject o kern/139088 acpi [acpi] ACPI Exception: AE_AML_INFINITE_LOOP error o amd64/138210 acpi [acpi] acer aspire 5536 ACPI problems (S3, brightness, o kern/137042 acpi [acpi] hp laptop's lcd not wakes up after suspend to r o i386/136008 acpi [acpi] Dell Vostro 1310 will not shutdown (Requires us o kern/132602 acpi [acpi] ACPI Problem with Intel SS4200: System does not p kern/128634 acpi [patch] fix acpi_asus(4) in asus a6f laptop o bin/126162 acpi [acpi] ACPI autoload failed : loading required module o kern/123039 acpi [acpi] ACPI AML_BUFFER_LIMIT errors during boot a i386/122887 acpi [panic] [atkbdc] 7.0-RELEASE on IBM HS20 panics immed s kern/112544 acpi [acpi] [patch] Add High Precision Event Timer Driver f o kern/105537 acpi [acpi] problems in acpi on HP Compaq nc6320 o kern/91594 acpi [acpi] FreeBSD > 5.4 w/ACPI fails to detect Intel Pro/ o kern/73823 acpi [request] acpi / power-on by timer support o kern/56024 acpi ACPI suspend drains battery while in S3 33 problems total. From owner-freebsd-acpi@FreeBSD.ORG Thu Jan 24 18:49:10 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A41EE5EE; Thu, 24 Jan 2013 18:49:10 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id C089BE14; Thu, 24 Jan 2013 18:49:09 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id UAA24592; Thu, 24 Jan 2013 20:49:08 +0200 (EET) (envelope-from avg@FreeBSD.org) Message-ID: <51018223.4030702@FreeBSD.org> Date: Thu, 24 Jan 2013 20:49:07 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130113 Thunderbird/17.0.2 MIME-Version: 1.0 To: Jung-uk Kim Subject: uma for acpi object cache References: <20130122175629.GA1714@garage.freebsd.pl> <51008661.4060006@FreeBSD.org> <510101B4.4030409@FreeBSD.org> <51017D79.6060202@FreeBSD.org> In-Reply-To: <51017D79.6060202@FreeBSD.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 18:49:10 -0000 on 24/01/2013 20:29 Jung-uk Kim said the following: > On 2013-01-24 04:41:08 -0500, Andriy Gapon wrote: >> on 24/01/2013 02:54 Jung-uk Kim said the following: >> I think that I have a much better patch for all potential ACPI >> object cache problems :-) >> http://people.freebsd.org/~avg/acpi-uma-cache.diff > >> What do you think? > > We have to fix this bug because local cache is always used for > userland applications, e.g., iasl. Could you please clarify what problem/bug is fixed by that patch? I looked hard but couldn't spot any difference besides moving the link pointer from offset 8 to offset 0. > BTW, I tried something like that long ago. In fact, the first attempt > goes all the way back to this patch (warning: it's naive, broken, and > overly complicated): > > http://people.freebsd.org/~jkim/acpica/OsdCache.diff > > I have more up-to-date and correct patch to use UMA but I'm still not > 100% convinced whether we want to do it or not. Hmm, your patch looks a bit more complicated than mine. What is all that extra stuff that you have there? > When utcache.c works, > it works fairly well, actually. :-) Well, my primary motivation for the patch is all the reports about mysterious panics that seem to involve the cache: http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7562 http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7613 http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7077 There were a few more reports with the same theme. I hoped that using uma(9) instead of hand-rolled code would lead to better diagnostic and debugging cabilities. -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Thu Jan 24 20:35:15 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EC780571; Thu, 24 Jan 2013 20:35:15 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from hammer.pct.niksun.com (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id 7911D33B; Thu, 24 Jan 2013 20:35:15 +0000 (UTC) Message-ID: <51019AAE.10501@FreeBSD.org> Date: Thu, 24 Jan 2013 15:33:50 -0500 From: Jung-uk Kim User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130116 Thunderbird/17.0.2 MIME-Version: 1.0 To: Andriy Gapon Subject: Re: uma for acpi object cache References: <20130122175629.GA1714@garage.freebsd.pl> <51008661.4060006@FreeBSD.org> <510101B4.4030409@FreeBSD.org> <51017D79.6060202@FreeBSD.org> <51018223.4030702@FreeBSD.org> In-Reply-To: <51018223.4030702@FreeBSD.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 20:35:16 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 2013-01-24 13:49:07 -0500, Andriy Gapon wrote: > on 24/01/2013 20:29 Jung-uk Kim said the following: >> On 2013-01-24 04:41:08 -0500, Andriy Gapon wrote: >>> on 24/01/2013 02:54 Jung-uk Kim said the following: I think >>> that I have a much better patch for all potential ACPI object >>> cache problems :-) >>> http://people.freebsd.org/~avg/acpi-uma-cache.diff >> >>> What do you think? >> >> We have to fix this bug because local cache is always used for >> userland applications, e.g., iasl. > > Could you please clarify what problem/bug is fixed by that patch? I > looked hard but couldn't spot any difference besides moving the > link pointer from offset 8 to offset 0. If I am not completely mistaken, this is what's happening: https://github.com/otcshare/acpica/pull/3 Please see ACPI_OBJECT_COMMON_HEADER macro change in the commit I mentioned the pull request. Before the commit: UINT8 Descriptor; UINT8 Type; UINT16 ReferenceCount; union acpi_operand_object *NextObject; UINT8 Flags; After the commit: union acpi_operand_object *NextObject; UINT8 DescriptorType; UINT8 Type; UINT16 ReferenceCount; UINT8 Flags; It may not look obvious but LinkOffset was used to keep offset of NextObject (and it was only "safe" for certain compilers & platforms). Alas, it is completely bogus now because the pointer became the first element of any object. Although it was the right decision, the author forgot to change the LinkOffset with this commit, I guess. Now, modifying DescriptorType, Type, ReferenceCount, or Flags silently corrupts the linked list. Similarly, modifying any of these before setting the pointer gets silently clobbered. For example, ACPI_SET_DESCRIPTOR_TYPE() in AcpiOsReleaseObject() is effectively no-op because it's overwritten later. Does it make sense to you? >> BTW, I tried something like that long ago. In fact, the first >> attempt goes all the way back to this patch (warning: it's naive, >> broken, and overly complicated): >> >> http://people.freebsd.org/~jkim/acpica/OsdCache.diff >> >> I have more up-to-date and correct patch to use UMA but I'm still >> not 100% convinced whether we want to do it or not. > > Hmm, your patch looks a bit more complicated than mine. What is all > that extra stuff that you have there? The main issue was AcpiOsPurgeCache(). For example, we didn't have anything like Linux's kmem_cache_shrink() at the time: http://www.kernel.org/doc/htmldocs/kernel-api/API-kmem-cache-shrink.html It seems you implemented that with zone_drain() but it wasn't available until this commit: http://svnweb.freebsd.org/base?view=revision&revision=166213 Also, I had to make sure the cache is empty before we do uma_zdestroy(), so on and so forth. >> When utcache.c works, it works fairly well, actually. :-) > > Well, my primary motivation for the patch is all the reports about > mysterious panics that seem to involve the cache: > http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7562 > http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7613 > http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7077 > > There were a few more reports with the same theme. I hoped that > using uma(9) instead of hand-rolled code would lead to better > diagnostic and debugging cabilities. Hmm... I am not really sure local cache is to blame here. If you really want to prove your theory, I think a simple modification to utcache.c should do: Cache->LinkOffset = 8; Cache->ListName = CacheName; Cache->ObjectSize = ObjectSize; - - Cache->MaxDepth = MaxDepth; + Cache->MaxDepth = 0; *ReturnCache = Cache; return (AE_OK); This should effectively kill object caching. Jung-uk Kim -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQEcBAEBAgAGBQJRAZquAAoJECXpabHZMqHOE9EIANaY52hh9wpflBCsISJHHmS0 MTtrEiLeC+SqUd8Z+WN0QCLkg9xitryuoyDEK+bMKfn5p5zjJQEL4OyEHSuN37I3 j06UU8gcti6Q8nv5f0EjgT/RR9WR8/AJfIta6neaiX+5cZxARpj86avD+hf8Mv71 7LiiDtbDIzkwf4bXM0kkhs5+UPCqlkCzZUHzMNQ8CZsmtIy8vfw3wagpYfX0nMhN YjdZkADo2f46lgZw409VBOxfwewrzrhYWeCG3ETPBM0YCYRsmU47dWNlnWFkqIQY OZT4BIu0sHtGYzCwamWKBDCSklpzGgYqk2V4eRZcm8b/BLCnS712GkqZfNYsei0= =ObAy -----END PGP SIGNATURE----- From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 08:22:34 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 863F696C; Fri, 25 Jan 2013 08:22:34 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id A043D6B3; Fri, 25 Jan 2013 08:22:33 +0000 (UTC) Received: from porto.starpoint.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 KAA29490; Fri, 25 Jan 2013 10:22:26 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1TyeYL-000F3y-Od; Fri, 25 Jan 2013 10:22:25 +0200 Message-ID: <510240BF.9070301@FreeBSD.org> Date: Fri, 25 Jan 2013 10:22:23 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: Jung-uk Kim Subject: Re: uma for acpi object cache References: <20130122175629.GA1714@garage.freebsd.pl> <51008661.4060006@FreeBSD.org> <510101B4.4030409@FreeBSD.org> <51017D79.6060202@FreeBSD.org> <51018223.4030702@FreeBSD.org> <51019AAE.10501@FreeBSD.org> In-Reply-To: <51019AAE.10501@FreeBSD.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 08:22:34 -0000 on 24/01/2013 22:33 Jung-uk Kim said the following: > If I am not completely mistaken, this is what's happening: > > https://github.com/otcshare/acpica/pull/3 > > Please see ACPI_OBJECT_COMMON_HEADER macro change in the commit I > mentioned the pull request. > > Before the commit: > UINT8 Descriptor; > UINT8 Type; > UINT16 ReferenceCount; > union acpi_operand_object *NextObject; > UINT8 Flags; > > After the commit: > union acpi_operand_object *NextObject; > UINT8 DescriptorType; > UINT8 Type; > UINT16 ReferenceCount; > UINT8 Flags; > > It may not look obvious but LinkOffset was used to keep offset of > NextObject (and it was only "safe" for certain compilers & platforms). > > Alas, it is completely bogus now because the pointer became the first > element of any object. Although it was the right decision, the author > forgot to change the LinkOffset with this commit, I guess. Now, > modifying DescriptorType, Type, ReferenceCount, or Flags silently > corrupts the linked list. Similarly, modifying any of these before > setting the pointer gets silently clobbered. For example, > ACPI_SET_DESCRIPTOR_TYPE() in AcpiOsReleaseObject() is effectively > no-op because it's overwritten later. > > Does it make sense to you? Hmm, not sure... Are you trying to improve behavior in use-after-free scenario or some such abnormal situation? My understanding is this. An object is either in use or it's free/cached. When it is in use, then LinkOffset has nothing to do with object (cache linking is not applied to the object). When it is cached, then it is not accessed as the real object (via ACPI_OBJECT_COMMON_HEADER fields), it is accessed only as a cached entity via the LinkOffset hackery. So, I do not see any bug in the current code. Your change makes it look a little bit less ugly, though. But I do not see any functional change. -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 08:36:55 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4B927C48; Fri, 25 Jan 2013 08:36:55 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 5EF1972D; Fri, 25 Jan 2013 08:36:53 +0000 (UTC) Received: from porto.starpoint.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 KAA29603; Fri, 25 Jan 2013 10:36:52 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1TyemK-000F5q-G1; Fri, 25 Jan 2013 10:36:52 +0200 Message-ID: <51024423.5020306@FreeBSD.org> Date: Fri, 25 Jan 2013 10:36:51 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: Jung-uk Kim Subject: Re: uma for acpi object cache References: <20130122175629.GA1714@garage.freebsd.pl> <51008661.4060006@FreeBSD.org> <510101B4.4030409@FreeBSD.org> <51017D79.6060202@FreeBSD.org> <51018223.4030702@FreeBSD.org> <51019AAE.10501@FreeBSD.org> In-Reply-To: <51019AAE.10501@FreeBSD.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 08:36:55 -0000 on 24/01/2013 22:33 Jung-uk Kim said the following: > On 2013-01-24 13:49:07 -0500, Andriy Gapon wrote: >> on 24/01/2013 20:29 Jung-uk Kim said the following: >>> BTW, I tried something like that long ago. In fact, the first >>> attempt goes all the way back to this patch (warning: it's naive, >>> broken, and overly complicated): >>> >>> http://people.freebsd.org/~jkim/acpica/OsdCache.diff >>> >>> I have more up-to-date and correct patch to use UMA but I'm still >>> not 100% convinced whether we want to do it or not. > >> Hmm, your patch looks a bit more complicated than mine. What is all >> that extra stuff that you have there? > > The main issue was AcpiOsPurgeCache(). For example, we didn't have > anything like Linux's kmem_cache_shrink() at the time: > > http://www.kernel.org/doc/htmldocs/kernel-api/API-kmem-cache-shrink.html > > It seems you implemented that with zone_drain() but it wasn't > available until this commit: > > http://svnweb.freebsd.org/base?view=revision&revision=166213 > > Also, I had to make sure the cache is empty before we do > uma_zdestroy(), so on and so forth. OK, I see. I don't think that any of that is really needed (now). If you don't object I'll commit my variant in 1-2 weeks from now. -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 08:38:16 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C9BF2C85; Fri, 25 Jan 2013 08:38:16 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id DD59173C; Fri, 25 Jan 2013 08:38:15 +0000 (UTC) Received: from porto.starpoint.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 KAA29607; Fri, 25 Jan 2013 10:38:14 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1Tyend-000F5z-T7; Fri, 25 Jan 2013 10:38:14 +0200 Message-ID: <51024475.20909@FreeBSD.org> Date: Fri, 25 Jan 2013 10:38:13 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: Jung-uk Kim Subject: Re: uma for acpi object cache References: <20130122175629.GA1714@garage.freebsd.pl> <51008661.4060006@FreeBSD.org> <510101B4.4030409@FreeBSD.org> <51017D79.6060202@FreeBSD.org> <51018223.4030702@FreeBSD.org> <51019AAE.10501@FreeBSD.org> In-Reply-To: <51019AAE.10501@FreeBSD.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 08:38:16 -0000 on 24/01/2013 22:33 Jung-uk Kim said the following: > On 2013-01-24 13:49:07 -0500, Andriy Gapon wrote: >> on 24/01/2013 20:29 Jung-uk Kim said the following: >>> When utcache.c works, it works fairly well, actually. :-) > >> Well, my primary motivation for the patch is all the reports about >> mysterious panics that seem to involve the cache: >> http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7562 >> http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7613 >> http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7077 > >> There were a few more reports with the same theme. I hoped that >> using uma(9) instead of hand-rolled code would lead to better >> diagnostic and debugging cabilities. > > Hmm... I am not really sure local cache is to blame here. If you > really want to prove your theory, I think a simple modification to > utcache.c should do: > > Cache->LinkOffset = 8; > Cache->ListName = CacheName; > Cache->ObjectSize = ObjectSize; > - Cache->MaxDepth = MaxDepth; > + Cache->MaxDepth = 0; > > *ReturnCache = Cache; > return (AE_OK); > > This should effectively kill object caching. That's a very simple trick, I wonder why I didn't think about it :-) Now I need to wait until one of the reporters resurfaces. -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 08:43:59 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 18B6EEAA for ; Fri, 25 Jan 2013 08:43:59 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 50C55785 for ; Fri, 25 Jan 2013 08:43:58 +0000 (UTC) Received: from porto.starpoint.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 KAA29670 for ; Fri, 25 Jan 2013 10:43:57 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1TyetA-000F6j-RW for freebsd-acpi@FreeBSD.org; Fri, 25 Jan 2013 10:43:56 +0200 Message-ID: <510245CC.3000903@FreeBSD.org> Date: Fri, 25 Jan 2013 10:43:56 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: freebsd-acpi@FreeBSD.org Subject: acpi resume related patch X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=x-viet-vps Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 08:43:59 -0000 If you have ACPI suspend/resume working, if it used to work but stopped working at some time, if it never worked, but you are still hoping, could you please test the following patch and report back? http://svn.freebsd.by/files/acpi-apic-wakeup-final.patch -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 13:56:18 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 96302C1E for ; Fri, 25 Jan 2013 13:56:18 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-lb0-f172.google.com (mail-lb0-f172.google.com [209.85.217.172]) by mx1.freebsd.org (Postfix) with ESMTP id 25F20B6D for ; Fri, 25 Jan 2013 13:56:17 +0000 (UTC) Received: by mail-lb0-f172.google.com with SMTP id n8so762857lbj.17 for ; Fri, 25 Jan 2013 05:56:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:from:date:message-id:subject:to :content-type; bh=r8LG57SL7lCYta8RRAJXz50lx1YHGFT3X6AYqMlhoX0=; b=IkyZZ5UvCQVugyEhCnZx7aUJ5In+H5IbAHreI4OlEJHaRQvMHTY21+NPm5Mh4Jm5Tr llTi+xpwbk63+s+V07ReY6RLkXmUAs5jA5U/OIsZ2Ri8C/PUn0WfgpzlVBX83cc1sC0Z z5HUv1LPVSMwWmKxUkSYqpsUwLeBDUXh5I+E8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:from:date:message-id:subject:to :content-type:x-gm-message-state; bh=r8LG57SL7lCYta8RRAJXz50lx1YHGFT3X6AYqMlhoX0=; b=U9XYITgK/2nLt15aFZCRQnPiL4m4EWng7V1DMVPmczkH+yyjU1cfxcsCzSvZt7OAvL qnguFK+Y14rKD+LJcWPko2tYwbgTDXVfbpI0UnVyh8v/WGFFETNtL4jWdhX0cPshNroP xH/aT8Mu/VsmlAID/HjvJY3Q9Rd0r1K/Uep0gr3M0OwqFfIWQ9vlQfNEv91H0B6cftwh uA6N91nVO1aIgmUSdg/o67yqYjQKUpLfPUCefb+8fEJfG5j+v1L5sQicxoPPjjU62e1f Nl+KSWz1O3ruXQyUu12wlByb5jbAPhE67daqHGpJ5Blta4z7EOpokAtdkmPSgwyFSLsz bd8w== X-Received: by 10.112.46.37 with SMTP id s5mr2238381lbm.67.1359122170940; Fri, 25 Jan 2013 05:56:10 -0800 (PST) MIME-Version: 1.0 Received: by 10.112.100.164 with HTTP; Fri, 25 Jan 2013 05:55:40 -0800 (PST) From: Eitan Adler Date: Fri, 25 Jan 2013 08:55:40 -0500 Message-ID: Subject: what is required to support a new laptop? To: freebsd-acpi@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQkNMgNaaYB358MIOMkG9GOe1f1MlE6yWE4Dyn3g8X2pUGAcr7nDRbbcXsQzeiuhQfsUjBuu X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 13:56:18 -0000 Hi all, I recently purchased a Lenovo Y530 and attempted to use some of the ACPI features (brightness of backlight, etc.) I attempted to load acpi_ibm but devd reported no events (running with devd -dD). What information might be useful to help support this laptop? Where are events such as "fn+pgup (brightness up) reported? http://freebsd.org/~eadler/files/asl.y530.gz - acpidump -dt if this may be useful. -- Eitan Adler From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 14:09:56 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 60F9AEAD; Fri, 25 Jan 2013 14:09:56 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from onyx.glenbarber.us (onyx.glenbarber.us [IPv6:2607:fc50:1000:c200::face]) by mx1.freebsd.org (Postfix) with ESMTP id 36DBBCDD; Fri, 25 Jan 2013 14:09:56 +0000 (UTC) Received: from glenbarber.us (75-146-225-65-Philadelphia.hfc.comcastbusiness.net [75.146.225.65]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: gjb) by onyx.glenbarber.us (Postfix) with ESMTPSA id 6910C23F654; Fri, 25 Jan 2013 09:09:55 -0500 (EST) DKIM-Filter: OpenDKIM Filter v2.7.4 onyx.glenbarber.us 6910C23F654 Authentication-Results: onyx.glenbarber.us; dkim=none reason="no signature"; dkim-adsp=none (insecure policy) Date: Fri, 25 Jan 2013 09:09:53 -0500 From: Glen Barber To: Eitan Adler Subject: Re: what is required to support a new laptop? Message-ID: <20130125140953.GA1328@glenbarber.us> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="J/dobhs11T7y2rNN" Content-Disposition: inline In-Reply-To: X-Operating-System: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 14:09:56 -0000 --J/dobhs11T7y2rNN Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jan 25, 2013 at 08:55:40AM -0500, Eitan Adler wrote: > Hi all, >=20 > I recently purchased a Lenovo Y530 and attempted to use some of the > ACPI features (brightness of backlight, etc.) >=20 > I attempted to load acpi_ibm but devd reported no events (running with > devd -dD). What information might be useful to help support this > laptop? >=20 > Where are events such as "fn+pgup (brightness up) reported? >=20 > http://freebsd.org/~eadler/files/asl.y530.gz - acpidump -dt if this > may be useful. >=20 Try apci_toshiba.ko. Glen --J/dobhs11T7y2rNN Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQEcBAEBCAAGBQJRApIxAAoJEFJPDDeguUajuxcIAIEQ7e+lM7Jw+lx+xpeFXNfK czbXevbgiBjElt8b53rKfm49vI8y0PnhnB8l1+LS5ftfwVjYVni8YKvP5GQsau0z u02Pb6A94p1kH7J8z6zlJOLvRAfhs0NzaOBHVqjcv4CdZXBl4EzKprgCmufXRGcv HlL0V4Ol6x1DzCh+mLEHEBIrYC0+xklutWuRoQtK0okb+Wq902Vu6epqod7jmAHR 3mTDRTHPeXTRAjnuNYu6HFxWecZGu4nYnDirCLIxrhLXpersZ4App+O/c/XlYSjH OhTf2A1/+CUfT2MvvZSODdgmVfDrCr6ul+MBp10nomPeMeeo6scDXJJo5D9A9Lw= =3OD9 -----END PGP SIGNATURE----- --J/dobhs11T7y2rNN-- From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 14:12:05 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7637EF32; Fri, 25 Jan 2013 14:12:05 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from onyx.glenbarber.us (onyx.glenbarber.us [IPv6:2607:fc50:1000:c200::face]) by mx1.freebsd.org (Postfix) with ESMTP id 4F545CF7; Fri, 25 Jan 2013 14:12:05 +0000 (UTC) Received: from glenbarber.us (75-146-225-65-Philadelphia.hfc.comcastbusiness.net [75.146.225.65]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: gjb) by onyx.glenbarber.us (Postfix) with ESMTPSA id 95F4823F654; Fri, 25 Jan 2013 09:12:04 -0500 (EST) DKIM-Filter: OpenDKIM Filter v2.7.4 onyx.glenbarber.us 95F4823F654 Authentication-Results: onyx.glenbarber.us; dkim=none reason="no signature"; dkim-adsp=none (insecure policy) Date: Fri, 25 Jan 2013 09:12:02 -0500 From: Glen Barber To: Eitan Adler Subject: Re: what is required to support a new laptop? Message-ID: <20130125141202.GB1328@glenbarber.us> References: <20130125140953.GA1328@glenbarber.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="eAbsdosE1cNLO4uF" Content-Disposition: inline In-Reply-To: <20130125140953.GA1328@glenbarber.us> X-Operating-System: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 14:12:05 -0000 --eAbsdosE1cNLO4uF Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jan 25, 2013 at 09:09:53AM -0500, Glen Barber wrote: > On Fri, Jan 25, 2013 at 08:55:40AM -0500, Eitan Adler wrote: > > Hi all, > >=20 > > I recently purchased a Lenovo Y530 and attempted to use some of the > > ACPI features (brightness of backlight, etc.) > >=20 > > I attempted to load acpi_ibm but devd reported no events (running with > > devd -dD). What information might be useful to help support this > > laptop? > >=20 > > Where are events such as "fn+pgup (brightness up) reported? > >=20 > > http://freebsd.org/~eadler/files/asl.y530.gz - acpidump -dt if this > > may be useful. > >=20 >=20 > Try apci_toshiba.ko. >=20 Erm.. Sorry, that may not help. I'm confusing "thinkpad" for "toshiba". Sorry for the noise... Glen --eAbsdosE1cNLO4uF Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQEcBAEBCAAGBQJRApKyAAoJEFJPDDeguUajDsoH/iOSXAP+8g4jSaCXVnNQt0mv OS+9BAEYOYSqP7SkCth7skW4UuAsXE6NJUoB28k4s8EONRd5x2n6QNo3WfFD/DPJ VXcQM3dSgwdNOt7dbwYsVUxsu3xbUwZcW74G6LE6fEt51wtOFZkcmr75L79GsWKp JI22AsDiHtcRZpvSkt6MJWmB8hliDawPYwzexmGnuLB1kdMLJ3vKOCJyWTEAVAIh bWZvrNenk8f1T+Dh4en5b9bFEUfu8YV0E/6oeuXZ8u+F9o9XSuMIgu7xBfZfn8dV lnlOZj2PwsQFhtbxbn93k/TtjDXramRthUeZW7KWoI3jW6OaCixEVWWfbaE0MBQ= =Qpnz -----END PGP SIGNATURE----- --eAbsdosE1cNLO4uF-- From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 17:40:10 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A11D12A3; Fri, 25 Jan 2013 17:40:10 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id 18FFAC47; Fri, 25 Jan 2013 17:40:09 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id r0PHe2C5000347; Sat, 26 Jan 2013 04:40:03 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Sat, 26 Jan 2013 04:40:02 +1100 (EST) From: Ian Smith To: Andriy Gapon Subject: Re: acpi resume related patch In-Reply-To: <510245CC.3000903@FreeBSD.org> Message-ID: <20130126043326.S76686@sola.nimnet.asn.au> References: <510245CC.3000903@FreeBSD.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 17:40:10 -0000 On Fri, 25 Jan 2013 10:43:56 +0200, Andriy Gapon wrote: > If you have ACPI suspend/resume working, if it used to work but stopped working > at some time, if it never worked, but you are still hoping, could you please > test the following patch and report back? > > http://svn.freebsd.by/files/acpi-apic-wakeup-final.patch Sort of a negative report: on my Thinkpad T23 (9.1-REL, i386) suspend and resume finally work flawlessly every time out of the box, with no fudging such as unloading / reloading USB drivers as on 8.2. I always resume it with the Fn key (or lifting lid) but I tried using the power button this time, no problem, so no use testing your patch? cheers, Ian From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 17:45:31 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8EA024EB for ; Fri, 25 Jan 2013 17:45:31 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id D211DCFE for ; Fri, 25 Jan 2013 17:45:30 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id TAA03707; Fri, 25 Jan 2013 19:45:13 +0200 (EET) (envelope-from avg@FreeBSD.org) Message-ID: <5102C4A8.1030401@FreeBSD.org> Date: Fri, 25 Jan 2013 19:45:12 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130113 Thunderbird/17.0.2 MIME-Version: 1.0 To: Ian Smith Subject: Re: acpi resume related patch References: <510245CC.3000903@FreeBSD.org> <20130126043326.S76686@sola.nimnet.asn.au> In-Reply-To: <20130126043326.S76686@sola.nimnet.asn.au> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 17:45:31 -0000 on 25/01/2013 19:40 Ian Smith said the following: > On Fri, 25 Jan 2013 10:43:56 +0200, Andriy Gapon wrote: > > > If you have ACPI suspend/resume working, if it used to work but stopped working > > at some time, if it never worked, but you are still hoping, could you please > > test the following patch and report back? > > > > http://svn.freebsd.by/files/acpi-apic-wakeup-final.patch > > Sort of a negative report: on my Thinkpad T23 (9.1-REL, i386) suspend > and resume finally work flawlessly every time out of the box, with no > fudging such as unloading / reloading USB drivers as on 8.2. > > I always resume it with the Fn key (or lifting lid) but I tried using > the power button this time, no problem, so no use testing your patch? Actually, I failed to mention that, but I am trying to check that there are no regressions with the patch. -- Andriy Gapon From owner-freebsd-acpi@FreeBSD.ORG Fri Jan 25 18:27:01 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 517DFA77; Fri, 25 Jan 2013 18:27:01 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) by mx1.freebsd.org (Postfix) with ESMTP id C052AF17; Fri, 25 Jan 2013 18:27:00 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id r0PIQwuY001950; Sat, 26 Jan 2013 05:26:59 +1100 (EST) (envelope-from smithi@nimnet.asn.au) Date: Sat, 26 Jan 2013 05:26:58 +1100 (EST) From: Ian Smith To: Andriy Gapon Subject: Re: acpi resume related patch In-Reply-To: <5102C4A8.1030401@FreeBSD.org> Message-ID: <20130126051208.P76686@sola.nimnet.asn.au> References: <510245CC.3000903@FreeBSD.org> <20130126043326.S76686@sola.nimnet.asn.au> <5102C4A8.1030401@FreeBSD.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 18:27:01 -0000 On Fri, 25 Jan 2013 19:45:12 +0200, Andriy Gapon wrote: > on 25/01/2013 19:40 Ian Smith said the following: > > On Fri, 25 Jan 2013 10:43:56 +0200, Andriy Gapon wrote: > > > > > If you have ACPI suspend/resume working, if it used to work but stopped working > > > at some time, if it never worked, but you are still hoping, could you please > > > test the following patch and report back? > > > > > > http://svn.freebsd.by/files/acpi-apic-wakeup-final.patch > > > > Sort of a negative report: on my Thinkpad T23 (9.1-REL, i386) suspend > > and resume finally work flawlessly every time out of the box, with no > > fudging such as unloading / reloading USB drivers as on 8.2. > > > > I always resume it with the Fn key (or lifting lid) but I tried using > > the power button this time, no problem, so no use testing your patch? > > Actually, I failed to mention that, but I am trying to check that there are no > regressions with the patch. Having spent the last two full nights up almost completely rebuilding a friend's Lenovo SL500 - broken left LCD hinge, design fault, not an uncommon problem on these - I'm almost delerious and shouldn't have tried this tonight .. but here's the patch results. Too late to try building it tonight anyway (yes these are local times), but it doesn't seem to apply happily to 9.1-RELEASE: ======= Script started on Sat Jan 26 05:07:08 2013 You have mail. root@t23_4ma:/usr/src # patch Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 701FE317; Fri, 25 Jan 2013 19:51:08 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-pa0-f53.google.com (mail-pa0-f53.google.com [209.85.220.53]) by mx1.freebsd.org (Postfix) with ESMTP id 396D33E6; Fri, 25 Jan 2013 19:51:08 +0000 (UTC) Received: by mail-pa0-f53.google.com with SMTP id hz1so446672pad.26 for ; Fri, 25 Jan 2013 11:51:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=U3c0uAj18blTE3jOG9t/wKwYnJW+HSGu0AZWyIfUD4Q=; b=y0micxvKF5szbba0CUgWvsMNzqjkiMjkoWyA0BdPiVksSVlihI0iH7LTSbbOuwgi8z KbdkeYIeibysTF7VZarXI0JoMrhh3tvQIdFB3T3xfdu4S5cshidKUFzWC2f2JP14ojxB W5eGvWP+ojL3jH55u/DjwXqt2pTDmcD1x8rfdQF/r4gNv/Mf1QivZrCJGGL80YkrvEiY IH/qxDWU8Rs3Oyxj9/eB/z6KT96B6TvfmZgSTEBecD85+DCG00sZGKdoCraw+HaMJGGk FqrBpB6eaHtp/HFfcsTa8d2U/0Iv/OOuIoPChREDeMS+geaT8DRdOCcj3kuSZezNtjFB EWgg== MIME-Version: 1.0 X-Received: by 10.68.238.39 with SMTP id vh7mr17174813pbc.6.1359143462679; Fri, 25 Jan 2013 11:51:02 -0800 (PST) Received: by 10.67.2.65 with HTTP; Fri, 25 Jan 2013 11:51:02 -0800 (PST) In-Reply-To: <20130125141202.GB1328@glenbarber.us> References: <20130125140953.GA1328@glenbarber.us> <20130125141202.GB1328@glenbarber.us> Date: Fri, 25 Jan 2013 11:51:02 -0800 Message-ID: Subject: Re: what is required to support a new laptop? From: Kevin Oberman To: Glen Barber Content-Type: text/plain; charset=UTF-8 Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 19:51:08 -0000 On Fri, Jan 25, 2013 at 6:12 AM, Glen Barber wrote: > On Fri, Jan 25, 2013 at 09:09:53AM -0500, Glen Barber wrote: >> On Fri, Jan 25, 2013 at 08:55:40AM -0500, Eitan Adler wrote: >> > Hi all, >> > >> > I recently purchased a Lenovo Y530 and attempted to use some of the >> > ACPI features (brightness of backlight, etc.) >> > >> > I attempted to load acpi_ibm but devd reported no events (running with >> > devd -dD). What information might be useful to help support this >> > laptop? >> > >> > Where are events such as "fn+pgup (brightness up) reported? >> > >> > http://freebsd.org/~eadler/files/asl.y530.gz - acpidump -dt if this >> > may be useful. >> > >> >> Try apci_toshiba.ko. >> > > Erm.. Sorry, that may not help. I'm confusing "thinkpad" for "toshiba". > Sorry for the noise... There are several threads in the archives of acpi@ and mobile@ discussing this. Most things are pretty easy. Use xev to find the events generated by the volume buttons. Mute and the ThinkLight (if your system has one) should work as is. Brightness is a bit bigger issue as Lenovo has completely revamped it These buttons don't generate events. :-( You can install the acpi_call port and use it to set the brightness, but it is a pain as it does not allow for setting incremental changes, only absolute values.(16 of them). Google for "FreeBSD acpi x220 notes". That should find the thread with the details. -- R. Kevin Oberman, Network Engineer E-mail: kob6558@gmail.com From owner-freebsd-acpi@FreeBSD.ORG Sat Jan 26 05:26:10 2013 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A792E8D1 for ; Sat, 26 Jan 2013 05:26:10 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-lb0-f174.google.com (mail-lb0-f174.google.com [209.85.217.174]) by mx1.freebsd.org (Postfix) with ESMTP id 09D95FA2 for ; Sat, 26 Jan 2013 05:26:09 +0000 (UTC) Received: by mail-lb0-f174.google.com with SMTP id l12so1813208lbo.19 for ; Fri, 25 Jan 2013 21:26:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=TrOst1KYbdfssfhmhbFKnUzqLA3fWi9BRGUGQEcX7G8=; b=IfIQmjuXKpZpEMSJinhK8TEGj2pRsuaKiD2r+GjYulYrXoIt1g4I2GpcCjbGaybESo gVqwLhWnyC9ujW+sQF6lqAYL+09rWIaQs3adLhVv7RZQLcANXrm4t6hiAJavvhA1bK/9 83KjmKG0nTbLlKEWiV9NZyW1crg4zpif9GT0k= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type:x-gm-message-state; bh=TrOst1KYbdfssfhmhbFKnUzqLA3fWi9BRGUGQEcX7G8=; b=CZDAEnK4XAK8nfDlnjDfaggOpoJ9c5JaBDjDRao4OJ/8L/I3GF3RxLSsC99d+0tx53 ueQlZMAbDPWoHfnYohJqajQFvKeqMWhzelhS1ntNc4FP3Am+oqBeHujotUgz1M3fwiWI /cX9ZlFLNvi9I0ql/IqUrjIY93vM7yxc/TrIfcVWynis934CAwb4PMcbiLlZoNvGVOou qClpTZVWJga8qaCVbEX1FagXGbnCvK7k6vUj7F/2dVFdILu1zijHoPzBgfSyvJV1IdJI TUF2ixeMLFqR12vonikZx3wuLCqv7hAHv20KwXbIm5IWQtVS+smX5LF1M1Yi7Os/dHAT +vAg== X-Received: by 10.112.17.194 with SMTP id q2mr3066589lbd.7.1359177967376; Fri, 25 Jan 2013 21:26:07 -0800 (PST) MIME-Version: 1.0 Received: by 10.112.100.164 with HTTP; Fri, 25 Jan 2013 21:25:37 -0800 (PST) In-Reply-To: References: <20130125140953.GA1328@glenbarber.us> <20130125141202.GB1328@glenbarber.us> From: Eitan Adler Date: Sat, 26 Jan 2013 00:25:37 -0500 Message-ID: Subject: Re: what is required to support a new laptop? To: Kevin Oberman Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQl4MURVE3JHBz/wDyWzFGXZ9Dk9N6BYDBTOKoWjEMinodVnU9X0SsEg1i9RUgcaOQ6SSe4S Cc: Glen Barber , freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 05:26:10 -0000 On 25 January 2013 14:51, Kevin Oberman wrote: > There are several threads in the archives of acpi@ and mobile@ > discussing this. Most things are pretty easy. Use xev to find the > events generated by the volume buttons. I'm handling the volume keys with xbindkeys. > Mute and the ThinkLight (if > your system has one) should work as is. Mute does not function - I am using xbindkeys to handle it. The "video" key generates no event. > Brightness is a bit bigger issue as Lenovo has completely revamped it > These buttons don't generate events. :-( Where *should* they be handled? How do they work on windows? FWIW they seem to change hw.acpi.video.brightness, but change nothing visible on the screen. > You can install the acpi_call > port and use it to set the brightness, but it is a pain as it does not > allow for setting incremental changes, only absolute values.(16 of > them). Any pointers for what to look at? I have no idea what I'm doing w.r.t. computers ^W ACPI. > Google for "FreeBSD acpi x220 notes". That should find the thread with > the details. I've been reading the thread and I think I may need a little bit more information / handholding while I figure this out -- Eitan Adler From owner-freebsd-acpi@FreeBSD.ORG Sat Jan 26 08:30:35 2013 Return-Path: Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 15389A87; Sat, 26 Jan 2013 08:30:35 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 1767864B; Sat, 26 Jan 2013 08:30:33 +0000 (UTC) Received: from porto.starpoint.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 KAA09826; Sat, 26 Jan 2013 10:30:28 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1Tz19f-000HcX-UP; Sat, 26 Jan 2013 10:30:27 +0200 Message-ID: <51039423.2070203@FreeBSD.org> Date: Sat, 26 Jan 2013 10:30:27 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: Jung-uk Kim Subject: Re: uma for acpi object cache References: <20130122175629.GA1714@garage.freebsd.pl> <51008661.4060006@FreeBSD.org> <510101B4.4030409@FreeBSD.org> <51017D79.6060202@FreeBSD.org> <51018223.4030702@FreeBSD.org> <51019AAE.10501@FreeBSD.org> <51024475.20909@FreeBSD.org> In-Reply-To: <51024475.20909@FreeBSD.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 08:30:35 -0000 on 25/01/2013 10:38 Andriy Gapon said the following: > on 24/01/2013 22:33 Jung-uk Kim said the following: >> On 2013-01-24 13:49:07 -0500, Andriy Gapon wrote: >>> on 24/01/2013 20:29 Jung-uk Kim said the following: >>>> When utcache.c works, it works fairly well, actually. :-) >> >>> Well, my primary motivation for the patch is all the reports about >>> mysterious panics that seem to involve the cache: >>> http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7562 >>> http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7613 >>> http://thread.gmane.org/gmane.os.freebsd.devel.acpi/7077 >> >>> There were a few more reports with the same theme. I hoped that >>> using uma(9) instead of hand-rolled code would lead to better >>> diagnostic and debugging cabilities. >> >> Hmm... I am not really sure local cache is to blame here. If you >> really want to prove your theory, I think a simple modification to >> utcache.c should do: >> >> Cache->LinkOffset = 8; >> Cache->ListName = CacheName; >> Cache->ObjectSize = ObjectSize; >> - Cache->MaxDepth = MaxDepth; >> + Cache->MaxDepth = 0; >> >> *ReturnCache = Cache; >> return (AE_OK); >> >> This should effectively kill object caching. > > That's a very simple trick, I wonder why I didn't think about it :-) > Now I need to wait until one of the reporters resurfaces. > And just to clarify - I didn't and don't suspect the cache code itself. I suspect some code that uses the cache (directly or indirectly) - something like double-free or use-after-free, etc. -- Andriy Gapon