From delphij@hotmail.com  Thu Dec 26 01:28:19 2002
Return-Path: <delphij@hotmail.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id DA0A437B401
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 26 Dec 2002 01:28:19 -0800 (PST)
Received: from hotmail.com (f111.law10.hotmail.com [64.4.15.111])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 895D543EC2
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 26 Dec 2002 01:28:19 -0800 (PST)
	(envelope-from delphij@hotmail.com)
Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC;
	 Thu, 26 Dec 2002 01:26:56 -0800
Received: from 218.246.96.6 by lw10fd.law10.hotmail.msn.com with HTTP;
	Thu, 26 Dec 2002 09:26:56 GMT
Message-Id: <F111NqjQc1FWzVzZ96q0000cdfb@hotmail.com>
Date: Thu, 26 Dec 2002 17:26:56 +0800
From: " " <delphij@hotmail.com>
To: FreeBSD-gnats-submit@freebsd.org
Subject: amr(4) hangs system on -CURRENT or make panic, and conditionally on -STABLE

>Number:         46537
>Category:       kern
>Synopsis:       amr(4) hangs system on -CURRENT or make panic, and conditionally
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    andre
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Dec 26 01:30:00 PST 2002
>Closed-Date:    Sat Dec 27 09:40:21 PST 2003
>Last-Modified:  Sat Dec 27 09:40:21 PST 2003
>Originator:     Xin LI <delphij@frontfree.net>
>Release:        FreeBSD 5.0-CURRENT i386
>Organization:
Frontfree Technology Network - http://www.frontfree.net
>Environment:
System: FreeBSD cluster.frontfree.net 5.0-CURRENT FreeBSD 5.0-CURRENT #147: 
Thu Dec 26 04:11:28 CST 2002 
delphij@cluster.frontfree.net:/usr/obj/usr/src/sys/FIREWALL i386

>Description:
	FreeBSD 5-CURRENT hangs or panics on amr(4) driver.

	Recently our university has purchased some new servers. Among them, there 
are one Dell PowerEdge 2650 with two Pentium4-XEON 2G installed, and 2GB of 
RAM. No matter if the memory is limited to 256MB, or if the HyperThread is 
disabled or enabled.

	The server has AIC 7899 SCSI controller, and Dell Extensible RAID 
Controller(LSILogic MegaRAID having 128MB RAM on it) installed. When booting 
from 5.0-RC-20021213 CD-ROM, the system stops to respond after the following 
line is displayed on screen:

	amr0: <LSILogic MegaRAID> mem 0xf0000000-0xf7ffffff irq 5 at device 0.0 on 
pci3

	I have tried 4.7-STABLE, when ANY ONE of(and of course combined) the 
following options enabled, the system hangs on amr0 too:
	ENABLE_SSE
	SMP (with APIC_IO)
	makeoptions     CONF_CFLAGS=-fno-builtin
	options         MAXDSIZ="(2048*1024*1024)"
	options         MAXSSIZ="(2048*1024*1024)"
	options         DFLDSIZ="(2048*1024*1024)"

	What's more, amr(4) panics on HP6000 with the MegaRAID having 32MB RAM:

	amr0: <LSILogic MegaRAID> mem 0xe0000000-0xefffffff irq 5 at device 3.1 on 
pci4

	Fatal trap 12: Page fault in kernel
	fault virtual address 	= 0xde
	fault code		= supervisor read, no page present
	instruction pointer	= 0x8:0xc01a8229
	stack pointer		= 0x10:0xc0b0f9fc
	frame pointer		= 0x10:0xc0b0fa0c
	code segment		= base 0x0, limit 0xfffff, type 0x1b
				= DPL 0, pres 1, def32 1, grow 1
	processor eflags	= interrupt enabled, resume, IOPL=0
	current process		= 0 (swapper)
	kernel: type 12 trap, code = 0
	stopped at amr_alloccmd+0x19:	cmpl $0, 0(%ecx)

	This behavior doesn't appear on 5.0-DP1, I have to say, that DP1 doesn't 
have the same problem. But DP2 seemed to have the same problem, and all 
-CURRENT from that time, including all recent RCs, does have the problem.
>How-To-Repeat:
	Boot from FreeBSD 5-CURRENT installation CD-ROM on Dell PowerEdge 2650, the 
system hangs immediately after the following line:

	and the keybord stops to respond anything, including CapsLock. Seemed that 
the system completely hangs.
>Fix:
	Currently unknown, because I have final exam in these weeks. But I would be 
glad to help work out this problem in January 2003, if needed, as I am 
familiar with i386 assembly language, C and C++ language, and programming 
with hardware. I think if this problem continues, the release of 5.0 should 
be considered to be delayed, as LSI MegaRAID is widely used around the 
world.

_________________________________________________________________
Protect your PC - get McAfee.com VirusScan Online 
http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963

>Release-Note:
>Audit-Trail:

