From owner-freebsd-current@FreeBSD.ORG Thu Dec 9 21:26:25 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1C2EE16A4CE for ; Thu, 9 Dec 2004 21:26:25 +0000 (GMT) Received: from pne-smtpout1-sn2.hy.skanova.net (pne-smtpout1-sn2.hy.skanova.net [81.228.8.83]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9F37243D39 for ; Thu, 9 Dec 2004 21:26:24 +0000 (GMT) (envelope-from pawel.worach@telia.com) Received: from pne-ps4-sn1 (81.228.11.133) by pne-smtpout1-sn2.hy.skanova.net (7.1.026.6) id 4199C6960000A5C2 for freebsd-current@freebsd.org; Thu, 9 Dec 2004 22:26:23 +0100 Message-ID: <15219186.1102627583229.JavaMail.tomcat@pne-ps4-sn1> Date: Thu, 9 Dec 2004 22:26:23 +0100 (MET) From: Pawel Worach To: freebsd-current@freebsd.org Mime-Version: 1.0 Content-Type: text/plain;charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-Mailer: CP Presentation Server X-clientstamp: [217.208.189.47] Subject: panic: pmap_mapdev: Couldn't alloc kernel virtual memory on mpt_attach X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: pawel.worach@telia.com List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Dec 2004 21:26:25 -0000 Booting an IBM x345 box without ACPI (see other problem) generates this panic during the scsi controller probe. It sits on the line before the panic message for about 1-2 minutes. I got a similar/the same panic with ACPI before the other ACPI problem showed up. FreeBSD 6.0-CURRENT #0: Wed Dec 8 17:58:20 CET 2004 root@zero:/usr/obj/usr/src/sys/ZERO MPTable: Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: Intel(R) Xeon(TM) CPU 2.80GHz (2793.90-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0xf29 Stepping = 9 Features=0xbfebfbff real memory = 1073590272 (1023 MB) avail memory = 1046147072 (997 MB) FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs cpu0 (BSP): APIC ID: 0 cpu1 (AP): APIC ID: 6 ioapic0: Assuming intbase of 0 ioapic1: Assuming intbase of 16 ioapic2: Assuming intbase of 32 ioapic2 irqs 32-47 on motherboard ioapic1 irqs 16-31 on motherboard ioapic0 irqs 0-15 on motherboard npx0: [FAST] npx0: on motherboard npx0: INT 16 interface pcib0: pcibus 0 on motherboard pci0: on pcib0 pci0: at device 6.0 (no driver attached) atapci0: port 0x700-0x70f,0x376,0x170- 0x177,0x3f6,0x1f0-0x1f7 at device 15.1 on pci0 ata0: channel #0 on atapci0 ata1: channel #1 on atapci0 pci0: at device 15.2 (no driver attached) isab0: at device 15.3 on pci0 isa0: on isab0 pcib1: pcibus 1 on motherboard pci1: on pcib1 pcib2: pcibus 2 on motherboard pci2: on pcib2 fxp0: port 0x2500-0x253f mem 0xfbfc0000- 0xfbfdffff,0xfbfff000-0xfbffffff irq 20 at device 3.0 on pci2 miibus0: on fxp0 inphy0: on miibus0 inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto fxp0: Ethernet address: 00:0e:0c:2e:98:88 pcib4: pcibus 4 on motherboard pci4: on pcib4 pcib6: pcibus 6 on motherboard pci6: on pcib6 em0: port 0x2540- 0x257f mem 0xf9fe0000-0xf9ffffff irq 29 at device 8.0 on pci6 em0: Ethernet address: 00:0d:60:1a:4f:c6 em0: Speed:N/A Duplex:N/A em1: port 0x2580- 0x25bf mem 0xf9fc0000-0xf9fdffff irq 30 at device 8.1 on pci6 em1: Ethernet address: 00:0d:60:1a:4f:c7 em1: Speed:N/A Duplex:N/A pcib8: pcibus 8 on motherboard pci8: on pcib8 mpt0: port 0x2600-0x26ff mem 0xf7fe0000- 0xf7feffff,0xf7ff0000-0xf7ffffff irq 27 at device 7.0 on pci8 mpt0: [GIANT-LOCKED] mpt1: port 0x2700-0x27ff mem 0xf7fc0000- 0xf7fcffff,0xf7fd0000-0xf7fdffff irq 28 at device 7.1 on pci8 panic: pmap_mapdev: Couldn't alloc kernel virtual memory cpuid = 0 KDB: enter: panic [thread pid 0 tid 0 ] Stopped at kdb_enter+0x32: leal 0(%esi),%esi db> tr Tracing pid 0 tid 0 td 0xc06eda40 kdb_enter(c06a75b3,0,c06b9a7d,c0820a20,0) at kdb_enter+0x32 panic(c06b9a7d,10000,c1f5eb00,0,0) at panic+0x1f3 pmap_mapdev(f7fd0000,10000,c1f5eb88,c1fcea80,c1f5eb84) at pmap_mapdev+0xd2 nexus_activate_resource(c1ee6e00,c1f5eb00,3,14,c1f79980) at nexus_activate_resource+0xa4 pci_alloc_resource(c1f5ed00,c1f5eb00,3,c1fdee90,0,ffffffff,0,2) at pci_alloc_resource+0x597 bus_alloc_resource(c1f5eb00,3,c1fdee90,0,ffffffff) at bus_alloc_resource+0x7d mpt_attach(c1f5eb00,c1f5eb00,ffffffff,c06a8919,0) at mpt_attach+0x453 device_attach(c1f5eb00,8,c0820bdc,c04b088a,c1f5ed00) at device_attach+0x2c9 bus_generic_attach(c1f5ed00,8,78,c0820bd0,8) at bus_generic_attach+0x18 pci_attach(c1f5ed00,c1f5ed00,ffffffff,c06a8919,0) at pci_attach+0x8a device_attach(c1f5ed00,c1ee6d80,c0820c4c,c0678171,c1ee6a00) at device_attach+0x2c9 bus_generic_attach(c1ee6a00,c06b6d31,8,c0820c40,8) at bus_generic_attach+0x18 mptable_hostb_attach(c1ee6a00,c1ee6a00,ffffffff,c06a8919,0) at mptable_hostb_attach+0x81 device_attach(c1ee6a00,c1ee6dcc,c0820cbc,c0670bff,c1ee6d80) at device_attach+0x2c9 bus_generic_attach(c1ee6d80,c1f373c0,c06bf6bc,c1ee6d80,c1ee6dcc) at bus_generic_attach+0x18 legacy_attach(c1ee6d80,c1f3904c,c06bf6bc,c06a8919,0) at legacy_attach+0x1f device_attach(c1ee6d80,c1ee6e00,c0820d18,c067852a,c1ee6e00) at device_attach+0x2c9 bus_generic_attach(c1ee6e00,c1ee6e4c,c0820d54,c051eb59,c1ee6e00) at bus_generic_attach+0x18 nexus_attach(c1ee6e00,c1f3f04c,c06bf6bc,c06a8919,0) at nexus_attach+0x1a device_attach(c1ee6e00,c06dbb50,c0820d78,c0665758,c1e7f500) at device_attach+0x2c9 root_bus_configure(c1e7f500,c06b95b7,0,c0820d98,c04d06a6) at root_bus_configure+0x19 configure(0,0,c06bc314,81ec00,81e000) at configure+0x28 mi_startup() at mi_startup+0xd6 begin() at begin+0x2c db> (kgdb) l *pmap_mapdev+0xd2 0xc067d342 is at /usr/src/sys/i386/i386/pmap.c:2877. 2872 if (pa < KERNLOAD && pa + size <= KERNLOAD) 2873 va = KERNBASE + pa; 2874 else 2875 va = kmem_alloc_nofault(kernel_map, size); 2876 if (!va) 2877 panic("pmap_mapdev: Couldn't alloc kernel virtual memory"); 2878 2879 for (tmpva = va; size > 0; ) { 2880 pmap_kenter(tmpva, pa); 2881 size -= PAGE_SIZE; (kgdb) l *nexus_activate_resource+0xa4 0xc06788f4 is in nexus_activate_resource (/usr/src/sys/i386/i386/nexus. c:419). 414 415 paddr = rman_get_start(r); 416 psize = rman_get_size(r); 417 418 poffs = paddr - trunc_page(paddr); 419 vaddr = (caddr_t) pmap_mapdev(paddr-poffs, psize+poffs) + poffs; 420 } 421 rman_set_virtual(r, vaddr); 422 #ifdef PC98 423 /* PC-98: the type of bus_space_handle_t is the structure. */ (kgdb) l *pci_alloc_resource+0x597 0xc04b1e87 is in pci_alloc_resource (/usr/src/sys/dev/pci/pci.c:1705). 1700 rman_get_size(rle->res), *rid, type, 1701 rman_get_start(rle->res)); 1702 if ((flags & RF_ACTIVE) && 1703 bus_generic_activate_resource(dev, child, type, 1704 *rid, rle->res) != 0) 1705 return NULL; 1706 return (rle->res); 1707 } 1708 } 1709 return (resource_list_alloc(rl, dev, child, type, rid, (kgdb) l *bus_alloc_resource+0x7d 0xc051c7ed is in bus_alloc_resource (/usr/src/sys/kern/subr_bus.c:3179). 3174 { 3175 if (dev->parent == 0) 3176 return (0); 3177 return (BUS_ALLOC_RESOURCE(dev->parent, dev, type, rid, start, end, 3178 count, flags)); 3179 } 3180 3181 /** 3182 * @brief Wrapper function for BUS_ACTIVATE_RESOURCE(). 3183 * (kgdb) l *mpt_attach+0x453 0xc04aaf93 is in mpt_attach (/usr/src/sys/dev/mpt/mpt_pci.c:309). 304 } 305 306 /* Set up the memory regions */ 307 /* Allocate kernel virtual memory for the 9x9's Mem0 region */ 308 mpt->pci_reg_id = MEM_MAP_REG; 309 mpt->pci_reg = bus_alloc_resource(dev, SYS_RES_MEMORY, 310 &mpt->pci_reg_id, 0, ~0, 0, RF_ACTIVE); 311 if (mpt->pci_reg == NULL) { 312 device_printf(dev, "unable to map any ports\n"); 313 goto bad; (kgdb) -- Pawel