Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753666AbXE3Lo1 (ORCPT ); Wed, 30 May 2007 07:44:27 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751791AbXE3LoS (ORCPT ); Wed, 30 May 2007 07:44:18 -0400 Received: from mail-gw3.adaptec.com ([216.52.22.36]:50496 "EHLO mail-gw3.adaptec.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751641AbXE3LoQ (ORCPT ); Wed, 30 May 2007 07:44:16 -0400 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----_=_NextPart_001_01C7A2AF.D6DDC3FE" Subject: RE: kexec and aacraid broken Date: Wed, 30 May 2007 07:44:02 -0400 Message-ID: In-reply-to: <20070529191347.9b1edd8b.akpm@linux-foundation.org> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: kexec and aacraid broken Thread-Index: AceiYCvP/l9D46qiTeSEgIgBHPAJNgATQ2VA From: "Salyzyn, Mark" To: "Andrew Morton" , "Yinghai Lu" Cc: "Vivek Goyal" , "Eric W. Biederman" , "Linux Kernel Mailing List" , , "Michal Piotrowski" Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 9668 Lines: 199 This is a multi-part message in MIME format. ------_=_NextPart_001_01C7A2AF.D6DDC3FE Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: quoted-printable I believe this issue is a result of the aacraid_commit_reset patch (as posted for scsi-misc-2.6, enclosed to permit testing) not yet propagated to the 2.6.22-rc3 tree. This is the adapter taking longer than 3 minutes to start after a reset. I seriously doubt either of these patches suggested below will have an affect. And if they do, they are not root cause, one reduces the chances that the card will be reset during initialization (thus applied would likely mitigate this problem), the other prevents a panic when the Adapter is reset (removed, would result in dogs and cats sleeping with each other). Please use kernel parameter aacraid.startup_timeout=3D540 (merely larger than the default 180 seconds) when spawning the kexec or see if the aacraid_commit_reset.patch resolves the issue to confirm my hunch. Sincerely -- Mark Salyzyn > -----Original Message----- > From: Andrew Morton [mailto:akpm@linux-foundation.org]=20 > Sent: Tuesday, May 29, 2007 10:14 PM > To: Yinghai Lu > Cc: Vivek Goyal; Eric W. Biederman; AACRAID; Linux Kernel=20 > Mailing List; linux-scsi@vger.kernel.org; Michal Piotrowski > Subject: Re: kexec and aacraid broken >=20 >=20 > On Tue, 29 May 2007 18:59:32 -0700 "Yinghai Lu"=20 > wrote: >=20 > > latest tree, can not use kexec to load 2.6.22-rc3 at least. > >=20 > > got: > >=20 > > AAC0: adapter kernel panic'd fffffffd > > AAC0: adapter kernel failed to start, init status=3D0 >=20 > One of the two diffs below, I guess. Please do a `patch -R=20 > -p1' of this > email and retest? >=20 > >=20 > > but can load 2.6.21.3 > >=20 >=20 > Michal, can you please add this to the regression list? >=20 >=20 >=20 >=20 > commit 9e4d4a5d71d673901d9c1df5146ce545c2cc0cc0 > Author: Salyzyn, Mark > Date: Tue May 1 11:43:06 2007 -0400 >=20 > [SCSI] aacraid: superfluous adapter reset for IBM 8=20 > series ServeRAID controllers > =20 > The kexec patch introduced a superfluous (and otherwise=20 > inert) reset of > some adapters. The register can have a hardware default=20 > value that has > zeros for the undefined interrupts. This patch refines=20 > the test of the > interrupt enable register to focus on only the interrupts=20 > that affect > the driver in order to detect if an incomplete shutdown=20 > of the Adapter > had occurred (kdump). > =20 > Signed-off-by: Mark Salyzyn > Signed-off-by: James Bottomley >=20 > diff --git a/drivers/scsi/aacraid/rx.c b/drivers/scsi/aacraid/rx.c > index b6ee3c0..291cd14 100644 > --- a/drivers/scsi/aacraid/rx.c > +++ b/drivers/scsi/aacraid/rx.c > @@ -542,7 +542,7 @@ int _aac_rx_init(struct aac_dev *dev) > dev->a_ops.adapter_sync_cmd =3D rx_sync_cmd; > dev->a_ops.adapter_enable_int =3D aac_rx_disable_interrupt; > dev->OIMR =3D status =3D rx_readb (dev, MUnit.OIMR); > - if ((((status & 0xff) !=3D 0xff) || reset_devices) && > + if ((((status & 0x0c) !=3D 0x0c) || reset_devices) && > !aac_rx_restart_adapter(dev, 0)) > ++restart; > /* > commit a5694ec545a880f9d23463fddc894f5096cc68fa > Author: Salyzyn, Mark > Date: Mon Apr 30 13:22:24 2007 -0400 >=20 > [SCSI] aacraid: kexec fix (reset interrupt handler) > =20 > Another layer on this onion also discovered by Duane, the > interrupt enable handler also needed to be set ... The=20 > interrupt enable > was called from within the synchronous command handler. > =20 > Signed-off-by: Mark Salyzyn > Signed-off-by: James Bottomley >=20 > diff --git a/drivers/scsi/aacraid/rx.c b/drivers/scsi/aacraid/rx.c > index 0c71315..b6ee3c0 100644 > --- a/drivers/scsi/aacraid/rx.c > +++ b/drivers/scsi/aacraid/rx.c > @@ -539,6 +539,8 @@ int _aac_rx_init(struct aac_dev *dev) > } > =20 > /* Failure to reset here is an option ... */ > + dev->a_ops.adapter_sync_cmd =3D rx_sync_cmd; > + dev->a_ops.adapter_enable_int =3D aac_rx_disable_interrupt; > dev->OIMR =3D status =3D rx_readb (dev, MUnit.OIMR); > if ((((status & 0xff) !=3D 0xff) || reset_devices) && > !aac_rx_restart_adapter(dev, 0)) >=20 >=20 ------_=_NextPart_001_01C7A2AF.D6DDC3FE Content-Type: application/octet-stream; name="aacraid_commit_reset.patch" Content-Transfer-Encoding: base64 Content-Description: aacraid_commit_reset.patch Content-Disposition: attachment; filename="aacraid_commit_reset.patch" ZGlmZiAtcnUgYS9kcml2ZXJzL3Njc2kvYWFjcmFpZC9hYWNoYmEuYyBiL2RyaXZlcnMvc2NzaS9h YWNyYWlkL2FhY2hiYS5jCi0tLSBhL2RyaXZlcnMvc2NzaS9hYWNyYWlkL2FhY2hiYS5jCTIwMDct MDUtMTYgMTA6Mjk6MjUuNjk3NzM1MzY3IC0wNDAwCisrKyBiL2RyaXZlcnMvc2NzaS9hYWNyYWlk L2FhY2hiYS5jCTIwMDctMDUtMTYgMTA6Mzc6MzMuNTM3MT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pZiAocmVzdGFydCkK KwkJYWFjX2NvbW1pdCA9IDE7CiAJLyoKIAkgKglGaWxsIGluIHRoZSBjb21tb24gZnVuY3Rpb24g ZGlzcGF0Y2ggdGFibGUuCiAJICovCg== ------_=_NextPart_001_01C7A2AF.D6DDC3FE-- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/