From: "Kang Liu" <lazykang@hotmail.com>
To: bug-followup@freebsd.org
Cc:  
Subject: Re: kern/46537 amr(4) hangs system on -CURRENT or make panic, and conditionally
Date: Wed, 01 Jan 2003 09:59:04 +0800

 I got the same problem when using new amr driver with dell PERC3/DC raid 
 card.
 I tried the newest source (use cvsup tag=. and tag=RELENG_5_0), but it can 
 not boot and hangs when probe amr device. I think it is a serious problem, 
 because a lot of servers use this kind of raid card.
 Here is a workaround for this pr: rollback all files in src/sys/dev/amr to 
 that dated OCT 30(or 31). I've not compare the differenet between newest 
 driver and OCT's driver, but when rollback the system works fine.
 
 PS, 4.7 stable has the same problem, rollback is temporary way to get rid of 
 this problem.
 
 Happy new year, daemons!!
 
 
 liukang=liukang->next;
 
 
 
 
 _________________________________________________________________
 Help STOP SPAM: Try the new MSN 8 and get 2 months FREE* 
 http://join.msn.com/?page=features/junkmail
 

From: "LiuKang" <lazykang@hotmail.com>
To: <freebsd-gnats-submit@FreeBSD.org>, <delphij@hotmail.com>
Cc: <emoore@FreeBSD.org>, <re@freebsd.org>
Subject: Re: kern/46537: amr(4) hangs system on -CURRENT or make panic, and conditionally
Date: Thu, 9 Jan 2003 13:11:35 +0800

 This is a multi-part message in MIME format.
 
 ------=_NextPart_000_0000_01C2B7E0.932C3360
 Content-Type: text/plain;
 	charset="us-ascii"
 Content-Transfer-Encoding: 7bit
 
 I tried to enable debug option in amr driver by adding :"CFLAGS= -O
 -pipe -DAMR_DEBUG COPTFLAGS= -O -pipe -DAMR_DEBUG" in /etc/make.conf and
 add some printf() in amr.c for debug. I think I find the problem , but I
 do not know how to solve it.
 
 In amr.c (Revision 1.38)
 Line 1008: while(sc->amr_mailbox->mb_nstatus == 0xFF);
 The value of sc->amr_mailbox->mb_nstatus is always 255, it seems that
 amr card should change the value of mb_nstatus itself. (my card is dell
 PERC3/DC)
 
 In pr 45698 http://www.freebsd.org/cgi/query-pr.cgi?pr=45698 I find
 there is the same problem in HP's raid card on 5.0.
 5.0 is about to release,  device amr is widely used in servers, I think
 this problem should be considered as critical.
 
 
 ------=_NextPart_000_0000_01C2B7E0.932C3360
 Content-Type: application/x-pkcs7-signature;
 	name="smime.p7s"
 Content-Transfer-Encoding: base64
 Content-Disposition: attachment;
 	filename="smime.p7s"
 
 MIAGCSqGSIb3DQEHAqCAMIACAQExCzAJBgUrDgMCGgUAMIAGCSqGSIb3DQEHAQAAoIIJnzCCAy0w
 ggKWoAMCAQICAQAwDQYJKoZIhvcNAQEEBQAwgdExCzAJBgNVBAYTAlpBMRUwEwYDVQQIEwxXZXN0
 ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEaMBgGA1UEChMRVGhhd3RlIENvbnN1bHRpbmcx
 KDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2VydmljZXMgRGl2aXNpb24xJDAiBgNVBAMTG1RoYXd0
 ZSBQZXJzb25hbCBGcmVlbWFpbCBDQTErMCkGCSqGSIb3DQEJARYccGVyc29uYWwtZnJlZW1haWxA
 dGhhd3RlLmNvbTAeFw05NjAxMDEwMDAwMDBaFw0yMDEyMzEyMzU5NTlaMIHRMQswCQYDVQQGEwJa
 QTEVMBMGA1UECBMMV2VzdGVybiBDYXBlMRIwEAYDVQQHEwlDYXBlIFRvd24xGjAYBgNVBAoTEVRo
 YXd0ZSBDb25zdWx0aW5nMSgwJgYDVQQLEx9DZXJ0aWZpY2F0aW9uIFNlcnZpY2VzIERpdmlzaW9u
 MSQwIgYDVQQDExtUaGF3dGUgUGVyc29uYWwgRnJlZW1haWwgQ0ExKzApBgkqhkiG9w0BCQEWHHBl
 cnNvbmFsLWZyZWV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AHBgUrDgMCBzANBggqhkiG9w0DAgIBKDAKBggqhkiG9w0CBTCBqwYJKwYBBAGC
 NxAEMYGdMIGaMIGSMQswCQYDVQQGEwJaQTEVMBMGA1UECBMMV2VzdGVybiBDYXBlMRIwEAYDVQQH
 EwlDYXBlIFRvd24xDzANBgNVBAoTBlRoYXd0ZTEdMBsGA1UECxMUQ2VydGlmaWNhdGUgU2Vydmlj
 ZXMxKDAmBgNVBAMTH1BlcnNvbmFsIEZyZWVtYWlsIFJTQSAyMDAwLjguMzACAwjxMzCBrQYLKoZI
 hvcNAQkQAgsxgZ2ggZowgZIxCzAJBgNVBAYTAlpBMRUwEwYDVQQIEwxXZXN0ZXJuIENhcGUxEjAQ
 BgNVBAcTCUNhcGUgVG93bjEPMA0GA1UEChMGVGhhd3RlMR0wGwYDVQQLExRDZXJ0aWZpY2F0ZSBT
 ZXJ2aWNlczEoMCYGA1UEAxMfUGVyc29uYWwgRnJlZW1haWwgUlNBIDIwMDAuOC4zMAIDCPEzMA0G
 CSqGSIb3DQEBAQUABIGAdZOCDtfXzpeGmYzCdSCQkJ7pWNXDgyweJysqbyEfiGZczHsF8LznrnN1
 yTK0Q5zdZcOT6IHV5a4TLGVY8Xj86SLX4liLd6fHLvJYU9nlQpiof8yU1gjn7G+dFZkazAdKL8yr
 DPR2BnBV2wLiCP2JzhahoAfsXLvM31+DT+lRmu8AAAAAAAA=
 
 ------=_NextPart_000_0000_01C2B7E0.932C3360--

