From nobody@FreeBSD.org  Sat Mar 28 03:13:40 2009
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 0B4AD106566B
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 28 Mar 2009 03:13:40 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id ED4988FC0C
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 28 Mar 2009 03:13:39 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n2S3DdS1014059
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 28 Mar 2009 03:13:39 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id n2S3DdWh014058;
	Sat, 28 Mar 2009 03:13:39 GMT
	(envelope-from nobody)
Message-Id: <200903280313.n2S3DdWh014058@www.freebsd.org>
Date: Sat, 28 Mar 2009 03:13:39 GMT
From: Andreas Schwarz <freebsd.asc@schwarzes.net>
To: freebsd-gnats-submit@FreeBSD.org
Subject: kernel freeze after probing age0 (Attansic Gigabit) with ASUS M2V
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         133149
>Category:       kern
>Synopsis:       [age] [hang] kernel freeze after probing age0 (Attansic Gigabit) with ASUS M2V
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    yongari
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Mar 28 03:20:01 UTC 2009
>Closed-Date:    Wed May 20 02:46:07 UTC 2009
>Last-Modified:  Wed May 20 02:46:07 UTC 2009
>Originator:     Andreas Schwarz
>Release:        7.1-RELEASE-i386
>Organization:
>Environment:
FreeBSD  7.1-RELEASE FreeBSD 7.1-RELEASE #0: Thu Jan  1 14:37:25 UTC 2009     root@logan.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
When booting a FreeBSD 7.1 RELEASE CD (bootonly, disc1 or livefs) the kernel
hangs after probing the Attansic Gigabit onboard NIC on my ASUS M2V mainboard.

The following lines will displayed before the system freezes.

age0: <Attansic Technology Corp, L1 Gigabit Ethernet> mem 0xfbbc0000-0xfbbfffff
irq 36 at device 0.0 on pci4
age0: PCI device revision : 0x00b0
age0: Chip id/revision : 0x9006
age0: 1280 Tx FIFO, 2364 Rx FIFO
age0: MSIX count : 0
age0: MSI count : 1
age0: Using 1 MSI messages.
age0: Read request size : 512 bytes
age0: TLP payload size : 128 bytes


>How-To-Repeat:
Use an ASUS M2V mainboard (with GBit enabled) and boot a FreeBSD 7.1 
RELEASE installation CD. The problem also occur with the current 
"stable" (7.2-PRERELEASE #2). When the kernel is build without the 
age driver, the system will freeze when the age module is loaded
with kldload.

>Fix:
Deactivate the onboard GBit interface via the BIOS (not really a fix).

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: gavin 
State-Changed-When: Sun Mar 29 12:05:46 UTC 2009 
State-Changed-Why:  
To submitter: can you please try the patch at 
http://people.freebsd.org/~gavin/PRs/133149.diff 


Responsible-Changed-From-To: freebsd-bugs->gavin 
Responsible-Changed-By: gavin 
Responsible-Changed-When: Sun Mar 29 12:05:46 UTC 2009 
Responsible-Changed-Why:  
Track 

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

From: Andreas Schwarz <freebsd.asc@schwarzes.net>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/133149: kernel freeze after probing age0 (Attansic Gigabit) with ASUS M2V
Date: Sun, 29 Mar 2009 15:51:05 +0200

 Hi gavin,
 
 the patch applies without problems, but compiling the kernel (GENERIC)
 breaks 
 with an error. Source tree is synced with stable (RELENG_7).
 
 cc -c -O -pipe -march=athlon-mp -std=c99 -g -Wall -Wredundant-decls
 -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes -Wpointer-arith
 -Winline -Wcast-qual  -Wundef -Wno-pointer-sign -fformat-extensions
 -nostdinc  -I. -I/usr/src/sys -I/usr/src/sys/contrib/altq -D_KERNEL
 -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common
 -finline-limit=8000 --param inline-unit-growth=100 --param
 large-function-growth=1000  -mno-align-long-strings
 -mpreferred-stack-boundary=2  -mno-mmx -mno-3dnow -mno-sse -mno-sse2
 -mno-sse3 -ffreestanding -Werror  /usr/src/sys/dev/age/if_age.c
 /usr/src/sys/dev/age/if_age.c: In function 'age_get_macaddr':
 /usr/src/sys/dev/age/if_age.c:361: error: 'TWSI_CTRL_SW_LD_START' undeclared
 (first use in this function)
 /usr/src/sys/dev/age/if_age.c:361: error: (Each undeclared identifier is
 reported only once
 /usr/src/sys/dev/age/if_age.c:361: error: for each function it appears in.)
 *** Error code 1
 
 Stop in /usr/obj/usr/src/sys/GENERIC.
 *** Error code 1
 
 Stop in /usr/src.
 *** Error code 1
 
 Stop in /usr/src.
 
 

From: Andreas Schwarz <Andreas.Schwarz@schwarzes.net>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/133149: kernel freeze after probing age0 (Attansic Gigabit) with ASUS M2V
Date: Sun, 29 Mar 2009 18:13:20 +0200

 I've added the missing defines (from HEAD) to if_agereg.h, the 
 driver compiles and finaly works. That's fine. Thank you.
 
 #define       TWSI_CTRL_SW_LD_START           0x00000800
 #define       TWSI_CTRL_HW_LD_START           0x00001000
 #define       TWSI_CTRL_LD_EXIST              0x00400000
 
State-Changed-From-To: feedback->patched 
State-Changed-By: gavin 
State-Changed-When: Sun Mar 29 20:38:21 UTC 2009 
State-Changed-Why:  
Already fixed in HEAD in r190499 


Responsible-Changed-From-To: gavin->yongari 
Responsible-Changed-By: gavin 
Responsible-Changed-When: Sun Mar 29 20:38:21 UTC 2009 
Responsible-Changed-Why:  
Over to committer for possible MFC. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=133149 
State-Changed-From-To: patched->closed 
State-Changed-By: yongari 
State-Changed-When: Wed May 20 02:45:36 UTC 2009 
State-Changed-Why:  
MFC done. Thanks for reporting. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=133149 
>Unformatted:
