Subject: kern/14852: kernel with serial console but wsmux and keyboard configured dies at keayboard attach time
To: None <gnats-bugs@gnats.netbsd.org>
From: None <martin@netbsd.org>
List: netbsd-bugs
Date: 12/06/2001 10:59:54
>Number:         14852
>Category:       kern
>Synopsis:       kernel with serial console but wsmux and keyboard configured dies at keayboard attach time
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Dec 06 03:00:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     Martin Husemann
>Release:        December 6, both -current and -current/sommerfeld_mp1
>Organization:
	
>Environment:
Dual PII machine, dmesg from a boot without serial console is:

NetBSD 1.5Z (BEASTY) #0: Thu Dec  6 11:28:06 CET 2001 
    martin@beasty.aprisoft.de:/usr/src/sys-mp/arch/i386/compile/BEASTY
total memory = 255 MB
avail memory = 235 MB
using 3296 buffers containing 13184 KB of memory
BIOS32 rev. 0 found at 0xfb2e0
mainbus0 (root)
mainbus0: Intel MP Specification (Version 1.4) (OEM00000 PROD00000000)  
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel Pentium II/Celeron (Deschutes) (686-class), 400.93 MHz
cpu0: features 183fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
cpu0: features 183fbff<PGE,MCA,CMOV,FGPAT,PSE36,MMX,FXSR>
cpu0: I-cache 16 KB 32b/line 4-way, D-cache 16 KB 32b/line 4-way
cpu0: L2 cache 512 KB 32b/line 4-way
cpu0: ITLB 32 4 KB entries 4-way, 2 4 MB entries fully associative
cpu0: DTLB 64 4 KB entries 4-way, 8 4 MB entries 4-way
cpu0: calibrating local timer
cpu0: apic clock running at 100 MHz
cpu0: 32 page colors
cpu1 at mainbus0: apid 1 (application processor)
cpu1: starting
cpu1: Intel Pentium II/Celeron (Deschutes) (686-class), 400.91 MHz
cpu1: features 183fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
cpu1: features 183fbff<PGE,MCA,CMOV,FGPAT,PSE36,MMX,FXSR>
cpu1: I-cache 16 KB 32b/line 4-way, D-cache 16 KB 32b/line 4-way
cpu1: L2 cache 512 KB 32b/line 4-way
cpu1: ITLB 32 4 KB entries 4-way, 2 4 MB entries fully associative
cpu1: DTLB 64 4 KB entries 4-way, 8 4 MB entries 4-way
mpbios: bus 0 is type PCI
mpbios: bus 1 is type PCI
mpbios: bus 2 is type ISA
ioapic0 at mainbus0 apid 2 (I/O APIC)
ioapic0: pa 0xfec00000, version 11, 24 pins
pci0 at mainbus0 bus 0: configuration mode 1
pci0: i/o space, memory space enabled
pchb0 at pci0 dev 0 function 0
pchb0: vendor 0x8086 product 0x7190 (rev. 0x03)
agp at pchb0 not configured
ppb0 at pci0 dev 1 function 0: vendor 0x8086 product 0x7191 (rev. 0x03)
pci1 at ppb0 bus 1
pci1: i/o space, memory space enabled
vga0 at pci1 dev 0 function 0: vendor 0x121a product 0x0003 (rev. 0x03)
wsdisplay0 at vga0 kbdmux 1: console (80x25, vt100 emulation)
pcib0 at pci0 dev 7 function 0
pcib0: vendor 0x8086 product 0x7110 (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
wd0 at pciide0 channel 0 drive 0: <IBM-DTTA-351010>
wd0: drive supports 16-sector PIO transfers, LBA addressing
wd0: 9671 MB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 19807200 sectors
wd0: 32-bit data port
wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
wd1 at pciide0 channel 0 drive 1: <WDC WD205AA>
wd1: drive supports 16-sector PIO transfers, LBA addressing
wd1: 19569 MB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 40079088 sectors
wd1: 32-bit data port
wd1: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 4 (Ultra/66)
pciide0: primary channel interrupting at irq 14
wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA data transfers)wd1(pciide0:0:1): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA data transfers)pciide0: secondary channel wired to compatibility mode
atapibus0 at pciide0 channel 1: 2 targets
cd0 at atapibus0 drive 0: <LG CD-RW CED-8080B, 1999/12/16, 1.00> type 5 cdrom removable
cd0: 32-bit data port
cd0: drive supports PIO mode 4, DMA mode 2
pciide0: secondary channel interrupting at irq 15
cd0(pciide0:1:0): using PIO mode 4, DMA mode 2 (using DMA data transfers)
uhci0 at pci0 dev 7 function 2: vendor 0x8086 product 0x7112 (rev. 0x01)
uhci0: interrupting at apic 2 int 19 (irq 5)
usb0 at uhci0: USB revision 1.0
uhub0 at usb0
uhub0: vendor 0x8086 UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
vendor 0x8086 product 0x7113 (miscellaneous bridge, revision 0x02) at pci0 dev 7 function$emuxki0 at pci0 dev 9 function 0: vendor 0x1102 product 0x0002 (audio multimedia, revisio$emuxki0: interrupting at apic 2 int 17 (irq 9)
emuxki0: SigmaTel STAC9721/23 codec; 18 bit DAC, 18 bit ADC, Rockwell 3D   
audio0 at emuxki0: full duplex, mmap, independent
vendor 0x1102 product 0x7002 (miscellaneous input, revision 0x05) at pci0 dev 9 function $tlp0 at pci0 dev 12 function 0: Macronix MX98713 Ethernet, pass 0.0
tlp0: interrupting at apic 2 int 16 (irq 11)
tlp0: Ethernet address 00:40:05:50:ee:9b
tlp0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX
isa0 at pcib0
com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, working fifo
com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, working fifo
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
pmsi0 at pckbc0 (aux slot)
pckbc0: using irq 12 for aux slot
wsmouse0 at pmsi0 mux 0
lpt0 at isa0 port 0x378-0x37b irq 7
pcppi0 at isa0 port 0x61
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: 1.44MB, 80 cyl, 2 head, 18 sec
isapnp0: no ISA Plug 'n Play devices found
biomask 0 netmask 0 ttymask 0
ioapic0: enabling
wd1: no disk label
boot device: wd0
root on wd0a dumps on wd0b
cpu1: CPU 1 running
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)


