![]() | |||||||||||||
Messages in this thread |
Claus-Justus Heine wrote: > Now, nfs_flush_pages() may return NULL in two cases: > > a) no write request is pending. Fine. > > b) the write-back request is already in progress. BAD. > > b) means that whenever the write back request already has been > triggered the system might be caught in a loop. This happens because > the nfs-write-back request might sleep while waiting for the > nfs-server to answer. But as nfs_flush_pages() returns NULL in this > case the function nfs_flush_dirty_pages() not wait and return > immediately to its caller nfs_dentry_iput(). Hi Claus, Thanks for your good detective work! The nfs_flush_dirty_pages() is indeed supposed to wait until all requests are finished, which is why nfs_dentry_iput() uses it. (The iput can't proceed until all requests are finished, as the requests need information in the dentry and the dentry may disappear soon.) > The following patch maybe fixes the problem. It changes > nfs_flush_pages() to also return the write-back requests to its caller > if the write back request already is in progress. Maybe this has side > effects? I'll look through the code look for other side effects. I've recently added a NFS_WRITE_COMPLETE flag set in the nfs writeback callback to watch out for other problems when flushing requests. Regards, Bill | ||||||||||||
| Last update: 2005-03-22 12:41 [W:0.330 / U:0.330 seconds] ©2003-2008 Jasper Spaans | |||||||||||||