lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 11 Jul 2009 10:06:54 -0400
From:	Trond Myklebust <Trond.Myklebust@...app.com>
To:	Linus Torvalds <torvalds@...ux-foundation.org>,
	Larry Finger <Larry.Finger@...inger.net>
Cc:	linux-kernel@...r.kernel.org
Subject: RE: commit 097041e576ee3a50d92dd643ee8ca65bf6a62e21 (fuse: Fix
 build error)

Hi Linus

Please revert this commit. Instead of fixing the compile problem, it
adds a new dependency on CONFIG_BLOCK to both NFS and FUSE. Neither one
of them has such a dependency today, nor is there a reason to introduce
one. 

The correct fix should rather be to move the definitions of BLK_RW_SYNC
and BLK_RW_ASYNC into backing-dev.h as per the patch below.

Cheers
  Trond

---------------------------------------------------------------------
From: Trond Myklebust <Trond.Myklebust@...app.com>
Fix compile error due to congestion_wait() changes

Move the definition of BLK_RW_ASYNC/BLK_RW_SYNC into linux/backing-dev.h so
that it is available to all callers of set/clear_bdi_congested().

This fixes a compile error in fs/fuse/dev.c:
linux-2.6/fs/fuse/dev.c: In function ‘request_end’:
linux-2.6/fs/fuse/dev.c:289: error: ‘BLK_RW_SYNC’ undeclared (first use in this function)
linux-2.6/fs/fuse/dev.c:289: error: (Each undeclared identifier is reported only once
linux-2.6/fs/fuse/dev.c:289: error: for each function it appears in.)
linux-2.6/fs/fuse/dev.c:290: error: ‘BLK_RW_ASYNC’ undeclared (first use in this function)
linux-2.6/fs/fuse/dev.c: In function ‘fuse_request_send_nowait_locked’:
linux-2.6/fs/fuse/dev.c:417: error: ‘BLK_RW_SYNC’ undeclared (first use in this function)
linux-2.6/fs/fuse/dev.c:418: error: ‘BLK_RW_ASYNC’ undeclared (first use in this function)
make[3]: *** [fs/fuse/dev.o] Error 1
make[2]: *** [fs/fuse] Error 2

Signed-off-by: Trond Myklebust <Trond.Myklebust@...app.com>
Cc: Jens Axboe <jens.axboe@...cle.com>
Cc: Miklos Szeredi <miklos@...redi.hu>
---

 include/linux/backing-dev.h |    5 +++++
 include/linux/blkdev.h      |    5 -----
 2 files changed, 5 insertions(+), 5 deletions(-)


diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h
index 3a52a63..1d52425 100644
--- a/include/linux/backing-dev.h
+++ b/include/linux/backing-dev.h
@@ -229,6 +229,11 @@ static inline int bdi_rw_congested(struct backing_dev_info *bdi)
 				  (1 << BDI_async_congested));
 }
 
+enum {
+	BLK_RW_ASYNC	= 0,
+	BLK_RW_SYNC	= 1,
+};
+
 void clear_bdi_congested(struct backing_dev_info *bdi, int sync);
 void set_bdi_congested(struct backing_dev_info *bdi, int sync);
 long congestion_wait(int sync, long timeout);
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 0146e0f..e7cb5db 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -70,11 +70,6 @@ enum rq_cmd_type_bits {
 	REQ_TYPE_ATA_PC,
 };
 
-enum {
-	BLK_RW_ASYNC	= 0,
-	BLK_RW_SYNC	= 1,
-};
-
 /*
  * For request of type REQ_TYPE_LINUX_BLOCK, rq->cmd[0] is the opcode being
  * sent down (similar to how REQ_TYPE_BLOCK_PC means that ->cmd[] holds a


-- 
Trond Myklebust
Linux NFS client maintainer

NetApp
Trond.Myklebust@...app.com
www.netapp.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