Hm, I don't really understand your question, but I'll try to explain
how I did this.
Both struct usb_device and struct usb_interface now have a struct
device. This is because _both_ things need to show up in the driverfs
tree. I tried only making interfaces be devices (which is more of what
the USB core code things of as devices), but the tree just didn't make
much sense. Also, a USB device contains such things as the control
pipe, and the usb descriptors and strings. So it is useful to show the
device, as that's where you get the device name and serial number from :)
Does that help?
Try looking at the usb driverfs implementation as it is in 2.5.30, both
the interfaces and the main device show up in the tree, I didn't change
this. All this patch does is start to use "struct device_driver", and
bind the drivers to the interfaces, _which_ is what the USB core has
always done (no change in functionality here.) What this allows us to
do is remove (eventually) the USB list of devices, and remove some other
device list logic, as well as clean up the probe/disconnect interface.
thanks,
greg k-h
-
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/