From mboxrd@z Thu Jan 1 00:00:00 1970 From: Valerie Aurora Subject: [PATCH 6/7] VFS: BUG_ON() rehash of an already hashed dentry Date: Wed, 23 Dec 2009 15:37:02 -0800 Message-ID: <1261611423-4396-7-git-send-email-vaurora@redhat.com> References: <1261611423-4396-1-git-send-email-vaurora@redhat.com> <1261611423-4396-2-git-send-email-vaurora@redhat.com> <1261611423-4396-3-git-send-email-vaurora@redhat.com> <1261611423-4396-4-git-send-email-vaurora@redhat.com> <1261611423-4396-5-git-send-email-vaurora@redhat.com> <1261611423-4396-6-git-send-email-vaurora@redhat.com> Cc: Jan Blunck , Alexander Viro , Valerie Aurora To: linux-fsdevel@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:54193 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757286AbZLWXg7 (ORCPT ); Wed, 23 Dec 2009 18:36:59 -0500 In-Reply-To: <1261611423-4396-6-git-send-email-vaurora@redhat.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: From: Jan Blunck BUG_ON() rehash of an already hashed dentry. For debugging of dcache-related development. Signed-off-by: Jan Blunck Signed-off-by: Valerie Aurora Cc: Alexander Viro --- fs/dcache.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/fs/dcache.c b/fs/dcache.c index a100fa3..74d4ca9 100644 --- a/fs/dcache.c +++ b/fs/dcache.c @@ -1551,6 +1551,7 @@ void d_rehash(struct dentry * entry) { spin_lock(&dcache_lock); spin_lock(&entry->d_lock); + BUG_ON(!d_unhashed(entry)); _d_rehash(entry); spin_unlock(&entry->d_lock); spin_unlock(&dcache_lock); -- 1.5.6.5