Re: [PATCH] Symlink /sys/class/block to /sys/block

From: Greg KH
Date: Thu Feb 24 2005 - 19:46:04 EST


On Wed, Feb 23, 2005 at 09:43:35AM +0000, Malcolm Rowe wrote:
> Greg KH writes:
>
> >>Following the discussion in [1], the attached patch creates
> >>/sys/class/block
> >>as a symlink to /sys/block. The patch applies to 2.6.11-rc4-bk7.
> >>
> >>Please cc: me on any replies - I'm not subscribed to the mailing list.
> >Hm, your patch is linewrapped, and can't be applied :(
>
> Bah, and I did send it to myself first, but I guess my mailer un-flowed it
> for me :-(. I'll try to find a better mailer.
>
> >But more importantly:
> >>static void disk_release(struct kobject * kobj)
> >
> >Did you try to remove a disk (like a usb device) and see what happens
> >here? Hint, this isn't the proper place to remove the symlink...
>
> Er, yeah. Oops.
>
> *Is* there a sensible place to remove the symlink from, though? Nobody
> seems to call subsystem_unregister(&block_subsys), which is the place I'd
> expect to add a call to, and I can't see anything that's otherwise
> obvious...

If the subsystem is never unregistered, then don't worry about undoing
the symlink.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/