From owner-freebsd-current@FreeBSD.ORG Sun Mar 22 10:50:40 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 05426106564A; Sun, 22 Mar 2009 10:50:40 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from mu-out-0910.google.com (mu-out-0910.google.com [209.85.134.190]) by mx1.freebsd.org (Postfix) with ESMTP id 358358FC18; Sun, 22 Mar 2009 10:50:38 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: by mu-out-0910.google.com with SMTP id w9so524738mue.3 for ; Sun, 22 Mar 2009 03:50:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=vwqJ0D5UNInPxzxwhe0w+UCUjtVtLhYAMcD4dUKz/k0=; b=EkCHyL3E9xSC62Ov18NiI8EUcWspXMoj/FoGfKPgwIL52L1xiy99IjdNAWUqZ5Isvk NmhNhR5G0SudDo8/8vpe9MdDmbdOzl7wFGbDLPNW7frJVpOHdBnjjoGfekP2VvILjUKU rEftj3wjGBxSSSfK3DJkWrC6RK8DL5BY5IjQU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=FGnLB/uHGhRiAFjebC7OgiBRBjIYmA92MDqQv7J+1bhSRVFojSuOQ4dYpRjPxloerJ swckx4iT1wzLMRNs5zkzfIMByNBU6X1kaBI0nzAOEN3spS5eCSSNtjbDCAHi+Y5Jjl+j +F5DrRX+kGJddFzp4Sdgb0UGc5v36Usz5muc0= MIME-Version: 1.0 Received: by 10.103.169.18 with SMTP id w18mr2171788muo.73.1237719038064; Sun, 22 Mar 2009 03:50:38 -0700 (PDT) In-Reply-To: References: <49B594B5.2060706@FreeBSD.org> <20090321.211942.-1540398823.imp@bsdimp.com> Date: Sun, 22 Mar 2009 13:50:38 +0300 Message-ID: From: pluknet To: "M. Warner Losh" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: mav@freebsd.org, freebsd-current@freebsd.org Subject: Re: Unable to set devclass (devname: (null) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Mar 2009 10:50:40 -0000 2009/3/22 pluknet : > 2009/3/22 M. Warner Losh : >> In message: >> pluknet writes: >> : 2009/3/10 pluknet : >> : > 2009/3/10 Alexander Motin : >> : >> pluknet wrote: >> : >>> >> : >>> 2009/3/10 Alexander Motin : >> : >>>> >> : >>>> pluknet wrote: >> : >>>>> >> : >>>>> Is it ok (and how much harmfull) to see this message? >> : >>>>> >> : >>>>> driver bug: Unable to set devclass (devname: (null)) >> : >>>>> >> : >>>>> P.S. >> : >>>>> This is introduced in subr_bus.c, v1.216 >> : >>>>> - PDEBUG(("Unable to set device >> : >>>>> class")); >> : >>>>> + printf("driver bug: Unable to >> : >>>>> set >> : >>>>> devclass (devname: %s)\n", >> : >>>>> + (child ? >> : >>>>> device_get_name(child) : >> : >>>>> + "no device")); >> : >>>>> >> : >>>>> where PDEBUG was moved from BUS_DEBUG to general output. >> : >>>> >> : >>>> Actually this check was introduced in rev. 1.214, just was not logged. >> : >>>> Before this change system could crash soon after this message. Now it >> : >>>> should >> : >>>> not, but related device probably will not work properly. It is probably >> : >>>> not >> : >>>> good and should be fixed, but it can be just a low memory symptom. It was >> : >>>> noticed for ata driver, but I hope it was fixed. Where have you get it? >> : >>> >> : >>> This is during the boot, see dmesg (attached). >> : >> >> : >> It does not gives much info. Can you try to add dl->driver->name, >> : >> device_get_unit(child) and device_set_devclass() result printing there? >> : >> >> : > >> : > That gives: >> : > atkbd0: [GIANT-LOCKED] >> : > atkbd0: [ITHREAD] >> : > driver bug: Unable to set devclass (devname: (null)) >> : > dl->driver->name: atkbdc >> : > device_get_unit(child): -1 >> : > device_set_devclass(): 17 >> : > >> : >> : Well, yes. That confirms with numerous devclass_alloc_unit() EEXIST >> : hidden messages; >> : >> : atkbdc0: port 0x60,0x64 irq 1 on acpi0 >> : atkbd0: irq 1 on atkbdc0 >> : atkbd: the current kbd controller command byte 0065 >> : atkbd: keyboard ID 0x83ab (2) >> : kbd0 at atkbd0 >> : kbd0: atkbd0, AT 101/102 (2), config:0x0, flags:0x3d0000 >> : ioapic0: routing intpin 1 (ISA IRQ 1) to lapic 0 vector 54 >> : atkbd0: [GIANT-LOCKED] >> : atkbd0: [ITHREAD] >> : psm0: unable to allocate IRQ >> : atkbdc: atkbdc-1 already exists; skipping it >> >> Can you set a breakpoint on this line and give a traceback? >> >> : driver bug: Unable to set devclass (devname: (null)) >> : dl->driver->name: atkbdc >> : device_get_unit(child): -1 >> : atkbdc: atkbdc-1 already exists; skipping it >> >> Ditto >> >> : device_set_devclass(): 17 >> : psmcpnp0: port 0x60,0x64 irq 12 on acpi0 >> : psm0: current command byte:0065 >> : psm0: irq 12 on atkbdc0 >> : ioapic0: routing intpin 12 (ISA IRQ 12) to lapic 0 vector 55 >> : psm0: [GIANT-LOCKED] >> : psm0: [ITHREAD] >> : psm0: model IntelliMouse Explorer, device ID 4-00, 5 buttons >> : psm0: config:00000000, flags:00000008, packet size:4 >> : psm0: syncmask:08, syncbits:00 >> : ppc0: using extended I/O port range >> : ppc0: using extended I/O port range >> : pnp_identify: Trying Read_Port at 203 >> : pnp_identify: Trying Read_Port at 243 >> : pnp_identify: Trying Read_Port at 283 >> : pnp_identify: Trying Read_Port at 2c3 >> : pnp_identify: Trying Read_Port at 303 >> : pnp_identify: Trying Read_Port at 343 >> : pnp_identify: Trying Read_Port at 383 >> : pnp_identify: Trying Read_Port at 3c3 >> : PNP Identify complete >> : isa_probe_children: disabling PnP devices >> : pmtimer0 on isa0 >> : ata: ata0 already exists; skipping it >> : ata: ata1 already exists; skipping it >> : atkbdc: atkbdc0 already exists; skipping it >> : sc: sc0 already exists; skipping it >> : vga: vga0 already exists; skipping it >> >> No need for these... >> >> Warner >> > > While rebuilding the kernel from newest sources, I have a dmesg from a > bit older kernel > (where atkbdc-1 was detected only once): > > atkbdc0: port 0x60,0x64 irq 1 on acpi0 > atkbd0: irq 1 on atkbdc0 > atkbd: the current kbd controller command byte 0065 > atkbd: keyboard ID 0x83ab (2) > kbd0 at atkbd0 > kbd0: atkbd0, AT 101/102 (2), config:0x0, flags:0x3d0000 > ioapic0: routing intpin 1 (ISA IRQ 1) to lapic 0 vector 54 > atkbd0: [GIANT-LOCKED] > atkbd0: [ITHREAD] > psm0: unable to allocate IRQ > atkbdc: atkbdc-1 already exists; skipping it > driver bug: Unable to set devclass (devname: (null)) > KDB: stack backtrace: > db_trace_self_wrapper(c08240e7,c0c20ba4,c05ecfd1,c08239a5,0,...) at > db_trace_self_wrapper+0x26 > kdb_backtrace(c08239a5,0,c0824f45,c3d7253c,c3d7253c,...) at kdb_backtrace+0x29 > device_probe_child(c3de4400,c3d72500,c0823799,981,c3d72500,...) at > device_probe_child+0xf1 > device_probe(c3d72500,4,c0823799,9a2,c3d72500,...) at device_probe+0x93 > device_probe_and_attach(c3d72500,1,c0c20c64,c048a0a6,c3de4400,...) at > device_probe_and_attach+0x36 > bus_generic_attach(c3de4400,c3de4400,c086aca8,c048a640,c3de4400,...) > at bus_generic_attach+0x19 > acpi_attach(c3de4400,c3d95054,c086ade8,c0823810,80000000,...) at > acpi_attach+0xba6 > device_attach(c3de4400,4,c0823799,9a2) at device_attach+0x36f > device_probe_and_attach(c3de4400,c3de4980,c0c20cf0,c0796a2e,c3de4980,...) > at device_probe_and_attach+0x4e > bus_generic_attach(c3de4980,a,c07fd14d,0) at bus_generic_attach+0x19 > nexus_acpi_attach(c3de4980,c3da0054,c086ade8,c0823810,80000000,...) at > nexus_acpi_attach+0x7e > device_attach(c3de4980,4,c0823799,9a2) at device_attach+0x36f > device_probe_and_attach(c3de4980,c3d0cb6c,c0c20d6c,c079b9bc,c07fc469,...) > at device_probe_and_attach+0x4e > root_bus_configure(c07fc469,c0c20d88,c05874f6,0,c1ec00,...) at > root_bus_configure+0x1b > configure(0,c1ec00,c1ec00,c1e000,c25000,...) at configure+0xc > mi_startup() at mi_startup+0x96 > begin() at begin+0x2c > Hm.. the same on new kernel; only one atkbdc-1 event: atkbdc0: port 0x60,0x64 irq 1 on acpi0 atkbd0: irq 1 on atkbdc0 atkbd: the current kbd controller command byte 0065 atkbd: keyboard ID 0x83ab (2) kbd0 at atkbd0 kbd0: atkbd0, AT 101/102 (2), config:0x0, flags:0x3d0000 ioapic0: routing intpin 1 (ISA IRQ 1) to lapic 0 vector 54 atkbd0: [GIANT-LOCKED] atkbd0: [ITHREAD] psm0: unable to allocate IRQ atkbdc: atkbdc-1 already exists; skipping it KDB: stack backtrace: db_trace_self_wrapper(c082979d,c0c20b58,c05ea65b,c0828da6,c3d118b0,...) at db_trace_self_wrapper+0x26 kdb_backtrace(c0828da6,c3d118b0,c3d118b0,ffffffff,ffffffff,...) at kdb_backtrace+0x29 devclass_add_device(101,c3d31460,6,c0c20ba4,c05ed817,...) at devclass_add_device+0x12b device_set_devclass(c3d73500,c084668e,c082a661,c3d7353c,c3d7353c,...) at device_set_devclass+0x6f device_probe_child(c3de5400,c3d73500,c0828e4f,97f,c3d73500,...) at device_probe_child+0xc7 device_probe(c3d73500,4,c0828e4f,9a0,c3d73500,...) at device_probe+0x93 device_probe_and_attach(c3d73500,1,c0c20c64,c048a556,c3de5400,...) at device_probe_and_attach+0x36 bus_generic_attach(c3de5400,c3de5400,c08708a8,c048aaf0,c3de5400,...) at bus_generic_attach+0x19 acpi_attach(c3de5400,c3d98054,c08709e8,c0828ec6,80000000,...) at acpi_attach+0xba6 device_attach(c3de5400,4,c0828e4f,9a0) at device_attach+0x36f device_probe_and_attach(c3de5400,c3de5980,c0c20cf0,c079bdee,c3de5980,...) at device_probe_and_attach+0x4e bus_generic_attach(c3de5980,a,c080276d,0) at bus_generic_attach+0x19 nexus_acpi_attach(c3de5980,c3da1054,c08709e8,c0828ec6,80000000,...) at nexus_acpi_attach+0x7e device_attach(c3de5980,4,c0828e4f,9a0) at device_attach+0x36f device_probe_and_attach(c3de5980,c3d0db78,c0c20d6c,c07a0d7c,c086edc8,...) at device_probe_and_attach+0x4e root_bus_configure(c086edc8,c0c20d88,c0587b46,0,c1ec00,...) at root_bus_configure+0x1b configure(0,c1ec00,c1ec00,c1e000,c25000,...) at configure+0xc mi_startup() at mi_startup+0x96 begin() at begin+0x2c driver bug: Unable to set devclass (devname: (null)) -- wbr, pluknet