Thread (15 messages) 15 messages, 4 authors, 2003-06-24

Re: [PATCH] Fix vmtruncate race and distributed filesystem race

From: Andrew Morton <hidden>
Date: 2003-06-12 21:35:06
Also in: lkml

Dave McCracken [off-list ref] wrote:

--On Thursday, June 12, 2003 14:00:14 -0700 Andrew Morton [off-list ref]
wrote:
quoted
And this does require that ->nopage be entered with page_table_lock held,
and that it drop it.
I think that's a worse layer violation than referencing inode in
do_no_page.  We shouldn't require that the filesystem layer mess with the
page_table_lock.
Well it is not "worse".  Futzing with i_sem in do_no_page() is pretty gross.
You could add vm_ops->prevalidate() or something if it worries you.

btw, it should be synchronising with
file->f_dentry->d_inode->i_mapping->host->i_sem, not
file->f_dentry->d_inode->i_sem.  do_truncate() also seems to be taking the
(potentially) wrong semaphore.


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help