From: David Sterba <dsterba@suse.cz>
To: Nikolay Borisov <nborisov@suse.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH 1/2] btrfs: Introduce btrfs_io_geometry
Date: Fri, 31 May 2019 18:03:12 +0200 [thread overview]
Message-ID: <20190531160312.GL15290@twin.jikos.cz> (raw)
In-Reply-To: <20190531150115.21003-1-nborisov@suse.com>
On Fri, May 31, 2019 at 06:01:14PM +0300, Nikolay Borisov wrote:
> ---
> fs/btrfs/volumes.c | 98 ++++++++++++++++++++++++++++++++++++++++++++++
> fs/btrfs/volumes.h | 2 +
> 2 files changed, 100 insertions(+)
>
> diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
> index 776f5c7ca7c5..b130f465ca6d 100644
> --- a/fs/btrfs/volumes.c
> +++ b/fs/btrfs/volumes.c
> @@ -5907,6 +5907,104 @@ static bool need_full_stripe(enum btrfs_map_op op)
> return (op == BTRFS_MAP_WRITE || op == BTRFS_MAP_GET_READ_MIRRORS);
> }
>
> +/*
> + * btrfs_io_geometry - calculates the geomery of a particular (address, len)
> + * tuple. This information is used to calculate how big a
> + * particular bio can get before it straddles a stripe.
> + *
> + * @fs_info - The omnipresent btrfs structure
> + * @logical - Address that we want to figure out the geometry of
> + * @len - The length of IO we are going to perform, starting at @logical
> + * @op - Type of operation - Write or Read
> + * @io_geom - Pointer used to return values
> + *
> + * Returns < 0 in case a chunk for the given logical address cannot be found,
> + * usually shouldn't happen unless @logical is corrupted, 0 otherwise.
> + */
> +int btrfs_io_geometry(struct btrfs_fs_info *fs_info, enum btrfs_map_op op,
> + u64 logical, u64 len, struct btrfs_io_geometry *io_geom)
Where is struct btrfs_io_geometry defined?
And changelog and signed-off-by are missing.
next prev parent reply other threads:[~2019-05-31 16:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-31 15:01 [PATCH 1/2] btrfs: Introduce btrfs_io_geometry Nikolay Borisov
2019-05-31 15:01 ` [PATCH 2/2] btrfs: Use btrfs_io_geometry appropriately Nikolay Borisov
2019-05-31 16:03 ` David Sterba [this message]
2019-05-31 17:01 ` [PATCH 1/2] btrfs: Introduce btrfs_io_geometry Nikolay Borisov
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=20190531160312.GL15290@twin.jikos.cz \
--to=dsterba@suse.cz \
--cc=linux-btrfs@vger.kernel.org \
--cc=nborisov@suse.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