On Mon, 2007-03-12 at 16:31 -0400, Dmitry Torokhov wrote:For what its worth, I think it makes sense if the driver no longer has to worry about sysfs attributes after they've been removed. This is something the core should look after, not each and every driver. http://marc.theaimsgroup.com/?l=linux-kernel&m=117355959020831&w=2 makes a lot of sense, particularly that "No driver callbacks occur after unregistration". When writing the backlight class code, I remember checking into this, concluding that seemed to be the design of sysfs and thinking it a sane design. The alternative is to force each and every driver to do its own refcounting. My experience with locking in the extremely simple backlight class shows nobody reads the documentation or writes the code correctly. With that, I've given up and added suitable locking to the core even if not every driver needs it. In doing so, I made a net removal of a few hundred lines of broken "ticking timebomb" style code. I dread to think what would happen if every driver had to deal with sysfs refcounting. So count me as a vote for handling this in the sysfs core, not the drivers. Richard -
| Theodore Tso | Re: -mm merge plans for 2.6.23 -- sys_fallocate |
| Greg Kroah-Hartman | [PATCH 005/196] Chinese: add translation of SubmittingDrivers |
| Christoph Hellwig | Re: [malware-list] [RFC 0/5] [TALPA] Intro to a linux interface for on access scan... |
| Andi Kleen | [PATCH] [0/45] x86 2.6.24 patches review I |
git: | |
| Wenji Wu | RE: A Linux TCP SACK Question |
| David Miller | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| David Miller | Re: [GIT]: Networking |