>Description:

Booting with serial console, but wsmux/vga/keyboard configured crashes
early:

isa0 at pcib0
com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, working fifo
com0: console
com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, working fifo
pckbc0 at isa0 port 0x60-0x64
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0 mux 1
kernel: page fault trap, code=0
Stopped in pid 0 (swapper) at   pckbc_enqueue_cmd+0x4c: movl          0x14(%ebx),%edi
db{0}> tr
pckbc_enqueue_cmd(c085b780,0,c02a587f,1,0) at pckbc_enqueue_cmd+0x4c
pckbd_enable(c085b740,1,c085f19a,1,c085ad00) at pckbd_enable+0x4b
wskbd_enable(c085ad00,1,ffffffff,c085f000,c085ad00) at wskbd_enable+0x1f
wskbd_set_display(c085ad00,c07e7c00,0,c085b724,c085ad00) at wskbd_set_display+0x5b
wsmux_attach_sc(c07e7c00,c085ad00,0,c013bfcb) at wsmux_attach_sc+0x71
wskbd_attach(c085b740,c085ad00,c02a59f0,c013c234,c085ad00,c02a59f0,c085b754,c013
bd84) at wskbd_attach+0x1d2
config_attach(c085b740,c024a9d0,c02a59f0,c020d05c,c085b740) at config_attach+0x248
...

This happens both for the SMP branch kernel, as for the mainline one.

The same kernels, booted with kbd/vga console work just fine.

>How-To-Repeat:
s/a
>Fix:
n/a
>Release-Note:
>Audit-Trail:
>Unformatted: