All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joe Thornber <thornber@redhat.com>
To: Mikulas Patocka <mpatocka@redhat.com>,
	"Alasdair G. Kergon" <agk@redhat.com>,
	dm-devel@redhat.com
Subject: Re: [PATCHES] convert dm-thin to use dm-bufio
Date: Fri, 19 Aug 2011 17:17:45 +0100	[thread overview]
Message-ID: <20110819161745.GA27778@ubuntu> (raw)
In-Reply-To: <20110819091224.GB3193@ubuntu>

Mikulas,

On Fri, Aug 19, 2011 at 10:12:24AM +0100, Joe Thornber wrote:
> On Thu, Aug 18, 2011 at 06:31:13PM -0400, Mikulas Patocka wrote:
> > I uploaded bufio-based block manager at 
> > http://people.redhat.com/mpatocka/patches/kernel/dm-thinp-bufio/. It 
> > supports locks, but it defines new functions down_write_non_owner and 
> > up_write_non_owner.
> 
> Thanks Mikulas, I'll try and get it merged over the next couple of days.

I've merged and pushed this to my git repo.

All the test-suite is passing.  Performance is identical (though
hopefully we're a lot more scaleable now).

I have to say I think the separation of io and locking is very elegant
now.  Well done.

I've made two small changes:

i) I switched to using dm_bufio_new() rather than dm_bufio_read() at
the start of *write_lock_zero().  No point reading the data if we're
going to throw it away.

ii) We no longer hold the superblock lock for the duration of the
transaction.  This means we can get rid of the nasty rwsem non-owner
patch.

We have one outstanding issue however.  Now we're using a rwsem per
block, lockdep is trying to validate there are no deadlocks.  Which it
can't do, so is producing a warning. See the
   
 "Exception: Nested data dependencies leading to nested locking"

section in lockdep-design.txt for more discussion of the problem.

We need to suppress this somehow.  I guess the right thing to do is
use the nesting level facility, eg call the superblock level 0, btree
roots level 1 etc.  This will involve a lot of code changes however.
So for now I just want to turn off checking on those locks.

- Joe

  reply	other threads:[~2011-08-19 16:17 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-14 20:18 [PATCHES] convert dm-thin to use dm-bufio Mikulas Patocka
2011-08-15  9:04 ` Joe Thornber
2011-08-15 18:26   ` Mikulas Patocka
2011-08-16  9:16     ` Joe Thornber
2011-08-16 22:03       ` Mikulas Patocka
2011-08-17  8:26         ` Joe Thornber
2011-08-18 22:31           ` Mikulas Patocka
2011-08-19  7:04             ` Mike Snitzer
2011-08-19  9:11               ` Joe Thornber
2011-08-19  9:46                 ` Mike Snitzer
2011-08-19 10:17                   ` Mike Snitzer
2011-08-19 10:22                   ` Joe Thornber
2011-08-19 13:49                     ` Mike Snitzer
2011-08-19 14:11                       ` Alasdair G Kergon
2011-08-19 13:31               ` Mikulas Patocka
2011-08-19 14:11                 ` Mike Snitzer
2011-08-19 15:37                 ` Joe Thornber
2011-08-19 18:25                   ` Mike Snitzer
2011-08-19 18:50                     ` Alasdair G Kergon
2011-08-19  9:12             ` [PATCHES] " Joe Thornber
2011-08-19 16:17               ` Joe Thornber [this message]
2011-08-20  1:10                 ` [PATCH 1/2] dm bufio: fix "value computed is not used" warnings Mike Snitzer
2011-08-20  1:10                   ` [PATCH 2/2] dm space map: only include bitops.h in dm-space-map-common.c Mike Snitzer
2011-08-22 13:29                   ` [PATCH 1/2] dm bufio: fix "value computed is not used" warnings Mikulas Patocka
2011-08-22 18:24                 ` [PATCHES] convert dm-thin to use dm-bufio Mikulas Patocka
2011-08-22 19:59                   ` Mikulas Patocka
2011-08-23 11:23                     ` Joe Thornber

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=20110819161745.GA27778@ubuntu \
    --to=thornber@redhat.com \
    --cc=agk@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=mpatocka@redhat.com \
    /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.