Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 2 Jan 2001 15:09:45 +0200 (IST)
From:      yonatan@xpert.com
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   kern/24019: Frequent panics in ep driver
Message-ID:  <200101021309.f02D9jd00402@Temujin.xpert.com>
Resent-Message-ID: <200101021320.f02DK1S51274@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         24019
>Category:       kern
>Synopsis:       Frequent panics in ep driver, 3c556 pcmcia
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jan 02 05:20:01 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     Yonatan
>Release:        FreeBSD 4.2-STABLE i386
>Organization:
>Environment:
4.2-STABLE of 1/1/2001 on IBM Thinkpad 600E

# kernel config
machine		i386
cpu		I686_CPU
ident		TEMUJIN
maxusers	100
makeoptions	KERNEL=TEMUJIN

makeoptions	DEBUG=-g		#Build kernel with gdb(1) debug symbols

#FIREWALLING:
options         IPFIREWALL              #firewall
options         IPFIREWALL_VERBOSE      #print information about
                                        # dropped packets
options         IPFIREWALL_FORWARD      #enable transparent proxy support
options         IPFIREWALL_VERBOSE_LIMIT=100    #limit verbosity
options         IPFIREWALL_DEFAULT_TO_ACCEPT    #allow everything by default
options         IPDIVERT                #divert sockets
options         IPSTEALTH               #support for stealth forwarding
#options		TCPDEBUG

# IPSEC here:
options         IPSEC                   #IP security
options         IPSEC_ESP               #IP security (crypto; define w/ IPSEC)
options         IPSEC_DEBUG             #debug for IP security
pseudo-device   gif     4               #IPv6 and IPv4 tunneling

options		NSWAPDEV=1
options		NMBCLUSTERS=4096
options		CPU_FASTER_5X86_FPU
options		CPU_SUSP_HLT
options		DDB
#options		INVARIANTS
#options		INVARIANT_SUPPORT
options		ETHER_II
options		ETHER_8023
options		ETHER_8022
#options		PPP_BSDCOMP
#options		PPP_DEFLATE
#options		PPP_FILTER
options		TCP_RESTRICT_RST
options		TCP_DROP_SYNFIN
options		NTFS
pseudo-device	speaker
pseudo-device	snp	3
device		pcm
#options		PNPBIOS
options		EXT2FS

device		smbus
device		smb
device		intpm

options		PSM_HOOKRESUME

options 	INET			#InterNETworking
options 	FFS			#Berkeley Fast Filesystem
options 	FFS_ROOT		#FFS usable as root device [keep this!]
options 	SOFTUPDATES		#Enable FFS soft updates support
options 	MFS			#Memory Filesystem
options 	MD_ROOT			#MD is a potential root device
options 	MSDOSFS			#MSDOS Filesystem
options 	CD9660			#ISO 9660 Filesystem
options 	PROCFS			#Process filesystem
options 	COMPAT_43		#Compatible with BSD 4.3 [KEEP THIS!]
options 	UCONSOLE		#Allow users to grab the console
options 	USERCONFIG		#boot -c editor
options 	VISUAL_USERCONFIG	#visual boot -c editor
options 	KTRACE			#ktrace(1) support
options 	SYSVSHM			#SYSV-style shared memory
options 	SYSVMSG			#SYSV-style message queues
options 	SYSVSEM			#SYSV-style semaphores
options 	P1003_1B		#Posix P1003_1B real-time extensions
options 	_KPOSIX_PRIORITY_SCHEDULING
options		ICMP_BANDLIM		#Rate limit bad replies
options 	KBD_INSTALL_CDEV	# install a CDEV entry in /dev

device		isa
#device		eisa
device		pci

# Floppy drives
device		fdc0	at isa? port IO_FD1 irq 6 drq 2
device		fd0	at fdc0 drive 0

# ATA and ATAPI devices
#device		ata0	at isa? port IO_WD1 irq 14
#device		ata1	at isa? port IO_WD2 irq 15
device		ata
device		atadisk			# ATA disk drives
device		atapicd			# ATAPI CDROM drives
#device		atapifd			# ATAPI floppy drives
#device		atapist			# ATAPI tape drives
#options 	ATA_STATIC_ID		#Static device numbering
options 	ATA_ENABLE_ATAPI_DMA	#Enable DMA on ATAPI devices

# atkbdc0 controls both the keyboard and the PS/2 mouse
device		atkbdc0	at isa? port IO_KBD
device		atkbd0	at atkbdc? irq 1 flags 0x3
device		psm0	at atkbdc? irq 12

device		vga0	at isa?

# splash screen/screen saver
pseudo-device	splash

# syscons is the default console driver, resembling an SCO console
device		sc0	at isa? flags 0x100

# Floating point support - do not disable.
device		npx0	at nexus? port IO_NPX irq 13

