Skip to contentSkip to conversation

fs: define file_fsync() even for CONFIG_BLOCK=n

PATCH In review Paul Mundt 3 participants 3 messages Sep 12, 2007

lore
Share & tools
lore

Paul Mundt

author
#0 lore raw

PATCH 1/1 fs: define file_fsync() even for CONFIG_BLOCK=n

There's nothing that is problematic for file_fsync() with CONFIG_BLOCK=n, and it's built in unconditionally anyways, so move the prototype out to reflect that. Without this, the unionfs build bails out.

CC fs/unionfs/file.o
fs/unionfs/file.c:148: error: 'file_fsync' undeclared here (not in a function) make[2]: *** [fs/unionfs/file.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [fs/unionfs] Error 2

--

 include/linux/buffer_head.h |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
include/linux/buffer_head.h +2 -1
@@ -14,6 +14,8 @@
 #include <linux/wait.h>
 #include <asm/atomic.h>
 
+int file_fsync(struct file *, struct dentry *, int);
+
 #ifdef CONFIG_BLOCK
 
 enum bh_state_bits {
@@ -225,7 +227,6 @@
 sector_t generic_block_bmap(struct address_space *, sector_t, get_block_t *);
 int generic_commit_write(struct file *, struct page *, unsigned, unsigned);
 int block_truncate_page(struct address_space *, loff_t, get_block_t *);
-int file_fsync(struct file *, struct dentry *, int);
 int nobh_prepare_write(struct page*, unsigned, unsigned, get_block_t*);
 int nobh_commit_write(struct file *, struct page *, unsigned, unsigned);
 int nobh_truncate_page(struct address_space *, loff_t);
#1 lore raw
Quoted 3 lines · Paul Mundt

There's nothing that is problematic for file_fsync() with CONFIG_BLOCK=n, and it's built in unconditionally anyways, so move the prototype out to reflect that. Without this, the unionfs build bails out.

Unionfs should stop using it instead.

#2 lore raw
Quoted 6 lines · Christoph Hellwig
Quoted 3 lines · Paul Mundt

There's nothing that is problematic for file_fsync() with CONFIG_BLOCK=n, and it's built in unconditionally anyways, so move the prototype out to reflect that. Without this, the unionfs build bails out.

Unionfs should stop using it instead.

We did stop.

Josef 'Jeff' Sipek.

Signature · 1 line
NT is to UNIX what a doughnut is to a particle accelerator.