Compile out splice support from coda when the splice-family of syscalls is not supported by the system (i.e. CONFIG_SYSCALL_SPLICE is undefined).
Signed-off-by: Pieter Smith <pie...@boesman.nl> --- fs/coda/file.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fs/coda/file.c b/fs/coda/file.c index d244d74..a9d8c5d 100644 --- a/fs/coda/file.c +++ b/fs/coda/file.c @@ -42,6 +42,7 @@ coda_file_read(struct file *coda_file, char __user *buf, size_t count, loff_t *p return host_file->f_op->read(host_file, buf, count, ppos); } +#ifdef CONFIG_SYSCALL_SPLICE static ssize_t coda_file_splice_read(struct file *coda_file, loff_t *ppos, struct pipe_inode_info *pipe, size_t count, @@ -62,6 +63,7 @@ coda_file_splice_read(struct file *coda_file, loff_t *ppos, return splice_read(host_file, ppos, pipe, count, flags); } +#endif /* #ifdef CONFIG_SYSCALL_SPLICE */ static ssize_t coda_file_write(struct file *coda_file, const char __user *buf, size_t count, loff_t *ppos) @@ -237,6 +239,6 @@ const struct file_operations coda_file_operations = { .open = coda_open, .release = coda_release, .fsync = coda_fsync, - .splice_read = coda_file_splice_read, + SPLICE_READ_INIT(coda_file_splice_read) }; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/