Re: Inconsistency in sysfs behavior?

From: Greg KH
Date: Thu Jan 08 2004 - 15:46:56 EST


On Thu, Jan 08, 2004 at 04:02:42PM +0530, Maneesh Soni wrote:
>
> The problem is that we have live references to the kobject dentry but
> kobject is gone. Problems can occur if kobject is accessed
> through dentry->d_fsdata field. The fix I did was to take a ref. to the
> kobject while linking the dentry with the kobject in create_dir(). This
> ref. can be released when dentry ref. count goes to zero, that is when
> dentry is being freed, through dentry->d_op->d_iput() call. With this
> patch we can have a kobject alive during the life time of the corresponding
> dentry.
>
> Please comment.

This is the patch already in the -mm tree, right? I think it's already
in Pat's pending queue of patches to send off (we're a bit hampered by
the weather right now in this part of the world...)

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/