From owner-freebsd-smp Sun Apr 23 20: 4:44 2000 Delivered-To: freebsd-smp@freebsd.org Received: from TYO202.gate.nec.co.jp (TYO202.gate.nec.co.jp [202.247.6.41]) by hub.freebsd.org (Postfix) with ESMTP id 35C9137B9AB for ; Sun, 23 Apr 2000 20:04:35 -0700 (PDT) (envelope-from mihara@prd.fc.nec.co.jp) Received: from mailsv4.nec.co.jp (mailsv4-le1 [192.168.1.93]) by TYO202.gate.nec.co.jp (8.9.3/3.7W00031314) with ESMTP id MAA17754; Mon, 24 Apr 2000 12:04:32 +0900 (JST) Received: from elmer.prd.fc.nec.co.jp (root@elmer.prd.fc.nec.co.jp [10.32.193.1]) by mailsv4.nec.co.jp (8.9.3/3.7W-MAILSV4-NEC) with ESMTP id MAA02522; Mon, 24 Apr 2000 12:04:30 +0900 (JST) Received: from oz.prd.fc.nec.co.jp (oz.prd.fc.nec.co.jp [10.32.193.3]) by elmer.prd.fc.nec.co.jp (8.8.8/3.6W-00032121) with ESMTP id MAA03874; Mon, 24 Apr 2000 12:04:29 +0900 (JST) Date: Mon, 24 Apr 2000 12:03:57 +0900 Message-ID: <861z3w42ua.wl@oz.prd.fc.nec.co.jp> From: Osamu MIHARA To: dillon@apollo.backplane.com, luoqi@watermarkgroup.com Cc: bbeck@mindmaker.com, smp@FreeBSD.ORG Subject: Re: Patch works with Dell 2450 (Re: Multiple APIC support) In-Reply-To: In your message of "Sun, 23 Apr 2000 11:43:24 -0700 (PDT)" <200004231843.LAA63088@apollo.backplane.com> References: <39023622.8777F483@mindmaker.com> <200004231843.LAA63088@apollo.backplane.com> User-Agent: Wanderlust/1.1.0 (Overjoyed) SEMI/1.13.7 (Awazu) FLIM/1.13.2 (Kasanui) MULE XEmacs/21.1 (patch 9) (Canyonlands) (i386-unknown-freebsd3.4) Organization: NEC Corporation, Tokyo Japan MIME-Version: 1.0 (generated by SEMI 1.13.7 - "Awazu") Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-smp@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org At Sun, 23 Apr 2000 11:43:24 -0700 (PDT), Matthew Dillon wrote: > It looks like Luoqi has committed & MFC'd the patch! I would like to > take this opportunity to congratulate Luoqi (and those that provided > the excellent bug reports) on locating and fixing this problem. The > issue with SMP breakage on the Dell boxes has been with us for a while > and it's nice to see progress! > > While there are certainly going to be continuing issues with SMP > compatibility (for example, the NEC box, which is still an open issue), > getting it working on Dell boxes was a major hurdle due to the number > of people using Dell SMP boxes. Banzai! Luoqi's patch also works for my NEC box with RCC LE chipset. Thank you, Luoqi and other guys! BTW, there still be a panic problm in the other NEC box (with Intel chipset, second IO-APIC enabled). As long as the second IO-APIC is disabled, this machine works fine with SMP kernel, so the problem is not critical for my case. However, I put some information for this issue. The panic seems to be caused in bus_dmamem_free() around ../../i386/i386/busdma_machdep.c:358 (5.0-CURRENT). Here is the list from symbol list. (kgdb) list *0xc02cb368 0xc02cb368 is in bus_dmamem_free (../../i386/i386/busdma_machdep.c:358). 353 * NULL 354 */ 355 if (map != NULL) 356 panic("bus_dmamem_free: Invalid map freed\n"); 357 /* XXX There is no "contigfree" and "free" doesn't work */ 358 if ((dmat->maxsize <= PAGE_SIZE) && dmat->lowaddr >= ptoa(Maxmem )) 359 free(vaddr, M_DEVBUF); 360 } 361 362 #define BUS_DMAMAP_NSEGS ((BUS_SPACE_MAXSIZE / PAGE_SIZE) + 1) And here is the boot message, 'trace' and other info from DDB. bus_dmamem_free() is called from ahc_free(). Copyright (c) 1992-2000 The FreeBSD Project. Copyright (c) 1982, 1986, 1989, 1991, 1993 The Regents of the University of California. All rights reserved. FreeBSD 5.0-CURRENT #6: Mon Apr 24 10:37:29 JST 2000 root@swd-poseidon.prd.fc.nec.co.jp:/usr/src/sys/compile/POSEIDON Timecounter "i8254" frequency 1193182 Hz CPU: Pentium/P54C (98.20-MHz 586-class CPU) Origin = "GenuineIntel" Id = 0x525 Stepping = 5 Features=0x3bf real memory = 100663296 (98304K bytes) avail memory = 93732864 (91536K bytes) Programming 16 pins in IOAPIC #0 IOAPIC #0 intpin 2 -> irq 0 Programming 16 pins in IOAPIC #1 IOAPIC #1 intpin 0 -> irq 2 IOAPIC #1 intpin 1 -> irq 16 IOAPIC #1 intpin 2 -> irq 17 IOAPIC #1 intpin 3 -> irq 18 IOAPIC #1 intpin 4 -> irq 19 IOAPIC #1 intpin 5 -> irq 20 IOAPIC #1 intpin 6 -> irq 21 IOAPIC #1 intpin 7 -> irq 22 IOAPIC #1 intpin 12 -> irq 23 FreeBSD/SMP: Multiprocessor motherboard cpu0 (BSP): apic id: 0, version: 0x00030010, at 0xfee00000 cpu1 (AP): apic id: 3, version: 0x00030010, at 0xfee00000 io0 (APIC): apic id: 14, version: 0x000f0011, at 0xfec00000 io1 (APIC): apic id: 13, version: 0x000f0011, at 0xfff7ec00 Intel Pentium detected, installing workaround for F00F bug md0: Malloc disk npx0: on motherboard npx0: INT 16 interface pcib0: on motherboard pci0: on pcib0 isab0: at device 14.0 on pci0 eisa0: on isab0 mainboard0: on eisa0 slot 0 ep0: <3Com 3C579-TP EISA Network Adapter> at 0x2000-0x200f, 0x2c80-0x2c89 ep0: irq 5 (level) on eisa0 slot 2 ep0: Ethernet address 00:20:af:ee:b5:04 ep0: supplying EUI64: 00:20:af:ff:fe:ee:b5:04 isa0: on isab0 chip1: <> mem 0xfff7ec00-0xfff7efff at device 15.0 on pci0 pcib1: on motherboard pci1: on pcib1 ahc0: port 0xfc00-0xfcff mem 0xff9fe000-0xff9feff f irq 23 at device 13.0 on pci1 ahc0: Using left over BIOS settings ahc0: aic7870 Wide Channel A, SCSI Id=7, 16/255 SCBs ahc1: port 0xf800-0xf8ff mem 0xff9ff000-0xff9ffff f at device 14.0 on pci1 Fatal trap 12: page fault while in kernel mode mp_lock = 00000002; cpuid = 0; lapic.id = 00000000 fault virtual address = 0x1c fault code = supervisor read, page not present instruction pointer = 0x8:0xc02cb368 stack pointer = 0x10:0xc0411e54 frame pointer = 0x10:0xc0411e54 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 = 0 (swapper) interrupt mask = net tty bio cam <- SMP: XXX kernel: type 12 trap, code=0 Stopped at bus_dmamem_free+0x18: cmpl $0x1000,0x1c(%edx) db> x/I bus_dmamem_free+0x18: cmpl $0x1000,0x1c(%edx) db> trace bus_dmamem_free(0,0,0,c0df3200,7) at bus_dmamem_free+0x18 ahc_free(c0df3200) at ahc_free+0x44b ahc_free(c0df3200,c0df1048,c0dfcf00,c0dfcc00,4) at ahc_free+0xd read_seeprom(c0dfcc00,c0dfcc00,c0df4680,c0dfcf00,0) at read_seeprom+0x136c device_probe_and_attach(c0dfcc00) at device_probe_and_attach+0x9e bus_generic_attach(c0dfcf00,c0dfcf00,c0df4780,c0df4680,0) at bus_generic_attach+ 0x16 device_probe_and_attach(c0dfcf00) at device_probe_and_attach+0x9e bus_generic_attach(c0df4680,c0df4680,c0a7f800,c0df4780,0) at bus_generic_attach+ 0x16 device_probe_and_attach(c0df4680) at device_probe_and_attach+0x9e bus_generic_attach(c0df4780,c0d95048,c0411f70,c01abcea,c0df4780) at bus_generic_ attach+0x16 rel_mplock(c0df4780,c0df4780,c0368770,419000,0) at rel_mplock+0x1ad device_probe_and_attach(c0df4780) at device_probe_and_attach+0x9e root_bus_configure(c0a7f800,c033d72c,0) at root_bus_configure+0x16 atomic_subtract_long(0,40fc00,419000,0,c0122136) at atomic_subtract_long+0x3e mi_startup(c0411fb4,0,0,a04,0) at mi_startup+0x70 btext() at btext+0xb6 db> show all procs pid proc addr uid ppid pgrp flag stat wmesg wchan cmd 0 c0390720 c0410000 0 0 0 000204 2 swapper db> show registers cs 0x8 gd_npxproc ds 0x10 gd_switchtime es 0x10 gd_switchtime fs 0x18 gd_common_tss ss 0x10 gd_switchtime eax 0 ecx 0x1 edx 0 ebx 0 esp 0xc0411e54 ebp 0xc0411e54 esi 0xc0df32fc edi 0x12 gd_switchtime+0x2 eip 0xc02cb368 bus_dmamem_free+0x18 efl 0x90246 bus_dmamem_free+0x18: cmpl $0x1000,0x1c(%edx) db> show map/f Task map 0xc02cb368: pmap=0x458b0000, nentries=60485, version=205666568 Fatal trap 12: page fault while in kernel mode mp_lock = 00000003; cpuid = 0; lapic.id = 00000000 fault virtual address = 0x7700001c fault code = supervisor read, page not present instruction pointer = 0x8:0xc029fca4 stack pointer = 0x10:0xc0411c7c frame pointer = 0x10:0xc0411c88 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 = 0 (swapper) interrupt mask = net tty bio cam <- SMP: XXX kernel: type 12 trap, code=0 Stopped at bus_dmamem_free+0x18: cmpl $0x1000,0x1c(%edx) db> show object/f Object 0xc02cb368: type=139, size=0x768dc3, res=-1983633149, ref=-2082109099, flags=0xc120 Fatal trap 12: page fault while in kernel mode mp_lock = 00000004; cpuid = 0; lapic.id = 00000000 fault virtual address = 0x7d83f88d fault code = supervisor read, page not present instruction pointer = 0x8:0xc02a2638 stack pointer = 0x10:0xc0411c5c frame pointer = 0x10:0xc0411c88 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 = 0 (swapper) interrupt mask = net tty bio cam <- SMP: XXX kernel: type 12 trap, code=0 Stopped at bus_dmamem_free+0x18: cmpl $0x1000,0x1c(%edx) db> -- Osamu MIHARA // NEC Printers Division To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-smp" in the body of the message