Subject: panic: sched_lock?
To: None <tech-smp@netbsd.org>
From: None <kay@kaynet.or.jp>
List: tech-smp
Date: 09/02/2000 09:12:57
  Building kernel is no problem. But, building user land my box was
paniced.

  my kernel is last night cvsed, and compiled.

main board:	EPoX KP6-BS
cpu:		PentiumIII 450MHz x 2
memoery:	128MB SDRAM(PC100)
scsi:		TEKRAM DC390U compatible

following messages are hand copyed.

panic: kernel diagnostic assertion "_simple_lock_held((&sched_lock)) == 0 failded: "../../../../kern/kern_synch.c", 617

syncing disks... simple_lock: locking against myself
lock: 0xc4115b0, currently at: ../../../../kern/kern_synch.c: 1026
on cpu1
last locked: ../../../../kern/kern_synch.c: 619
last unlocked: ../../../../kern/kern_synch.c: 621
sd0(siop0:0:0): command timeout

dmesg:
NetBSD 1.5E (HELEN) #0: Sat Sep  2 00:34:32 JST 2000
    root@helen.kaynet.or.jp:/usr/src/sys/arch/i386/compile/HELEN
total memory = 127 MB
avail memory = 68484 KB
using 11424 buffers containing 52160 KB of memory
biostramp installed @ 1000
BIOS32 rev. 0 found at 0xfb310
PCI BIOS rev. 2.1 found at 0xfb340
pcibios: config mechanism [1][x], special cycles [1][x], last bus 1
PCI IRQ Routing Table rev. 1.0 found at 0xfde50, size 144 bytes (7 entries)
PCI Interrupt Router at 000:07:0 (Intel 82371SB PCI-to-ISA Bridge (PIIX3))
PCI Exclusive IRQs: 10 11
PIR Entry 0:
	Bus: 0  Device: 8
		INTA: link 0x60 bitmap 0xdeb8
		INTB: link 0x61 bitmap 0xdeb8
		INTC: link 0x62 bitmap 0xdeb8
		INTD: link 0x63 bitmap 0xdeb8
PIR Entry 1:
	Bus: 0  Device: 9
		INTA: link 0x61 bitmap 0xdeb8
		INTB: link 0x62 bitmap 0xdeb8
		INTC: link 0x63 bitmap 0xdeb8
		INTD: link 0x60 bitmap 0xdeb8
PIR Entry 2:
	Bus: 0  Device: 10
		INTA: link 0x62 bitmap 0xdeb8
		INTB: link 0x63 bitmap 0xdeb8
		INTC: link 0x60 bitmap 0xdeb8
		INTD: link 0x61 bitmap 0xdeb8
PIR Entry 3:
	Bus: 0  Device: 11
		INTA: link 0x63 bitmap 0xdeb8
		INTB: link 0x60 bitmap 0xdeb8
		INTC: link 0x61 bitmap 0xdeb8
		INTD: link 0x62 bitmap 0xdeb8
PIR Entry 4:
	Bus: 0  Device: 12
		INTA: link 0x62 bitmap 0xdeb8
		INTB: link 0x63 bitmap 0xdeb8
		INTC: link 0x60 bitmap 0xdeb8
		INTD: link 0x61 bitmap 0xdeb8
PIR Entry 5:
	Bus: 0  Device: 7
		INTA: link 0x60 bitmap 0xdeb8
		INTB: link 0x61 bitmap 0xdeb8
		INTC: link 0x62 bitmap 0xdeb8
		INTD: link 0x63 bitmap 0xdeb8
PIR Entry 6:
	Bus: 0  Device: 1
		INTA: link 0x60 bitmap 0xdeb8
		INTB: link 0x61 bitmap 0xdeb8
		INTC: link 0x62 bitmap 0xdeb8
		INTD: link 0x63 bitmap 0xdeb8
pciintr_link_fixup: PIRQ 0x00 already connected to IRQ 11
pciintr_link_fixup: PIRQ 0x01 not connected
pciintr_link_fixup: PIRQ 0x02 not connected
pciintr_link_fixup: PIRQ 0x03 already connected to IRQ 10
pciintr_link_fixup (stage 2): assigning IRQ 10 to PIRQ 0x01
pciintr_link_fixup (stage 2): assigning IRQ 10 to PIRQ 0x02
pciintr_link_route: route of PIRQ 0x00 -> IRQ 11 preserved BIOS setting
pciintr_link_route: route of PIRQ 0x03 -> IRQ 10 preserved BIOS setting
------------------------------------------
  device vendor product pin PIRQ IRQ stage
------------------------------------------
000:07:2 0x8086 0x7112   D  0x03  10  0    already assigned
000:08:0 0x1011 0x0009   A  0x00  11  0    already assigned
000:11:0 0x1000 0x000f   A  0x03  10  0    already assigned
------------------------------------------
PCI bridge 0: primary 0, secondary 1, subordinate 1
PCI bus #1 is the last bus
[System BIOS Setting]-----------------------
  device vendor product
  register space address    size
--------------------------------------------
000:00:0 0x8086 0x7190 
	10h mem  0xe0000000 0x04000000
		[OK]
000:01:0 0x8086 0x7191 
		[OK]
000:07:0 0x8086 0x7110 
		[OK]
000:07:1 0x8086 0x7111 
	20h port 0x0000f000 0x00000010
		[OK]
000:07:2 0x8086 0x7112 
	20h port 0x0000e000 0x00000020
		[OK]
000:07:3 0x8086 0x7113 
		[OK]
000:08:0 0x1011 0x0009 
	10h port 0x0000e400 0x00000080
	14h mem  0xe9002000 0x00000080
		[OK]
000:11:0 0x1000 0x000f 
	10h port 0x0000e800 0x00000100
	14h mem  0xe9000000 0x00000100
	18h mem  0xe9001000 0x00001000
		[OK]
001:00:0 0x8086 0x7800 
	10h mem  0xe6000000 0x01000000
	14h mem  0xe5000000 0x00080000
		[OK]
--------------------------[  0 devices bogus]
 Physical memory end: 0x07fef000
 PCI memory mapped I/O space start: 0x08000000
