Jeff Mahoney: > sysaufs_sbinfo is a pretty ugly hack. It has a refcount, a kset, some > attributes, and a way to track if it's been added. This is pretty much > what a kobject was designed to do. > > Rather than duplicating all the code inside aufs, we can leverage the > kobject code to do all of that for us. > > For the attribute functions, we don't need to search for anything anymore > because the kobject can be used to reach a properly protected and > refcounted sbinfo structure.
Is this case safe too? - a user opens /sys/fs/aufs/sbi_*/mntpnt1 - anothere user unmount the same aufs - the first user reads mntpnt1 which was opened previously I am afraid your approach may corrupt the file structure because of the lifetime of sysaufs_sbinfo structutre. Your patch makes it freed when the aufs is unmounted. This scenario is similar to your approach for sysaufs_br. Junjiro Okajima ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
