And why not 4., have a per fs flag (say fs_{,set_,clear_,}generic_aops())
(or per superblock flag or whatever, perhaps a per address space flag
even?) specifying whether the fs' aops support loop or not. loop.c then
simply does:
if (fs_generic_aops()/fs_aops_support_loop()/whatever...)
use aops ->readpage and ->{prepare,commit}_write
else
use fops ->read and ->write
I guess that is like point 2, just making it a simple generic mechanism so
that loop always works yet users of address spaces are free to implement
their ->readpage and ->{prepare,commit}_write anything they want...
Best regards,
Anton
-- Anton Altaparmakov <aia21 at cantab.net> (replace at with @) Linux NTFS maintainer / IRC: #ntfs on irc.openprojects.net WWW: http://linux-ntfs.sf.net/ & http://www-stu.christs.cam.ac.uk/~aia21/- 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/