mainbus0 (root)
mainbus0: scanning 0x9fc00 to 0x9fff0 for MP signature
mainbus0: scanning 0x9f800 to 0x9fbf0 for MP signature
mainbus0: scanning 0xf0000 to 0xffff0 for MP signature
mainbus0: MP floating pointer found in bios at 0xf5550
mainbus0: MP config table at 0xf1400, 260 bytes long
mainbus0: Intel MP Specification (Version 1.1)
mainbus0: MP OEM OEM00000 Product PROD00000000
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: family 6 model 7 step 2
cpu0: Intel Pentium III (686-class)
cpu0: features fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
cpu0: features fbff<PGE,MCA,CMOV>
cpu0: calibrating local timer
cpu0: apic clock running at 100 MHz
cpu0: kstack at 0xefe14000 for 8192 bytes
cpu0: idle pcb at 0xefe14000, idle sp at 0xefe15fa0
cpu1 at mainbus0: apid 1 (application processor)
cpu1: family 6 model 7 step 2
cpu1: Intel Pentium III (686-class)
cpu1: features fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
cpu1: features fbff<PGE,MCA,CMOV>
cpu1: kstack at 0xefe16000 for 8192 bytes
cpu1: idle pcb at 0xefe16000, idle sp at 0xefe17fa0
ioapic0 at mainbus0 apid 2 (I/O APIC)
ioapic0: pa 0xfec00000, virtual wire mode, version 11, 24 pins
ioapic0: int0 attached to ExtINT (type 3<type=3=ExtINT> flags 0<pol=0,trig=0>)
ioapic0: int1 attached to isa0 irq 1 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int2 attached to isa0 irq 0 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int3 attached to isa0 irq 3 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int4 attached to isa0 irq 4 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int5 attached to isa0 irq 5 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int6 attached to isa0 irq 6 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int7 attached to isa0 irq 7 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int8 attached to isa0 irq 8 (type 0<type=0> flags 5<pol=1=Act Hi,trig=1=Edge>)
ioapic0: int9 attached to isa0 irq 9 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int12 attached to isa0 irq 12 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int13 attached to isa0 irq 13 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int14 attached to isa0 irq 14 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int15 attached to isa0 irq 15 (type 0<type=0> flags 0<pol=0,trig=0>)
ioapic0: int16 attached to isa0 irq 11 (type 0<type=0> flags f<pol=3=Act Lo,trig=3=Level>)
ioapic0: int19 attached to isa0 irq 10 (type 0<type=0> flags f<pol=3=Act Lo,trig=3=Level>)
local apic: int0 attached to ExtINT (type 3<type=3=ExtINT> flags 0<pol=0,trig=0>)
local apic: int1 attached to NMI (type 1<type=1=NMI> flags 0<pol=0,trig=0>)
pnpbios0 at mainbus0: code f0000, data f0000, entry bf08, control 0 eventp f0000
pnpbios0: nodes 14, max len 98
PNP0000 (io 20-21 a0-a1, irq 2) at pnpbios0 index 0 ignored
PNP0200 (io 0-f 81-83 87 89-8b 8f-91 c0-df, dma 4) at pnpbios0 index 1 ignored
PNP0100 (io 40-43, irq 0) at pnpbios0 index 2 ignored
PNP0B00 (io 70-71, irq 8) at pnpbios0 index 3 ignored
PNP0303 (io 60 64, irq 1) at pnpbios0 index 4 ignored
PNP0800 (io 61) at pnpbios0 index 5 ignored
PNP0C04 (io f0-ff, irq 13) at pnpbios0 index 6 ignored
PNP0C01 (mem 0-9ffff fffe0000-ffffffff fec00000-fec0ffff fee00000-fee0ffff 100000-7ffffff) at pnpbios0 index 7 ignored
PNP0C02 (mem f0000-f3fff f4000-f7fff f8000-fffff ca200-cbfff) at pnpbios0 index 8 ignored
PNP0A03 (io 294-297 4d0-4d1 cf8-cff 480-48f 4000-403f 5000-501f) at pnpbios0 index 9 ignored
com0 at pnpbios0 index 12 (PNP0501)
com0: io 3f8-3ff, irq 4
com0: ns16550a, working fifo
PNP0700 (io 3f2-3f5, irq 6, dma 2) at pnpbios0 index 13 ignored
lpt0 at pnpbios0 index 15 (PNP0401)
lpt0: io 378-37f 778-77a, irq 7, dma 3
com1 at pnpbios0 index 16 (PNP0501)
com1: io 2f8-2ff, irq 3
com1: ns16550a, working fifo
pci0 at mainbus0 bus 0: configuration mode 1
pci0: i/o space, memory space enabled
pchb0 at pci0 dev 0 function 0
pchb0: Intel 82443BX Host Bridge/Controller (rev. 0x03)
ppb0 at pci0 dev 1 function 0: Intel 82443BX AGP Interface (rev. 0x03)
pci1 at ppb0 bus 1
pci1: i/o space, memory space enabled
vga0 at pci1 dev 0 function 0: Intel i740 Graphics Accelerator (rev. 0x21)
wsdisplay0 at vga0: console (80x25, vt100 emulation)
pcib0 at pci0 dev 7 function 0
pcib0: Intel 82371AB PCI-to-ISA Bridge (PIIX4) (rev. 0x02)
pciide0 at pci0 dev 7 function 1: Intel 82371AB IDE controller (PIIX4) (rev. 0x01)
pciide0: bus-master DMA support present
pciide0: primary channel wired to compatibility mode
atapibus0 at pciide0 channel 0
cd0 at atapibus0 drive 0: <HITACHI CDR-8335, , 0008> type 5 cdrom removable
cd0: 32-bit data port
cd0: drive supports PIO mode 4, DMA mode 2
pciide0: primary channel interrupting at irq 14
cd0(pciide0:0:0): using PIO mode 4, DMA mode 2 (using DMA data transfers)
pciide0: secondary channel wired to compatibility mode
pciide0: disabling secondary channel (no drives)
uhci0 at pci0 dev 7 function 2: Intel 82371AB USB Host Controller (PIIX4) (rev. 0x01)
pci_intr_map: no MP mapping found
uhci0: interrupting at irq 10
usb0 at uhci0: USB revision 1.0
uhub0 at usb0
uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
Intel 82371AB Power Management Controller (PIIX4) (miscellaneous bridge, revision 0x02) at pci0 dev 7 function 3 not configured
de0 at pci0 dev 8 function 0
pci_intr_map: no MP mapping found
de0: interrupting at irq 11
de0: 21140A [10-100Mb/s] pass 2.2
de0: address 00:40:05:a7:d2:29
siop0 at pci0 dev 11 function 0: Symbios Logic 53c875 (ultra-wide scsi)
siop0: using on-board RAM
pci_intr_map: no MP mapping found
siop0: interrupting at irq 10
scsibus0 at siop0: 16 targets, 8 luns per target
isa0 at pcib0
pckbc0 at isa0 port 0x60-0x64
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pmsprobe: reset error 5
pmsiprobe: reset error 5
lm0 at isa0 port 0x290-0x297: LM78J
pcppi0 at isa0 port 0x61
midi0 at pcppi0: PC speaker
spkr0 at pcppi0
sysbeep0 at pcppi0
isapnp0 at isa0 port 0x279: ISA Plug 'n Play device support
npx0 at isa0 port 0xf0-0xff: using exception 16
fdc0 at isa0 port 0x3f0-0x3f7 irq 6 drq 2
fd0 at fdc0 drive 0: density unknown
pcic0 at isa0 port 0x3e0-0x3e1 iomem 0xd0000-0xdffff
pcic0: controller 0 (Cirrus PD672X) has sockets A and B
pcic0: controller 1 (Intel 82365SL Revision 1) has no sockets
pcmcia0 at pcic0 controller 0 socket 0
pcmcia1 at pcic0 controller 0 socket 1
isapnp0: no ISA Plug 'n Play devices found
apm0 at mainbus0: Power Management spec V1.2 (slowidle)
apm: 0 batteries, global standby, global suspend, rtimer standby, rtimer suspend, internal standby, internal suspend
biomask 0 netmask 0 ttymask 0
cpu0: prelint0 700<vector=0,delmode=7,dest=0> 0<target=0>
cpu0: prelint1 400<vector=0,delmode=4,dest=0> 0<target=0>
cpu0: timer0 300d0<vector=d0,delmode=0,masked,dest=0> 0<target=0>
cpu0: pcint0 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
cpu0: lint0 10700<vector=0,delmode=7,masked,dest=0> 0<target=0>
cpu0: lint1 400<vector=0,delmode=4,dest=0> 0<target=0>
cpu0: err0 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: enabling
ioapic0: int0 10700<vector=0,delmode=7,masked,dest=0> 0<target=0>
ioapic0: int1 1a0<vector=a0,delmode=1,dest=0> 0<target=0>
ioapic0: int2 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int3 1e1<vector=e1,delmode=1,dest=0> 0<target=0>
ioapic0: int4 1e2<vector=e2,delmode=1,dest=0> 0<target=0>
ioapic0: int5 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int6 170<vector=70,delmode=1,dest=0> 0<target=0>
ioapic0: int7 1a1<vector=a1,delmode=1,dest=0> 0<target=0>
ioapic0: int8 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int9 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int10 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int11 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int12 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int13 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int14 171<vector=71,delmode=1,dest=0> 0<target=0>
ioapic0: int15 10100<vector=0,delmode=1,masked,dest=0> 0<target=0>
ioapic0: int16 a181<vector=81,delmode=1,actlo,level,dest=0> 0<target=0>
ioapic0: int17 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int18 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int19 a172<vector=72,delmode=1,actlo,level,dest=0> 0<target=0>
ioapic0: int20 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int21 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int22 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
ioapic0: int23 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
scsibus0: waiting 2 seconds for devices to settle...
de0: setting full duplex.
de0: enabling Full Duplex 100baseTX port
sd0 at scsibus0 target 0 lun 0: <SEAGATE, ST32151N, 0542> SCSI2 0/direct fixed
siop0: target 0 now synchronous at 10.0Mhz, offset 15
sd0: 2049 MB, 4177 cyl, 8 head, 125 sec, 512 bytes/sect x 4197405 sectors
freed vector e1
ioapic0: int3 1e1<vector=e1,delmode=1,dest=0> 0<target=0>
pcic0: using irq 3 for socket events
raidattach: Asked for 4 units
Kernelized RAIDframe activated
Searching for raid components...
IPsec: Initialized Security Association Processing.
boot device: sd0
root on sd0a dumps on sd0b
mountroot: trying coda...
mountroot: trying msdos...
mountroot: trying cd9660...
mountroot: trying ntfs...
mountroot: trying nfs...
mountroot: trying lfs...
mountroot: trying ext2fs...
mountroot: trying ffs...
root file system type: ffs
cpu1: starting
cpu1: prelint0 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
cpu1: prelint1 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
cpu1: timer0 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
cpu1: pcint0 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
cpu1: lint0 10700<vector=0,delmode=7,masked,dest=0> 0<target=0>
cpu1: lint1 400<vector=0,delmode=4,dest=0> 0<target=0>
cpu1: err0 10000<vector=0,delmode=0,masked,dest=0> 0<target=0>
cpu1: CPU 1 running
init: copying out path `/sbin/init' 11
wsdisplay0: screen 1 added (80x25, vt100 emulation)
wsdisplay0: screen 2 added (80x25, vt100 emulation)
wsdisplay0: screen 3 added (80x25, vt100 emulation)
wsdisplay0: screen 4 added (80x25, vt100 emulation)
wsmux1: connecting to wsdisplay0
-- 
Keisuke YOSHIDA, Kanagawa, Japan (kay@kaynet.or.jp)