public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Alasdair G Kergon <agk@redhat.com>
To: Mike Snitzer <snitzer@redhat.com>
Cc: dm-devel@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [dm-devel] [PATCH] dm snapshot: implement .iterate_devices
Date: Wed, 26 Aug 2009 15:50:45 +0100	[thread overview]
Message-ID: <20090826145045.GH643@agk-dp.fab.redhat.com> (raw)
In-Reply-To: <1251007867-13004-1-git-send-email-snitzer@redhat.com>

On Sun, Aug 23, 2009 at 02:11:07AM -0400, Mike Snitzer wrote:
> This patch implements .iterate_devices for the origin and snapshot
> targets.  dm-snapshot's lack of .iterate_devices resulted in the
> inability to properly establish queue_limits for both targets.  
> With 4K sector drives: an unfortunate side-effect of not establishing
> proper limits in either targets' DM device was that IO to the devices
> would fail even though both had been created without error.
> Commit af4874e03ed82f050d5872d8c39ce64bf16b5c38 should have implemented
> .iterate_devices for dm-snap.c's origin and snapshot targets.
 
> +static int snapshot_iterate_devices(struct dm_target *ti,
> +				    iterate_devices_callout_fn fn, void *data)
> +{
> +	struct dm_snapshot *snap = ti->private;
> +
> +	return fn(ti, snap->origin, 0, ti->len, data);
> +}

> +static int origin_iterate_devices(struct dm_target *ti,
> +				  iterate_devices_callout_fn fn, void *data)
> +{
> +	struct dm_dev *dev = ti->private;
> +
> +	return fn(ti, dev, 0, ti->len, data);
> +}

Why are these both seemingly the same?  Is one sufficient?
And where are the characteristics of the 'cow' device taken into account?

Alasdair


  parent reply	other threads:[~2009-08-26 14:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-23  6:11 [PATCH] dm snapshot: implement .iterate_devices Mike Snitzer
2009-08-24 21:15 ` Andrew Morton
2009-08-24 22:55   ` Mike Snitzer
2009-08-26 14:50 ` Alasdair G Kergon [this message]
2009-08-26 18:19   ` Mike Snitzer
2009-08-26 19:32     ` [dm-devel] " Alasdair G Kergon

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=20090826145045.GH643@agk-dp.fab.redhat.com \
    --to=agk@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=snitzer@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