linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* VFS,fs/locks.c: cleanup locks_insert_block
@ 2006-03-21 17:14 Trond Myklebust
  0 siblings, 0 replies; only message in thread
From: Trond Myklebust @ 2006-03-21 17:14 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel, Linux Filesystem Development

From: J. Bruce Fields <bfields@fieldses.org>

BUG instead of handling a case that should never happen.

Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
---

 fs/locks.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/fs/locks.c b/fs/locks.c
index 1b4b899..a2278bc 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -533,12 +533,7 @@ static void locks_delete_block(struct fi
 static void locks_insert_block(struct file_lock *blocker, 
 			       struct file_lock *waiter)
 {
-	if (!list_empty(&waiter->fl_block)) {
-		printk(KERN_ERR "locks_insert_block: removing duplicated lock "
-			"(pid=%d %Ld-%Ld type=%d)\n", waiter->fl_pid,
-			waiter->fl_start, waiter->fl_end, waiter->fl_type);
-		__locks_delete_block(waiter);
-	}
+	BUG_ON(!list_empty(&waiter->fl_block));
 	list_add_tail(&waiter->fl_block, &blocker->fl_block);
 	waiter->fl_next = blocker;
 	if (IS_POSIX(blocker))




^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2006-03-21 17:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-21 17:14 VFS,fs/locks.c: cleanup locks_insert_block Trond Myklebust

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).