# Power management support (see LINT for more options)
device		apm0    at nexus?

# PCCARD (PCMCIA) support
device		card
device		pcic0	at isa?

# Serial (COM) ports
device		sio0	at isa? port IO_COM1 flags 0x10 irq 4
device		sio1	at isa? port IO_COM2 irq 3
device		sio2	at isa? disable port IO_COM3 irq 5
device		sio3	at isa? disable port IO_COM4 irq 9

# Parallel port
device		ppc0	at isa?  irq 7
device		ppbus		# Parallel port bus (required)
device		lpt		# Printer
#device		plip		# TCP/IP over parallel
#device		ppi		# Parallel port interface device
#device		vpo		# Requires scbus and da

# PCI Ethernet NICs that use the common MII bus controller code.
device		miibus		# MII bus support

# ISA Ethernet NICs.
device		ep

# Pseudo devices - the number indicates how many units to allocated.
pseudo-device	loop		# Network loopback
pseudo-device	ether		# Ethernet support
#pseudo-device	sl	1	# Kernel SLIP
#pseudo-device	ppp	1	# Kernel PPP
pseudo-device	tun		# Packet tunnel.
pseudo-device	pty		# Pseudo-ttys (telnet etc)
pseudo-device	md		# Memory "disks"
pseudo-device	gif	4	# IPv6 and IPv4 tunneling
#pseudo-device	faith	1	# IPv6-to-IPv4 relaying (translation)

# The `bpf' pseudo-device enables the Berkeley Packet Filter.
# Be aware of the administrative consequences of enabling this!
pseudo-device	bpf		#Berkeley packet filter

# USB support
#device		uhci		# UHCI PCI->USB interface
#device		ohci		# OHCI PCI->USB interface
device		usb		# USB Bus (required)
device		ugen		# Generic

device		agp


dmesg:

Copyright (c) 1992-2001 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
	The Regents of the University of California. All rights reserved.
FreeBSD 4.2-STABLE #0: Tue Jan  2 09:41:30 IST 2001
    root@Temujin.xpert.com:/usr/obj/usr/src/sys/TEMUJIN
