[PATCH] fuse: Fix build error

From: Larry Finger
Date: Fri Jul 10 2009 - 21:06:41 EST


When building v2.6.31-rc2-344-g69ca06c, the following build errors are
found due to missing includes:

CC [M] fs/fuse/dev.o
fs/fuse/dev.c: In function ârequest_endâ:
fs/fuse/dev.c:289: error: âBLK_RW_SYNCâ undeclared (first use in this
function)
fs/fuse/dev.c:289: error: (Each undeclared identifier is reported only
once
fs/fuse/dev.c:289: error: for each function it appears in.)
fs/fuse/dev.c:290: error: âBLK_RW_ASYNCâ undeclared (first use in this
function)
fs/fuse/dev.c: In function âfuse_request_send_nowait_lockedâ:
fs/fuse/dev.c:417: error: âBLK_RW_SYNCâ undeclared (first use in this
function)
fs/fuse/dev.c:418: error: âBLK_RW_ASYNCâ undeclared (first use in this
function)
make[2]: *** [fs/fuse/dev.o] Error 1

fs/nfs/write.c: In function ânfs_set_page_writebackâ:
fs/nfs/write.c:207: error: âBLK_RW_ASYNCâ undeclared (first use in
this function)
fs/nfs/write.c:207: error: (Each undeclared identifier is reported
only once
fs/nfs/write.c:207: error: for each function it appears in.)
fs/nfs/write.c: In function ânfs_end_page_writebackâ:
fs/nfs/write.c:220: error: âBLK_RW_ASYNCâ undeclared (first use in
this function)
CC lib/dump_stack.o
make[2]: *** [fs/nfs/write.o] Error 1

Signed-off-by: Larry Finger@xxxxxxxxxxxx>
---

fuse/dev.c | 1 +
nfs/write.c | 1 +
2 files changed, 2 insertions(+)


Index: linux-2.6/fs/fuse/dev.c
===================================================================
--- linux-2.6.orig/fs/fuse/dev.c
+++ linux-2.6/fs/fuse/dev.c
@@ -16,6 +16,7 @@
#include <linux/pagemap.h>
#include <linux/file.h>
#include <linux/slab.h>
+#include <linux/blkdev.h>

MODULE_ALIAS_MISCDEV(FUSE_MINOR);

Index: linux-2.6/fs/nfs/write.c
===================================================================
--- linux-2.6.orig/fs/nfs/write.c
+++ linux-2.6/fs/nfs/write.c
@@ -19,6 +19,7 @@
#include <linux/nfs_mount.h>
#include <linux/nfs_page.h>
#include <linux/backing-dev.h>
+#include <linux/blkdev.h>

#include <asm/uaccess.h>



Index: linux-2.6/fs/fuse/dev.c
===================================================================
--- linux-2.6.orig/fs/fuse/dev.c
+++ linux-2.6/fs/fuse/dev.c
@@ -16,6 +16,7 @@
#include <linux/pagemap.h>
#include <linux/file.h>
#include <linux/slab.h>
+#include <linux/blkdev.h>

MODULE_ALIAS_MISCDEV(FUSE_MINOR);

Index: linux-2.6/fs/nfs/write.c
===================================================================
--- linux-2.6.orig/fs/nfs/write.c
+++ linux-2.6/fs/nfs/write.c
@@ -19,6 +19,7 @@
#include <linux/nfs_mount.h>
#include <linux/nfs_page.h>
#include <linux/backing-dev.h>
+#include <linux/blkdev.h>

#include <asm/uaccess.h>