From owner-freebsd-acpi@FreeBSD.ORG Wed Jun 15 20:15:23 2005 Return-Path: X-Original-To: freebsd-acpi@FreeBSD.org Delivered-To: freebsd-acpi@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 72F9A16A41C; Wed, 15 Jun 2005 20:15:23 +0000 (GMT) (envelope-from nate@root.org) Received: from www.cryptography.com (li-22.members.linode.com [64.5.53.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id CCB7643D49; Wed, 15 Jun 2005 20:15:22 +0000 (GMT) (envelope-from nate@root.org) Received: from [10.0.5.50] (adsl-64-171-184-89.dsl.snfc21.pacbell.net [64.171.184.89]) by www.cryptography.com (8.12.8/8.12.8) with ESMTP id j5FKF5Z6013361 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 15 Jun 2005 13:15:08 -0700 Message-ID: <42B08B57.6010203@root.org> Date: Wed, 15 Jun 2005 13:11:03 -0700 From: Nate Lawson User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Eric Anderson References: <200506032012.j53KCC5k077879@repoman.freebsd.org> <42AD83ED.8070703@centtech.com> <42AD849E.8030908@centtech.com> <200506141621.32011.jhb@FreeBSD.org> <42B06B2D.4010600@centtech.com> In-Reply-To: <42B06B2D.4010600@centtech.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-acpi@FreeBSD.org, John Baldwin Subject: Re: cvs commit: src/sys/dev/acpica acpi.c 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: Wed, 15 Jun 2005 20:15:23 -0000 Eric Anderson wrote: >>>> >>>> Ok - I've narrowed it down. A GENERIC kernel will go into S3 just fine >>>> on this laptop. Removing apic from the kernel will break that. It is interesting that the suspend path without the apic support causes a hang for you. This should be investigated. Does it work if you have apic compiled in but boot with hint.apic.0.disabled="1" ? Any ideas where to look John? >>>> I've also run into some bugs with having smp in the kernel and certain >>>> modules, so beware. >>>> >>>> Now, I can successfully go into S3, but coming back out (using the lid >>>> switch button or the power button are the only ways I know of) seems to >>>> reboot the machine. Maybe I should say that I can't tell if it's >>>> rebooting the machine, or if the machine just 'powers up' as if it was >>>> off. >>> >>> >>> Oh - and here's what it looks like when it goes to sleep: >>> >>> acpi_lid0: Lid closed >>> acpi_lid0: wake_prep enabled for \_SB_.LID_ (S3) >>> acpi_button0: wake_prep enabled for \_SB_.PBTN (S3) >>> uhci0: wake_prep disabled wake for \_SB_.PCI0.USB0 (S3) >>> uhci1: wake_prep disabled wake for \_SB_.PCI0.USB1 (S3) >>> uhci2: wake_prep disabled wake for \_SB_.PCI0.USB2 (S3) >>> uhci3: wake_prep disabled wake for \_SB_.PCI0.USB4 (S3) >>> ehci0: wake_prep disabled wake for \_SB_.PCI0.USB3 (S3) This is acpi enabling devices to wake the system from S3 and disabling others. This is done before running all DEVICE_SUSPEND methods since those could potentially power down the device, and then it won't be able to do the wake prep. (Unlikely since it is the chipset which does the wake enable function but still just being careful.) You could disable this by commenting out the acpi_wake_prep_walk(state) call in acpi_SetSleepState(). I doubt this will change anything. >>> pci2:0:0: Transition from D0 to D3 >>> vga0: saving 68 bytes of video state >>> pci0:31:2: Transition from D0 to D3 You could disable PCI power state support with hw.pci.do_power_state="0" >>> ioapic_suspend: not implemented! >>> ioapic_suspend: not implemented! I still think this needs to be implemented although it's not likely to be your problem. >>> ======== acpi_printcpu() debug dump ======== >>> gdt[0097:c09c7380] idt[07ff:c09c7ea0] ldt[0050] tr[0048] efl[00080086] >>> eax[00000001] ebx[c23ccc80] ecx[00000001] edx[00000004] >>> esi[00000003] edi[00000000] ebp[e3618c5c] esp[e3618c40] >>> cr0[8005003b] cr2[2813d704] cr3[00c1e000] cr4[00000691] >>> cs[0020] ds[0028] es[0028] fs[0008] gs[003b] ss[0028] >> > > No - it boots up like I had it powered off. Anything I can debug to > figure that out? When it's suspended, is the sleep light on or are all lights off like it is already powered off? If it's on, it is likely actually suspended. On power up, it's possible your bios doesn't even call the wake vector. There was a beep patch I never committed from takawata that can be used to see if your bios even calls the asm wake code. imp has it somewhere. Try disabling the calls to video reset in the wake code (hw.acpi.reset_video=0). Basically, you see if you're even executing the wake code. -- Nate