]> Git Repo - J-linux.git/commitdiff
NFS: Fix a typo in include/linux/nfs_fs.h
authorTrond Myklebust <[email protected]>
Sun, 1 Aug 2010 17:40:40 +0000 (13:40 -0400)
committerLinus Torvalds <[email protected]>
Sun, 1 Aug 2010 22:10:01 +0000 (15:10 -0700)
nfs_commit_inode() needs to be defined irrespectively of whether or not
we are supporting NFSv3 and NFSv4.

Allow the compiler to optimise away code in the NFSv2-only case by
converting it into an inlined stub function.

Reported-and-tested-by: Ingo Molnar <[email protected]>
Signed-off-by: Trond Myklebust <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
fs/nfs/write.c
include/linux/nfs_fs.h

index bb72ad34d51dd37fcf32a346b103c1db54a6a227..9f81bdd91c559c9f082e8fb3067cfe444da8b6b6 100644 (file)
@@ -1454,11 +1454,6 @@ out_mark_dirty:
        return ret;
 }
 #else
-int nfs_commit_inode(struct inode *inode, int how)
-{
-       return 0;
-}
-
 static int nfs_commit_unstable_pages(struct inode *inode, struct writeback_control *wbc)
 {
        return 0;
index f6e2455f13d16262ab4eecc8cc9faafdf8952aa3..bad4d121b16efa42fa161b2b525d1e73f42b8a71 100644 (file)
@@ -496,6 +496,12 @@ extern int nfs_wb_page_cancel(struct inode *inode, struct page* page);
 extern int  nfs_commit_inode(struct inode *, int);
 extern struct nfs_write_data *nfs_commitdata_alloc(void);
 extern void nfs_commit_free(struct nfs_write_data *wdata);
+#else
+static inline int
+nfs_commit_inode(struct inode *inode, int how)
+{
+       return 0;
+}
 #endif
 
 static inline int
This page took 0.059476 seconds and 4 git commands to generate.