On Tue, 16 Oct 2007, Dave Young wrote:Okay, good, the extra printk messages show exactly where the problem lies. In usb_set_configuration(), each new interfaces is registered and then usb_create_sysfs_intf_files() gets called for that interface. This makes sense, because obviously we can't create sysfs files for an interface before it is registered. The problem is that during registration drivers get probed, and drivers sometimes call usb_set_interface() from their probe method. This routine also calls usb_create_sysfs_intf_files(), and the result is that the sysfs files get created twice: First by usb_set_interface, from the driver probe; Then by usb_set_configuration, when registration is finished. I can think of two possible ways around the problem. One is to add a bit to the usb_interface structure, recording whether the sysfs files have been created. The other is always to remove the files just before trying to create them. The first seems more workable, although it is slightly awkward. Greg, what do you think? Alan Stern ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
| Linus Torvalds | Linux 2.6.21 |
| Greg Kroah-Hartman | [PATCH 002/196] Chinese: rephrase English introduction in HOWTO |
| Con Kolivas | Re: [PATCH][RSDL-mm 0/7] RSDL cpu scheduler for 2.6.21-rc3-mm2 |
| Andrew Morton | echo mem > /sys/power/state |
git: | |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| David Miller | Re: [GIT]: Networking |
| Michael S. Tsirkin | Re: [RFC PATCH v2 03/19] vbus: add connection-client helper infrastructure |
