From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Date: Tue, 23 Mar 2004 15:57:56 +0000 Subject: Re: libsysfs/udev hang Message-Id: <20040323155756.GA30122@kroah.com> List-Id: References: <4060259D.4000905@gmx.net> In-Reply-To: <4060259D.4000905@gmx.net> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On Tue, Mar 23, 2004 at 12:55:09PM +0100, Carl-Daniel Hailfinger wrote: > sysfs_dev = sysfs_get_classdev_device(class_dev); > if (sysfs_dev != NULL) > printf("follow the class device's \"device\"\n"); > > /* look the device chain upwards */ > while (sysfs_dev != NULL) { > sysfs_dev_parent = sysfs_get_device_parent(sysfs_dev); > printf("point4\n"); > if (sysfs_dev_parent = NULL) > break; > printf("point5\n"); > > sysfs_dev = sysfs_dev_parent; > printf("point6\n"); > } > printf("point7\n"); > sysfs_close_device(sysfs_dev); At this point in time, sysfs_dev will not point to the oritinal device you got from the sysfs_get_glassdev_device() call, right? That's probably the bug. Hope this helps, greg k-h ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id70&alloc_id638&op=click _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel