Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S264991AbTFQWqL (ORCPT ); Tue, 17 Jun 2003 18:46:11 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S264992AbTFQWqL (ORCPT ); Tue, 17 Jun 2003 18:46:11 -0400 Received: from e31.co.us.ibm.com ([32.97.110.129]:21680 "EHLO e31.co.us.ibm.com") by vger.kernel.org with ESMTP id S264991AbTFQWqJ (ORCPT ); Tue, 17 Jun 2003 18:46:09 -0400 Subject: Re: borked sysfs system devices in 2.5.72 From: Dave Hansen To: Patrick Mochel Cc: Linux Kernel Mailing List , Matthew Dobson In-Reply-To: References: Content-Type: text/plain Organization: Message-Id: <1055890701.24452.15.camel@nighthawk> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.4 Date: 17 Jun 2003 15:58:21 -0700 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1562 Lines: 42 On Tue, 2003-06-17 at 15:54, Patrick Mochel wrote: > > Look in subsys_attr_show(). It is being passed a kobject, which is a > > member of a "struct sys_device". We can tell this because I printed out > > the address of the sys device in sys_device_register(). A to_subsys() > > is being performed on that object, which is wrong, because the kobject > > is not a member of a "struct subsystem". > > My question was how the hell it was getting there in the first place, and > I see that the type of the object isn't getting set properly, so it > defaults to treat it as a struct subsystem. Stack dump from si_meminfo_node(): Call Trace: [] si_meminfo_node+0x4d/0x54 [] node_read_meminfo+0x1c/0x80 [] __alloc_pages+0x82/0x2b4 [] release_console_sem+0x9b/0xa4 [] subsys_attr_show+0x1d/0x28 [] fill_read_buffer+0x96/0xb4 [] opost_block+0x18e/0x19c [] pty_write+0x156/0x168 [] do_lookup+0x18/0x8c [] cp_new_stat64+0xe7/0x100 [] sysfs_read_file+0x1b/0x3c [] vfs_read+0x9c/0xcc [] sys_read+0x31/0x4c [] syscall_call+0x7/0xb > Could you please try the following patch, and let me know if it works? That fixed it, thanks. -- Dave Hansen haveblue@us.ibm.com - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/