linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jan Kara <jack@suse.cz>
To: Dave Chinner <david@fromorbit.com>
Cc: Oleg Nesterov <oleg@redhat.com>, Jan Kara <jack@suse.cz>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	Al Viro <viro@zeniv.linux.org.uk>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Paul McKenney <paulmck@linux.vnet.ibm.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Daniel Wagner <daniel.wagner@bmw-carit.de>,
	Davidlohr Bueso <dave@stgolabs.net>,
	Ingo Molnar <mingo@redhat.com>, Tejun Heo <tj@kernel.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH RFC 0/4] change sb_writers to use percpu_rw_semaphore
Date: Mon, 20 Jul 2015 10:26:56 +0200	[thread overview]
Message-ID: <20150720082656.GC3131@quack.suse.cz> (raw)
In-Reply-To: <20150717224015.GR7943@dastard>

On Sat 18-07-15 08:40:15, Dave Chinner wrote:
> On Fri, Jul 17, 2015 at 07:31:17PM +0200, Oleg Nesterov wrote:
> > On 07/17, Dave Chinner wrote:
> > >
> > > On Thu, Jul 16, 2015 at 07:32:56PM +0200, Oleg Nesterov wrote:
> > > >
> > > > 	#ifdef CONFIG_LOCKDEP
> > > > 		/*
> > > > 		 * We want lockdep to tell us about possible deadlocks with freezing but
> > > > 		 * it's it bit tricky to properly instrument it. Getting a freeze protection
> > > > 		 * works as getting a read lock but there are subtle problems. XFS for example
> > > > 		 * gets freeze protection on internal level twice in some cases, which is OK
> > >
> > > Sorry, I've missed something here - where is XFS nesting
> > > sb_start_intwrite() calls?
> > 
> > Heh ;) I too tried to understand thi but failed. I was not surprized,
> > I know nothing about fs/.
> > 
> > Dave, I didn't write this comment. Please look at acquire_freeze_lock().
> > If we can remove this logic - great! but this needs a separate change.
> 
> Oh, I think I know what it was - when we duplicate a transaction for
> a rolling commit, we do it before committing the current transaction
> is committed. I *think* that used to take a second freeze reference,
> which only existed until the first transaction was committed. We do
> things a bit differently now - we hold a state flag on the
> transaction to indicate it needs to release the freeze reference
> when it is freed and we pass it to the new transaction so that the
> first transaction commit doesn't release it.
> 
> So, yes, it may well be a stale comment now.

Yeah, as far as I remember this was the reason why I added the comment. So
Oleg, feel free to remove the special code and run xfstests with XFS and
lockdep enabled to verify there are really no issues. Thanks!

								Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

  reply	other threads:[~2015-07-21 20:26 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-13 21:25 [PATCH RFC 0/4] change sb_writers to use percpu_rw_semaphore Oleg Nesterov
2015-07-13 21:25 ` [PATCH 1/4] change get_super_thawed() to use sb_start/end_write() Oleg Nesterov
2015-07-14 10:49   ` Jan Kara
2015-07-14 13:38     ` Oleg Nesterov
2015-07-13 21:25 ` [PATCH 2/4] introduce sb_unlock_frozen() Oleg Nesterov
2015-07-13 21:25 ` [PATCH 3/4] introduce sb_lockdep_release() Oleg Nesterov
2015-07-13 21:25 ` [PATCH 4/4] change sb_writers to use percpu_rw_semaphore Oleg Nesterov
2015-07-13 22:23 ` [PATCH RFC 0/4] " Dave Chinner
2015-07-13 22:42   ` Oleg Nesterov
2015-07-13 23:14     ` Dave Chinner
2015-07-14 10:48 ` Jan Kara
2015-07-14 13:37   ` Oleg Nesterov
2015-07-14 21:17     ` Dave Hansen
2015-07-14 21:22       ` Oleg Nesterov
2015-07-14 21:41         ` Dave Hansen
2015-07-15  6:47           ` Jan Kara
2015-07-15 18:19             ` Oleg Nesterov
2015-07-16  7:26               ` Jan Kara
2015-07-16  7:30                 ` Dave Hansen
2015-07-16  8:55                   ` Jan Kara
2015-07-16 17:32                 ` Oleg Nesterov
2015-07-17  1:27                   ` Dave Chinner
2015-07-17 17:31                     ` Oleg Nesterov
2015-07-17 22:40                       ` Dave Chinner
2015-07-20  8:26                         ` Jan Kara [this message]
2015-07-22 21:09                           ` Oleg Nesterov
2015-07-20 16:23                         ` Oleg Nesterov

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=20150720082656.GC3131@quack.suse.cz \
    --to=jack@suse.cz \
    --cc=daniel.wagner@bmw-carit.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=dave@stgolabs.net \
    --cc=david@fromorbit.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=oleg@redhat.com \
    --cc=paulmck@linux.vnet.ibm.com \
    --cc=peterz@infradead.org \
    --cc=tj@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 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).