Timecounter "i8254"  frequency 1193182 Hz
CPU: Pentium II/Pentium II Xeon/Celeron (363.96-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0x66a  Stepping = 10
  Features=0x183f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR>
real memory  = 134021120 (130880K bytes)
avail memory = 126959616 (123984K bytes)
Preloaded elf kernel "kernel" at 0xc0355000.
Pentium Pro MTRR support enabled
md0: Malloc disk
apm0: <APM BIOS> on motherboard
apm: found APM BIOS v1.2, connected at v1.2
npx0: <math processor> on motherboard
npx0: INT 16 interface
pcib0: <Intel 82443BX (440 BX) host to PCI bridge> on motherboard
pci0: <PCI bus> on pcib0
agp0: <Intel 82443BX (440 BX) host to PCI bridge> mem 0x40000000-0x43ffffff at device 0.0 on pci0
pcib1: <Intel 82443BX (440 BX) PCI-PCI (AGP) bridge> at device 1.0 on pci0
pci1: <PCI bus> on pcib1
pci1: <NeoMagic MagicMedia 256AV SVGA controller> at 0.0 irq 11
pcic-pci0: <TI PCI-1251 PCI-CardBus Bridge> mem 0x50102000-0x50102fff irq 11 at device 2.0 on pci0
pcic-pci0: TI12XX PCI Config Reg: [ring enable][speaker enable][pwr save][CSC parallel isa irq]
pcic-pci1: <TI PCI-1251 PCI-CardBus Bridge> mem 0x50101000-0x50101fff irq 11 at device 2.1 on pci0
pcic-pci1: TI12XX PCI Config Reg: [ring enable][speaker enable][pwr save][CSC parallel isa irq]
csa0: <Crystal Semiconductor CS4610/4611 Audio accelerator> mem 0x50000000-0x500fffff,0x50100000-0x50100fff irq 11 at device 6.0 on pci0
device_probe_and_attach: csa0 attach returned 6
isab0: <Intel 82371AB PCI to ISA bridge> at device 7.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <Intel PIIX4 ATA33 controller> port 0xfcf0-0xfcff at device 7.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
pci0: <Intel 82371AB/EB (PIIX4) USB controller> at 7.2 irq 11
intpm0: <Intel 82371AB Power management controller> port 0xefa0-0xefaf irq 9 at device 7.3 on pci0
intpm0: I/O mapped efa0
intpm0: intr IRQ 9 enabled revision 0
smbus0: <System Management Bus> on intsmb0
smb0: <SMBus general purpose I/O> on smbus0
intpm0: PM I/O mapped ef00 
fdc0: <NEC 72065B or clone> at port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on isa0
fdc0: FIFO enabled, 8 bytes threshold
atkbdc0: <Keyboard controller (i8042)> at port 0x60,0x64 on isa0
atkbd0: <AT Keyboard> flags 0x3 irq 1 on atkbdc0
kbd0 at atkbd0
psm0: <PS/2 Mouse> irq 12 on atkbdc0
psm0: model Generic PS/2 mouse, device ID 0
vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
sc0: <System console> at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
pcic0: <Intel i82365> at port 0x3e0-0x3e1 on isa0
pcic0: Polling mode
pccard0: <PC Card bus -- kludge version> on pcic0
pccard1: <PC Card bus -- kludge version> on pcic0
sio0: configured irq 4 not in bitmap of probed irqs 0
sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
sio0: type 8250
sio1: configured irq 3 not in bitmap of probed irqs 0
ppc0: cannot reserve I/O port range
IP packet filtering initialized, divert enabled, rule-based forwarding enabled, default to accept, logging limited to 100 packets/entry by default
IPsec: Initialized Security Association Processing.
ad0: 6149MB <HITACHI_DK239A-65B> [13328/15/63] at ata0-master UDMA33
acd0: CDROM <TOSHIBA CD-ROM XM-1902B> at ata0-slave using WDMA2
Mounting root from ufs:/dev/ad0s2a
pccard: card inserted, slot 1
WARNING: / was not properly dismounted
ep0: <3Com 3C556> at port 0x240-0x25f irq 3 slot 1 on pccard1
ep0: Ethernet address 00:00:86:50:d7:e2

>Description:

Script started on Tue Jan  2 14:58:51 2001
Temujin:/root# gdb -k /usr/obj/usr/src/sys/TEMUJIN/kernel.debug /usr/crash/vmcore.0 
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-unknown-freebsd"...
IdlePTD 3620864
initial pcb at 2db1c0
panicstr: from debugger
panic messages:
---
Fatal trap 12: page fault while in kernel mode
fault virtual address	= 0x75c01500
fault code		= supervisor read, page not present
instruction pointer	= 0x8:0xc012a040
stack pointer	        = 0x10:0xc0290c48
frame pointer	        = 0x10:0xc0290c70
code segment		= base 0x0, limit 0xfffff, type 0x1b
			= DPL 0, pres 1, def32 1, gran 1
processor eflags	= interrupt enabled, resume, IOPL = 0
current process		= Idle
interrupt mask		= net bio cam 
panic: from debugger
panic: from debugger
Uptime: 4h7m20s

dumping to dev #ad/0x30001, offset 262528
dump ata0: resetting devices .. done
127 126 125 124 123 122 121 120 119 118 117 116 115 114 113 112 111 110 109 108 107 106 105 104 103 102 101 100 99 98 97 96 95 94 93 92 91 90 89 88 87 86 85 84 83 82 81 80 79 78 77 76 75 74 73 72 71 70 69 68 67 66 65 64 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 
---
#0  dumpsys () at /usr/src/sys/kern/kern_shutdown.c:469
469		if (dumping++) {
(kgdb) bt
#0  dumpsys () at /usr/src/sys/kern/kern_shutdown.c:469
#1  0xc0150ef8 in boot (howto=260) at /usr/src/sys/kern/kern_shutdown.c:309
#2  0xc0151299 in panic (fmt=0xc0258d34 "from debugger")
    at /usr/src/sys/kern/kern_shutdown.c:556
#3  0xc0126d79 in db_panic (addr=-1072521152, have_addr=0, count=-1, 
    modif=0xc0290ab4 "") at /usr/src/sys/ddb/db_command.c:433
#4  0xc0126d17 in db_command (last_cmdp=0xc029518c, cmd_table=0xc0294fec, 
    aux_cmd_tablep=0xc02d667c) at /usr/src/sys/ddb/db_command.c:333
#5  0xc0126dde in db_command_loop () at /usr/src/sys/ddb/db_command.c:455
#6  0xc0128f7f in db_trap (type=12, code=0) at /usr/src/sys/ddb/db_trap.c:71
#7  0xc0237938 in kdb_trap (type=12, code=0, regs=0xc0290c08)
    at /usr/src/sys/i386/i386/db_interface.c:158

#8  0xc0243d8c in trap_fatal (frame=0xc0290c08, eva=1975522560)
    at /usr/src/sys/i386/i386/trap.c:946
#9  0xc0243a4d in trap_pfault (frame=0xc0290c08, usermode=0, eva=1975522560)
    at /usr/src/sys/i386/i386/trap.c:844
