Messages in this thread | | | Date | Thu, 10 Oct 2002 14:22:30 -0400 (EDT) | From | Alexander Viro <> | Subject | Re: [RFC] gendisk refcounting |
| |
On Thu, 10 Oct 2002, Patrick Mochel wrote:
> Then, the one thing that really integrates into the driver model: Wrap > add_disk() and del_gendisk() into ->add_device() and ->remove_device() > of disk_devclass. > > disk_devclass is initialized and added to the tree in > drivers/block/genhd.c::device_init(). Once a driver is bound a device, it > is added to the class the driver belongs to, which calls struct > device_class::add_device(), with a pointer to the struct device of the > drive.
???
What would trigger that? Notice that places where we call add_disk() _do_ matter - shifting it around is not a good idea.
> The other huge benefits of having a generic object like this are: > > - all the current driver model objects can share them, along with the code > to operate on them. > - driverfs can easily be taught about them, making reference counting > easier. > - The glue layers for adding driverfs support for different object types > becomes quite a bit less.
I would still try to trim that object down. Yes, having such a beast would be useful and yes, struct device is too bloated for that. But...
- 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/
| |