All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Frederic Weisbecker <fweisbec@gmail.com>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Jeff Mahoney <jeffm@suse.com>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	ReiserFS Development List <reiserfs-devel@vger.kernel.org>,
	Bron Gondwana <brong@fastmail.fm>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Alexander Viro <viro@zeniv.linux.org.uk>
Subject: Re: [PATCH] reiserfs: kill-the-BKL
Date: Tue, 7 Apr 2009 15:40:17 +0200	[thread overview]
Message-ID: <20090407134017.GA20556@elte.hu> (raw)
In-Reply-To: <1239070789-13354-1-git-send-email-fweisbec@gmail.com>


* Frederic Weisbecker <fweisbec@gmail.com> wrote:

> +/*
> + * Utility function to force a BUG if it is called without the superblock
> + * write lock held.  caller is the string printed just before calling BUG()
> + */
> +void reiserfs_check_lock_depth(struct super_block *sb, char *caller)
> +{
> +	struct reiserfs_sb_info *sb_i = REISERFS_SB(sb);
> +
> +	if (sb_i->lock_depth < 0)
> +		reiserfs_panic(sb, "%s called without kernel lock held %d",
> +			       caller);

s/kernel lock/sb write lock/

> +	reiserfs_write_unlock(s);
> +	mutex_destroy(&REISERFS_SB(s)->lock);
>  	kfree(s->s_fs_info);
>  	s->s_fs_info = NULL;

ah, mutex_destroy() - it's a small detail but still nice ;-)

Anyway, it still looks good to me, after the earlier patch i 
reviewed. Would be nice to have the testing feedback of reiserfs 
users, and the locking review from anyone who knows this code.

	Ingo

  parent reply	other threads:[~2009-04-07 13:40 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-07  2:19 [PATCH] reiserfs: kill-the-BKL Frederic Weisbecker
2009-04-07 11:24 ` Frederic Weisbecker
2009-04-07 13:40 ` Ingo Molnar [this message]
2009-04-07 21:34 ` Alexander Beregalov
2009-04-07 21:57   ` Frederic Weisbecker
2009-04-07 22:19     ` Alexander Beregalov
2009-04-08  0:42       ` Frederic Weisbecker
2009-04-09 15:15 ` Andi Kleen
2009-04-09 15:35   ` Linus Torvalds
2009-04-09 18:40     ` Ingo Molnar
2009-04-09 19:36       ` Andi Kleen
2009-04-09 20:05         ` Frederic Weisbecker
2009-04-09 21:17         ` Ingo Molnar
2009-04-09 21:23           ` Volker Armin Hemmann
2009-04-10  0:39           ` Bron Gondwana
2009-04-10  0:39             ` Bron Gondwana
2009-04-10 13:07             ` Ingo Molnar
2009-04-12  4:05         ` Toby Thain
2009-04-09 21:07   ` Ingo Molnar
2009-04-09 21:07     ` Ingo Molnar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090407134017.GA20556@elte.hu \
    --to=mingo@elte.hu \
    --cc=a.p.zijlstra@chello.nl \
    --cc=akpm@linux-foundation.org \
    --cc=brong@fastmail.fm \
    --cc=fweisbec@gmail.com \
    --cc=jeffm@suse.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=reiserfs-devel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.