From: Joe Thornber <thornber@redhat.com>
To: Mikulas Patocka <mpatocka@redhat.com>
Cc: dm-devel@redhat.com, Mike Snitzer <msnitzer@redhat.com>,
"Alasdair G. Kergon" <agk@redhat.com>
Subject: Re: [PATCH] dm-bufio
Date: Mon, 17 Oct 2011 15:09:48 +0100 [thread overview]
Message-ID: <20111017140947.GA10136@ubuntu> (raw)
In-Reply-To: <Pine.LNX.4.64.1110171004290.14928@hs20-bc2-1.build.redhat.com>
On Mon, Oct 17, 2011 at 10:05:26AM -0400, Mikulas Patocka wrote:
>
>
> On Mon, 17 Oct 2011, Joe Thornber wrote:
>
> > On Fri, Oct 14, 2011 at 03:14:34PM -0400, Mikulas Patocka wrote:
> > @@ -493,8 +500,10 @@ static void use_inline_bio(struct dm_buf
> > static void submit_io(struct dm_buffer *b, int rw, sector_t block,
> > bio_end_io_t *end_io)
> > {
> > - if (b->c->block_size <= DM_BUFIO_INLINE_VECS * PAGE_SIZE &&
> > - b->data_mode != DATA_MODE_VMALLOC)
> > + if (rw == WRITE && b->c->write_callback)
> > + b->c->write_callback(b);
> > if (likely(b->c->block_size <= DM_BUFIO_INLINE_VECS * PAGE_SIZE) &&
> > likely(b->data_mode != DATA_MODE_VMALLOC))
> > use_inline_bio(b, rw, block, end_io);
> > else
> > use_dmio(b, rw, block, end_io);
> > @@ -550,8 +559,6 @@ static void __write_dirty_buffer(struct
> > clear_bit(B_DIRTY, &b->state);
> > wait_on_bit_lock(&b->state, B_WRITING,
> > do_io_schedule, TASK_UNINTERRUPTIBLE);
> > - if (b->c->write_callback)
> > - b->c->write_callback(b);
> > submit_io(b, WRITE, b->block, write_endio);
> > }
> >
> >
> > This doesn't seem an improvement. Except ... it changes the behaviour
> > of dm_bufio_release_move(). So was there a preexisting bug in
> > dm_bufio_release_move() that you're trying to fix with this patch?
>
> The actual reason was to do this callback in dm_bufio_release_move() too
> --- just for consistency. (the user of dm_bufio_release_move() doesn't use
> write_callback anyway).
thinp uses dm_bufio_release_move() and write_callback. So yes, this
is a bug fix. I thought so and merged.
- Joe
next prev parent reply other threads:[~2011-10-17 14:09 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-14 19:14 [PATCH] dm-bufio Mikulas Patocka
2011-10-17 10:08 ` Joe Thornber
2011-10-17 12:41 ` dm-bufio Mike Snitzer
2011-10-17 14:04 ` [PATCH] dm-bufio Mikulas Patocka
2011-10-17 14:15 ` Joe Thornber
2011-10-17 10:29 ` Joe Thornber
2011-10-17 10:39 ` Joe Thornber
2011-10-17 10:43 ` Joe Thornber
2011-10-17 10:54 ` Joe Thornber
2011-10-17 13:47 ` Mikulas Patocka
2011-10-17 13:57 ` Joe Thornber
2011-10-17 10:57 ` Joe Thornber
2011-10-17 11:11 ` Joe Thornber
2011-10-17 14:05 ` Mikulas Patocka
2011-10-17 14:09 ` Joe Thornber [this message]
2011-10-17 16:22 ` Mikulas Patocka
2011-10-17 16:41 ` Joe Thornber
2011-10-17 18:30 ` Joe Thornber
2011-10-17 11:14 ` Joe Thornber
2011-10-17 13:43 ` Mikulas Patocka
2011-10-17 11:29 ` Joe Thornber
2011-10-17 16:24 ` Mikulas Patocka
2011-10-17 16:43 ` 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=20111017140947.GA10136@ubuntu \
--to=thornber@redhat.com \
--cc=agk@redhat.com \
--cc=dm-devel@redhat.com \
--cc=mpatocka@redhat.com \
--cc=msnitzer@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox