From patchwork Mon Jul 5 06:30:28 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tejun Heo X-Patchwork-Id: 57866 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 90E43B6F0E for ; Mon, 5 Jul 2010 16:30:34 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751976Ab0GEGac (ORCPT ); Mon, 5 Jul 2010 02:30:32 -0400 Received: from hera.kernel.org ([140.211.167.34]:46484 "EHLO hera.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751697Ab0GEGab (ORCPT ); Mon, 5 Jul 2010 02:30:31 -0400 Received: from htj.dyndns.org (localhost [127.0.0.1]) by hera.kernel.org (8.14.4/8.14.3) with ESMTP id o656USqJ019928; Mon, 5 Jul 2010 06:30:29 GMT X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.95.2 at hera.kernel.org Received: from [127.0.0.2] (htj.dyndns.org [127.0.0.2]) by htj.dyndns.org (Postfix) with ESMTPSA id 8BC47100446A6; Mon, 5 Jul 2010 08:30:28 +0200 (CEST) Message-ID: <4C317C04.20500@kernel.org> Date: Mon, 05 Jul 2010 08:30:28 +0200 From: Tejun Heo User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9) Gecko/20100317 SUSE/3.0.4-1.1.1 Thunderbird/3.0.4 MIME-Version: 1.0 To: Mark Knecht CC: Linux Kernel List , "linux-ide@vger.kernel.org" Subject: Re: Drives missing at boot References: <4C2F5ECB.1040505@kernel.org> <4C2F61AB.9030806@kernel.org> In-Reply-To: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on hera.kernel.org X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.3 (hera.kernel.org [127.0.0.1]); Mon, 05 Jul 2010 06:30:29 +0000 (UTC) Sender: linux-ide-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ide@vger.kernel.org On 07/03/2010 06:42 PM, Mark Knecht wrote: > On Sat, Jul 3, 2010 at 9:13 AM, Tejun Heo wrote: >> Hello, >> >> On 07/03/2010 06:06 PM, Mark Knecht wrote: >>>> Can you please *attach* full logs of a successful boot and several >>>> failing boots? >>> >>> Certainly? Which logs? dmesg or something else? >> >> dmesg output preferably with printk timestamp enabled. Can you please apply the attached patch, reproduce the problem and post the kernel log? Thanks. diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index 2984e45..987ca80 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -3739,6 +3739,14 @@ int sata_link_resume(struct ata_link *link, const unsigned long *params, return rc; } while ((scontrol & 0xf0f) != 0x300 && --tries); + /* check once more */ + msleep(100); + if ((rc = sata_scr_read(link, SCR_CONTROL, &scontrol))) + return rc; + ata_link_printk(link, KERN_ERR, + "XXX SControl after resume = %X, tries=%d\n", + scontrol, ATA_LINK_RESUME_TRIES - tries + 1); + if ((scontrol & 0xf0f) != 0x300) { ata_link_printk(link, KERN_ERR, "failed to resume link (SControl %X)\n", @@ -6007,7 +6015,7 @@ static void async_port_probe(void *data, async_cookie_t cookie) ehi->probe_mask |= ATA_ALL_DEVICES; ehi->action |= ATA_EH_RESET | ATA_EH_LPM; - ehi->flags |= ATA_EHI_NO_AUTOPSY | ATA_EHI_QUIET; + ehi->flags |= ATA_EHI_NO_AUTOPSY/* | ATA_EHI_QUIET*/; ap->pflags &= ~ATA_PFLAG_INITIALIZING; ap->pflags |= ATA_PFLAG_LOADING;