From: "Kang Liu" <lazykang@hotmail.com>
To: freebsd-gnats-submit@FreeBSD.org, delphij@hotmail.com
Cc: emoore@FreeBSD.org, re@freebsd.org
Subject: Re: kern/46537: amr(4) hangs system on -CURRENT or make panic, and conditionally
Date: Thu, 09 Jan 2003 13:31:01 +0800

 I tried to enable debug option in amr driver by adding :"CFLAGS= -O
 -pipe -DAMR_DEBUG COPTFLAGS= -O -pipe -DAMR_DEBUG" in /etc/make.conf and
 add some printf() in amr.c for debug. I think I find the problem , but I
 do not know how to solve it.
 
 In amr.c (Revision 1.38)
 Line 1008: while(sc->amr_mailbox->mb_nstatus == 0xFF);
 The value of sc->amr_mailbox->mb_nstatus is always 255, it seems that
 amr card should change the value of mb_nstatus itself. (my card is dell
 PERC3/DC)
 
 In pr 45698 http://www.freebsd.org/cgi/query-pr.cgi?pr=45698 I find
 there is the same problem in HP's raid card on 5.0.
 5.0 is about to release,Since the device amr is widely used in servers,this 
 problem should be considered as critical.
 
 
 _________________________________________________________________
 MSN 8 with e-mail virus protection service: 2 months FREE* 
 http://join.msn.com/?page=features/virus
 
State-Changed-From-To: open->feedback 
State-Changed-By: andre 
State-Changed-When: Sat Dec 27 06:41:39 PST 2003 
State-Changed-Why:  
There have been many changes and fixes to the amr driver. 
Check back with Originator if fixed. 


Responsible-Changed-From-To: freebsd-bugs->andre 
Responsible-Changed-By: andre 
Responsible-Changed-When: Sat Dec 27 06:41:39 PST 2003 
Responsible-Changed-Why:  
There have been many changes and fixes to the amr driver. 
Check back with Originator if fixed. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=46537 

From: Andre Oppermann <andre@freebsd.org>
To: freebsd-gnats-submit@FreeBSD.org, delphij@hotmail.com
Cc:  
Subject: Re: kern/46537: amr(4) hangs system on -CURRENT or make panic, and
 conditionally
Date: Sat, 27 Dec 2003 15:40:32 +0100

 Xin,
 
 do you still have the problem with FreeBSD 5.2 or -CURRENT?
 There have been many fixes to the amr driver since you filed
 the PR.
 
 -- 
 Andre
 
 

From: "=?gb2312?B?WGluIExJL8Du9s4=?=" <delphij@frontfree.net>
To: "'Andre Oppermann'" <andre@FreeBSD.org>,
	<freebsd-bugs@FreeBSD.org>
Cc:  
Subject: RE: kern/46537: amr(4) hangs system on -CURRENT or make panic,
	andconditionally
Date: Sun, 28 Dec 2003 01:18:43 +0800

 This was believed to be fixed when 5.0 was released. If memory serves me
 right, it was fixed in revision 1.39 of sys/dev/amr/amr.c, and MFC'ed as
 1.36.2.2 for 5.0-RELEASE, and 1.7.2.13 for 4-STABLE.
 
 Please close this. The problem no longer exists :) Thank you for your great
 work!
 
 Xin LI
 Frontfree Technology Network
 
 _______________________________________________
 freebsd-bugs@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-bugs
 To unsubscribe, send any mail to "freebsd-bugs-unsubscribe@freebsd.org"
State-Changed-From-To: feedback->closed 
State-Changed-By: andre 
State-Changed-When: Sat Dec 27 09:39:53 PST 2003 
State-Changed-Why:  
Fixed according to Originator. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=46537 
>Unformatted:
 >on -STABLE