#10 0xc02435db in trap (frame={tf_fs = -1066139632, tf_es = -1066139632, 
      tf_ds = -1066139632, tf_edi = 1, tf_esi = 1, tf_ebp = -1071051664, 
      tf_isp = -1071051724, tf_ebx = 7225416, tf_edx = 1975522560, 
      tf_ecx = -1052932096, tf_eax = 7225416, tf_trapno = 12, tf_err = 0, 
      tf_eip = -1072521152, tf_cs = 8, tf_eflags = 66054, tf_esp = 8208, 
      tf_ss = -1052932096}) at /usr/src/sys/i386/i386/trap.c:443
#11 0xc012a040 in epread (sc=0xc13d8800) at /usr/src/sys/dev/ep/if_ep.c:690
#12 0xc0129ebb in ep_intr (arg=0xc13d8800) at /usr/src/sys/dev/ep/if_ep.c:572
---Type <return> to continue, or q <return> to quit---
#13 0xc023978a in vec3 ()
#14 0xc0198ce7 in ether_output (ifp=0xc13d8800, m=0xc0745100, dst=0xc0290dfc, 
    rt0=0xc147e100) at /usr/src/sys/net/if_ethersubr.c:354
#15 0xc01af247 in ip_output (m0=0xc0745100, opt=0x0, ro=0xc0290df8, flags=0, 
    imo=0x0) at /usr/src/sys/netinet/ip_output.c:787
#16 0xc01acd9e in icmp_send (m=0xc0745100, opts=0x0)
    at /usr/src/sys/netinet/ip_icmp.c:753
#17 0xc01acd1f in icmp_reflect (m=0xc0745100)
    at /usr/src/sys/netinet/ip_icmp.c:715
#18 0xc01ac631 in icmp_error (n=0xc0751600, type=5, code=1, dest=3733244871, 
    destifp=0x0) at /usr/src/sys/netinet/ip_icmp.c:225
#19 0xc01ae5c7 in ip_forward (m=0xc0758900, srcrt=0)
    at /usr/src/sys/netinet/ip_input.c:1659
#20 0xc01ad49b in ip_input (m=0xc0758900)
    at /usr/src/sys/netinet/ip_input.c:563
#21 0xc01ad807 in ipintr () at /usr/src/sys/netinet/ip_input.c:759
(kgdb) up 11
#11 0xc012a040 in epread (sc=0xc13d8800) at /usr/src/sys/dev/ep/if_ep.c:690
690		goto out;
(kgdb) list
685			sc->rx_overrunf++;
686		    else
687			sc->rx_overrunl++;
688	#endif
689		}
690		goto out;
691	    }
692	    rx_fifo = rx_fifo2 = status & RX_BYTES_MASK;
693	
694	    if (EP_FTST(sc, F_RX_FIRST)) {
(kgdb) up
#12 0xc0129ebb in ep_intr (arg=0xc13d8800) at /usr/src/sys/dev/ep/if_ep.c:572
572		    epread(sc);
(kgdb) list
567	
568		/* first acknowledge all interrupt sources */
569		outw(BASE + EP_COMMAND, ACK_INTR | (status & S_MASK));
570	
571		if (status & (S_RX_COMPLETE | S_RX_EARLY)) {
572		    epread(sc);
573		    continue;
574		}
575		if (status & S_TX_AVAIL) {
576		    /* we need ACK */
(kgdb) up
#13 0xc023978a in vec3 ()
(kgdb) list
577		    ifp->if_timer = 0;
578		    ifp->if_flags &= ~IFF_OACTIVE;
579		    GO_WINDOW(1);
580		    inw(BASE + EP_W1_FREE_TX);
581		    ep_if_start(ifp);
582		}
583		if (status & S_CARD_FAILURE) {
584		    ifp->if_timer = 0;
585	#ifdef EP_LOCAL_STATS
586		    printf("\nep%d:\n\tStatus: %x\n", sc->unit, status);
(kgdb) up
#14 0xc0198ce7 in ether_output (ifp=0xc13d8800, m=0xc0745100, dst=0xc0290dfc, 
    rt0=0xc147e100) at /usr/src/sys/net/if_ethersubr.c:354
354		return ether_output_frame(ifp, m);
(kgdb) list
349			if (m == NULL)
350				return (0);
351		}
352	
353		/* Continue with link-layer output */
354		return ether_output_frame(ifp, m);
355	}
356	
357	/*
358	 * Ethernet link layer output routine to send a raw frame to the device.
(kgdb) quit
Temujin:/root# ^Dexit

Script done on Tue Jan  2 14:59:34 2001

>How-To-Repeat:

Leave the computer, go to lunch (preferrable Italian cusine), come back and
wonder.

>Fix:
It seems that there's interrupt when interrupts should be disabled.
goto out causes a page fault, which is also weird.. Perhaps the address is
wrong.

I wish I knew.. :(

>Release-Note:
>Audit-Trail:
>Unformatted:


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200101021309.f02D9jd00402>