From owner-freebsd-acpi@FreeBSD.ORG Mon May 5 19:51:32 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0DEEF956 for ; Mon, 5 May 2014 19:51:32 +0000 (UTC) Received: from mail-ee0-x235.google.com (mail-ee0-x235.google.com [IPv6:2a00:1450:4013:c00::235]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 979C15FBF for ; Mon, 5 May 2014 19:51:31 +0000 (UTC) Received: by mail-ee0-f53.google.com with SMTP id c13so16932eek.12 for ; Mon, 05 May 2014 12:51:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=EjVi0+xPT524IJNBhmwEohRNWDjqi7XbxfbG5SLhy4U=; b=fPs2HB9DWhYqzNaxcwzPDkO1HIoYKmPzoAIU4X+opWIjC7J+wkdnvIq2AqH39zMUam Akzs/ZoMglUAaobMJs+ukEyBI4EbOsw9FKH76TTGlL7fkLGSe8Vvlu7ww+OC1wETV/p0 QxNYt7QgQ4ipmllbztmq4J9gUviShtJ6qyNXmjSrwF8Js5WaySKCb9iytkqYqOY33D3e ROTC4uTKkQhQbk7mkrq+iT+xF8OgIuOQKKR81QhCKZqHxGep9F13zw6/T/mOzhjOH3IW SeqZN11bCCG0mAHzk5BPURpvqME8GsqVzzfVN4n+rNrO7DkbkNUkYIZ13zvdW4BOloaG 5M4g== X-Received: by 10.15.45.130 with SMTP id b2mr34533862eew.28.1399319489917; Mon, 05 May 2014 12:51:29 -0700 (PDT) Received: from mavbook.mavhome.dp.ua ([134.249.139.101]) by mx.google.com with ESMTPSA id a42sm32217834ees.10.2014.05.05.12.51.28 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 05 May 2014 12:51:29 -0700 (PDT) Sender: Alexander Motin Message-ID: <5367EBBE.2020602@FreeBSD.org> Date: Mon, 05 May 2014 22:51:26 +0300 From: Alexander Motin User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 MIME-Version: 1.0 To: Adrian Chadd , "freebsd-acpi@freebsd.org" Subject: Re: suspend issues with latest -HEAD, ahci failing to complete something? References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 May 2014 19:51:32 -0000 On 05.05.2014 20:37, Adrian Chadd wrote: > (I know, I just emailed out asking about setting S3 for the default > lid suspend state, however I just updated to the very latest head and > things went a little backwards.) > > Suspend no longer works for me: > > May 5 10:33:10 lucy-11i386 acpi: suspend at 20140505 10:33:10 > May 5 10:33:47 lucy-11i386 kernel: ahcich0: Timeout on slot 19 port 0 > May 5 10:33:47 lucy-11i386 kernel: ahcich0: is 00000000 cs fff80fff > ss fff80fff rs fff80fff tfd d0 serr 00000000 cmd 0000d317 > May 5 10:33:47 lucy-11i386 kernel: (ada0:ahcich0:0:0:0): > WRITE_FPDMA_QUEUED. ACB: 61 08 e0 b0 fa 40 42 00 00 00 00 00 > May 5 10:33:47 lucy-11i386 kernel: (ada0:ahcich0:0:0:0): CAM status: > Command timeout > May 5 10:33:47 lucy-11i386 kernel: (ada0:ahcich0:0:0:0): Retrying command > May 5 10:33:13 lucy-11i386 acpi: resumed at 20140505 10:33:13 > > May 5 10:33:59 lucy-11i386 acpi: suspend at 20140505 10:33:59 > May 5 10:34:37 lucy-11i386 kernel: ahcich0: Timeout on slot 9 port 0 > May 5 10:34:37 lucy-11i386 kernel: ahcich0: is 00000000 cs ffffff83 > ss ffffff83 rs ffffff83 tfd d0 serr 00000000 cmd 0000c717 > May 5 10:34:37 lucy-11i386 kernel: (ada0:ahcich0:0:0:0): > WRITE_FPDMA_QUEUED. ACB: 61 08 18 5c f7 40 42 00 00 00 00 00 > May 5 10:34:37 lucy-11i386 kernel: (ada0:ahcich0:0:0:0): CAM status: > Command timeout > May 5 10:34:37 lucy-11i386 kernel: (ada0:ahcich0:0:0:0): Retrying command > May 5 10:34:03 lucy-11i386 acpi: resumed at 20140505 10:34:03 > > What has recently changed that'd possibly break ahci's ability to > correctly suspend? When I tested it last time (awhile ago), it was working for me. ahci_ch_suspend() should block all I/O on the channel and wait until all active commands complete. On resume channel should be reinitialized, device reset and only then I/Os should be released. Do you see those timeouts on suspend or resume? Do you have kern.cam.ada.spindown_suspend enabled? Can you try to disable it? -- Alexander Motin