From owner-freebsd-stable Mon Mar 25 7:50:20 2002 Delivered-To: freebsd-stable@freebsd.org Received: from postal3.es.net (postal3.es.net [198.128.3.207]) by hub.freebsd.org (Postfix) with ESMTP id 7067337B417 for ; Mon, 25 Mar 2002 07:50:12 -0800 (PST) Received: from ptavv.es.net ([198.128.4.29]) by postal3.es.net (Postal Node 3) with ESMTP id GQF37091; Mon, 25 Mar 2002 07:50:11 -0800 Received: from ptavv (localhost [127.0.0.1]) by ptavv.es.net (Postfix) with ESMTP id 639625D06; Mon, 25 Mar 2002 07:50:10 -0800 (PST) To: Tony Maher Cc: stable@freebsd.org Subject: Re: panic on resume (ata related?) In-reply-to: Your message of "Mon, 25 Mar 2002 20:16:30 +1100." <200203250916.g2P9GUr15835@c16703.thorn1.nsw.optusnet.com.au> Mime-Version: 1.0 (generated by tm-edit 1.8) Content-Type: multipart/mixed; boundary="Multipart_Mon_Mar_25_07:48:54_2002-1" Content-Transfer-Encoding: 7bit Date: Mon, 25 Mar 2002 07:50:10 -0800 From: "Kevin Oberman" Message-Id: <20020325155010.639625D06@ptavv.es.net> Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --Multipart_Mon_Mar_25_07:48:54_2002-1 Content-Type: text/plain; charset=US-ASCII > Date: Mon, 25 Mar 2002 20:16:30 +1100 (EST) > From: Tony Maher > Sender: owner-freebsd-stable@FreeBSD.ORG > > Hello, > > cvsupped about 24 hours ago and made world. Suspended laptop (Dell Inspiron > 3500) on leaving working and when I resumed at home got the following panic. > Tried the suspend again, this time dropped into debugger but did not get > a second core file due to lack of disk space. It also appeared to be > ata related. Yes, this seems to be a common problem with the new ata code Soren merged last week. I am seeing it on my ThinkPad, as well. There are a couple of reports that the patch Ian Dowse posted back on Friday will fix the problem. I have not yet tried it, but will soon. If you don't have the message any more, you can find it at: http://groups.google.com/groups?q=Ian+Dowse+resume+group:mailing.freebsd.stable&hl=en&selm=a7gkv8% I will attach his patch. I had to strip off the HTML cruft from Google, but I think it's clean. R. Kevin Oberman, Network Engineer Energy Sciences Network (ESnet) Ernest O. Lawrence Berkeley National Laboratory (Berkeley Lab) E-mail: oberman@es.net Phone: +1 510 486-8634 --Multipart_Mon_Mar_25_07:48:54_2002-1 Content-Type: application/octet-stream; type=patch Content-Disposition: attachment; filename="ata-resume-dowse.patch" Content-Transfer-Encoding: 7bit Index: ata-all.c =================================================================== RCS file: /home/iedowse/CVS/src/sys/dev/ata/ata-all.c,v retrieving revision 1.50.2.30 diff -u -r1.50.2.30 ata-all.c --- ata-all.c 18 Mar 2002 08:37:33 -0000 1.50.2.30 +++ ata-all.c 23 Mar 2002 00:53:32 -0000 @@ -162,7 +162,7 @@ ata_attach(device_t dev) { struct ata_channel *ch; - int error, rid; + int error, rid, s; if (!dev || !(ch = device_get_softc(dev))) return ENXIO; @@ -186,6 +186,7 @@ * otherwise attach what the probe has found in ch->devices. */ if (!ata_delayed_attach) { + s = splbio(); if (ch->devices & ATA_ATA_SLAVE) if (ata_getparam(&ch->device[SLAVE], ATA_C_ATA_IDENTIFY)) ch->devices &= ~ATA_ATA_SLAVE; @@ -210,6 +211,7 @@ if (ch->devices & ATA_ATAPI_SLAVE) atapi_attach(&ch->device[SLAVE]); #endif + splx(s); } return 0; } @@ -425,7 +427,7 @@ /* apparently some devices needs this repeated */ do { - if (ata_command(atadev, command, 0, 0, 0, ATA_WAIT_INTR)) { + if (ata_command(atadev, command, 0, 0, 0, ATA_IMMEDIATE)) { ata_prtdev(atadev, "%s identify failed\n", command == ATA_C_ATAPI_IDENTIFY ? "ATAPI" : "ATA"); return -1; @@ -469,13 +471,14 @@ ata_boot_attach(void) { struct ata_channel *ch; - int ctlr; + int ctlr, s; if (ata_delayed_attach) { config_intrhook_disestablish(ata_delayed_attach); free(ata_delayed_attach, M_TEMP); ata_delayed_attach = NULL; } + s = splbio(); /* * run through all ata devices and look for real ATA & ATAPI devices @@ -522,6 +525,7 @@ atapi_attach(&ch->device[SLAVE]); } #endif + splx(s); } static void --Multipart_Mon_Mar_25_07:48:54_2002-1-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message