aboutsummaryrefslogtreecommitdiffstats
path: root/fs
Commit message (Collapse)AuthorAge
* NFS: Make nfs_updatepage() mark the page as dirty.Trond Myklebust2006-12-06
| | | | | | | This will ensure that we can call set_page_writeback() from within nfs_writepage(), which is always called with the page lock set. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Ensure that nfs_wb_page() calls writepage when necessary.Trond Myklebust2006-12-06
| | | | Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Add nfs_set_page_dirty()Trond Myklebust2006-12-06
| | | | | | | | | | We will want to allow nfs_writepage() to distinguish between pages that have been marked as dirty by the VM, and those that have been marked as dirty by nfs_updatepage(). In the former case, the entire page will want to be written out, and so any requests that were pending need to be flushed out first. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Remove nfs_writepage_sync()Trond Myklebust2006-12-06
| | | | | | | | Maintaining two parallel ways of doing synchronous writes is rather pointless. This patch gets rid of the legacy nfs_writepage_sync(), and replaces it with the faster asynchronous writes. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: More cleanups of fs/nfs/write.cTrond Myklebust2006-12-06
| | | | Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Remove call to igrab() from nfs_writepage()Trond Myklebust2006-12-06
| | | | | | | | We always ensure that the nfs_open_context holds a reference to the dentry, so the test in nfs_writepage() for whether or not the inode is referenced is redundant. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Cleanup: add common helper nfs_page_length()Trond Myklebust2006-12-06
| | | | | | Clean up a lot of ad-hoc page length calculations in fs/nfs/write.c Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Store pointer to the nfs_page in page->privateTrond Myklebust2006-12-06
| | | | | | | This will allow fast lookup of the nfs_page from the struct page instead of having to search the radix tree. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: cleanup of nfs_sync_inode_wait()Trond Myklebust2006-12-06
| | | | | | Allow callers to directly pass it a struct writeback_control. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Clean up nfs_scan_dirty()Trond Myklebust2006-12-06
| | | | | | Pass down struct writeback control. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Clean up nfs_flush_inode()Trond Myklebust2006-12-06
| | | | | | | Make it take a struct writepages argument, and rename to nfs_flush_mapping(). Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Remove use of the Big Kernel Lock around nfs calls to readlinkFrank Filz2006-12-06
| | | | | | | | | Remove use of the Big Kernel Lock around indirect calls to nfs3_proc_readlink and nfs4_proc_readlink, both of which basically call rpc_call_sync. Signed-off-by: Frank Filz <ffilz@us.ibm.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Remove use of the Big Kernel Lock around calls to rpc_call_syncFrank Filz2006-12-06
| | | | | | | Remove use of the Big Kernel Lock around calls to rpc_call_sync. Signed-off-by: Frank Filz <ffilz@us.ibm.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Remove use of the Big Kernel Lock around calls to rpc_execute.Frank Filz2006-12-06
| | | | | | | Remove use of the Big Kernel Lock around calls to rpc_execute. Signed-off-by: Frank Filz <ffilz@us.ibm.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Fix nfs_sync_inode_wait(FLUSH_INVALIDATE)Trond Myklebust2006-12-06
| | | | | | | Currently nfs_sync_inode_wait() will fail to loop correctly when we call nfs_sync_inode_wait with the FLUSH_INVALIDATE argument. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Fix missing page_unlock() in nfs_readpageTrond Myklebust2006-12-06
| | | | Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS: Fix asynchronous read error handlingTrond Myklebust2006-12-06
| | | | | | | | | | | | | | | | | | | | | We must always call ->read_done() before we truncate the page data, or decide to flag an error. The reasons are that in NFSv2, ->read_done() is where the eof flag gets set. in NFSv3/v4 ->read_done() handles EJUKEBOX-type errors, and v4 state recovery. However, we need to mark the pages as uptodate before we deal with short read errors, since we may need to modify the nfs_read_data arguments. We therefore split the current nfs_readpage_result() into two parts: nfs_readpage_result(), which calls ->read_done() etc, and nfs_readpage_retry(), which subsequently handles short reads. Note: Removing the code that retries in case of a short read also fixes a bug in nfs_direct_read_result(), which used to return a corrupted number of bytes. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* NFS Exclusive open not supported bugAndy Ryan2006-12-06
| | | | | | | | | | | When trying to open a file with the O_EXCL flag over NFS on a server that does not support exclusive mode, the file does not open. The reason, rpc_call_sync returns a errno number, and not the nfs error number. I fixed it by changing the status check in nfs3proc.c. Either this is how it should be fixed, or rpc_call_sync should be fixed to return the NFS error. Signed-off-by: Andy Ryan <genanr@allantgroup.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* SUNRPC: Fix a potential race in rpc_wake_up_task()Trond Myklebust2006-12-06
| | | | | | | | Use RCU to ensure that we can safely call rpc_finish_wakeup after we've called __rpc_do_wake_up_task. If not, there is a theoretical race, in which the rpc_task finishes executing, and gets freed first. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* Fix a second potential rpc_wakeup race...Trond Myklebust2006-12-06
| | | | Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
* Merge branch 'upstream-linus' of ↵Linus Torvalds2006-12-04
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/mfasheh/ocfs2 * 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mfasheh/ocfs2: (31 commits) ocfs2: implement i_op->permission configfs: make configfs_dirent_exists() static ocfs2: update file system paths to set atime ocfs2: core atime update functions ocfs2: Add splice support ocfs2: Remove ocfs2_write_should_remove_suid() [PATCH] Export should_remove_suid() configfs: mutex_lock_nested() fix ocfs2: Remove struct ocfs2_journal_handle in favor of handle_t ocfs2: remove handle argument to ocfs2_start_trans() ocfs2: remove ocfs2_journal_handle journal field ocfs2: pass ocfs2_super * into ocfs2_commit_trans() ocfs2: remove unused handle argument from ocfs2_meta_lock_full() ocfs2: make ocfs2_alloc_handle() static ocfs2: remove unused ocfs2_handle_add_lock() ocfs2: remove unused ocfs2_handle_add_inode() ocfs2: Don't allocate handle early in ocfs2_rename() ocfs2: don't use handle for locking in allocation functions ocfs2: don't pass handle to ocfs2_meta_lock in ocfs2_rename() ocfs2: don't pass handle to ocfs2_meta_lock in ocfs2_symlink() ...
| * ocfs2: implement i_op->permissionTiger Yang2006-12-01
| | | | | | | | | | | | | | | | | | | | | | Implement .permission() in ocfs2_file_iops, ocfs2_special_file_iops and ocfs2_dir_iops. This helps us avoid some multi-node races with mode change and vfs operations. Signed-off-by: Tiger Yang <tiger.yang@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * configfs: make configfs_dirent_exists() staticAdrian Bunk2006-12-01
| | | | | | | | | | | | | | | | This patch makes the needlessly global configfs_dirent_exists() static. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Joel Becker <joel.becker@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: update file system paths to set atimeTiger Yang2006-12-01
| | | | | | | | | | | | | | | | Conditionally update atime in ocfs2_file_aio_read(), ocfs2_readdir() and ocfs2_mmap(). Signed-off-by: Tiger Yang <tiger.yang@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: core atime update functionsTiger Yang2006-12-01
| | | | | | | | | | | | | | This patch adds the core routines for updating atime in ocfs2. Signed-off-by: Tiger Yang <tiger.yang@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: Add splice supportTiger Yang2006-12-01
| | | | | | | | | | | | | | | | | | Add splice read/write support in ocfs2. ocfs2_file_splice_read/write are very similar to ocfs2_file_aio_read/write. Signed-off-by: Tiger Yang <tiger.yang@oracle.com> Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: Remove ocfs2_write_should_remove_suid()Mark Fasheh2006-12-01
| | | | | | | | | | | | Use should_remove_suid() instead. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * configfs: mutex_lock_nested() fixMark Fasheh2006-12-01
| | | | | | | | | | | | | | configfs_unregister_subsystem() nests a pair of inode i_mutex acquisitions, and thus needs annotation via mutex_lock_nested(). Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: Remove struct ocfs2_journal_handle in favor of handle_tMark Fasheh2006-12-01
| | | | | | | | | | | | | | | | | | | | This is mostly a search and replace as ocfs2_journal_handle is now no more than a container for a handle_t pointer. ocfs2_commit_trans() becomes very straight forward, and we remove some out of date comments / code. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove handle argument to ocfs2_start_trans()Mark Fasheh2006-12-01
| | | | | | | | | | | | | | | | | | All callers either pass in NULL directly, or a local variable that is already set to NULL. The internals of ocfs2_start_trans() get a nice cleanup as a result. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove ocfs2_journal_handle journal fieldMark Fasheh2006-12-01
| | | | | | | | | | | | It is no longer used. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: pass ocfs2_super * into ocfs2_commit_trans()Mark Fasheh2006-12-01
| | | | | | | | | | | | This sets us up to remove handle->journal. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove unused handle argument from ocfs2_meta_lock_full()Mark Fasheh2006-12-01
| | | | | | | | | | | | Now that this is unused and all callers pass NULL, we can safely remove it. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: make ocfs2_alloc_handle() staticMark Fasheh2006-12-01
| | | | | | | | | | | | This is no longer used outside of journal.c Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove unused ocfs2_handle_add_lock()Mark Fasheh2006-12-01
| | | | | | | | | | | | | | | | | | | | This gets us rid of a slab we no longer need, as well as removing the majority of what's left on ocfs2_journal_handle. ocfs2_commit_unstarted_handle() has no more real work to do, so remove that function too. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove unused ocfs2_handle_add_inode()Mark Fasheh2006-12-01
| | | | | | | | | | | | | | | | We can also delete the unused infrastructure which was once in place to support this functionality. ocfs2_inode_private loses ip_handle and ip_handle_list. ocfs2_journal_handle loses handle_list. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: Don't allocate handle early in ocfs2_rename()Mark Fasheh2006-12-01
| | | | | | | | | | | | It isn't used until ocfs2_start_trans() anyway. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't use handle for locking in allocation functionsMark Fasheh2006-12-01
| | | | | | | | | | | | | | | | | | Instead we record our state on the allocation context structure which all callers already know about and lifetime correctly. This means the reservation functions don't need a handle passed in any more, and we can also take it off the alloc context. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock in ocfs2_rename()Mark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock in ocfs2_symlink()Mark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock in ocfs2_unlink()Mark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock() in orphan dir codeMark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock() in ocfs2_link()Mark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock() in ocfs2_mknod()Mark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock() in __ocfs2_flush_truncate_log()Mark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: don't pass handle to ocfs2_meta_lock() in localalloc.cMark Fasheh2006-12-01
| | | | | | | | | | | | Take and drop the locks directly. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove ocfs2_journal_handle flags fieldMark Fasheh2006-12-01
| | | | | | | | | | | | | | | | Callers can set h_sync directly on the handle_t, whether a transaction has been started or not can be determined via the existence of the handle_t on the struct ocfs2_journal_handle. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: have ocfs2_extend_trans() take handle_tMark Fasheh2006-12-01
| | | | | | | | | | | | | | | | | | | | No reason to use our wrapper struct in this function, so take the handle_t directly. Also fixes a bug where we were incorrectly setting the handle to NULL in case of a failure from journal_restart() Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: remove unused ocfs2_journal_handle fieldMark Fasheh2006-12-01
| | | | | | | | | | | | max_buffs was just being set and not actually used. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
| * ocfs2: fix format warnings in dlm_alloc_pagevec()Mark Fasheh2006-12-01
| | | | | | | | Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>