lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 13 Dec 2023 00:52:10 -0800
From:   Christoph Hellwig <hch@...radead.org>
To:     Johannes Thumshirn <johannes.thumshirn@....com>
Cc:     Chris Mason <clm@...com>, Josef Bacik <josef@...icpanda.com>,
        David Sterba <dsterba@...e.com>, linux-btrfs@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 04/13] btrfs: factor out RAID1 block mapping

On Tue, Dec 12, 2023 at 04:38:02AM -0800, Johannes Thumshirn wrote:
> Now that we have a container for the I/O geometry that has all the needed
> information for the block mappings of RAID1, factor out a helper calculating
> this information.
> 
> Signed-off-by: Johannes Thumshirn <johannes.thumshirn@....com>
> ---
>  fs/btrfs/volumes.c | 31 +++++++++++++++++++++----------
>  1 file changed, 21 insertions(+), 10 deletions(-)
> 
> diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
> index a5d85a77da25..f6f1e783b3c1 100644
> --- a/fs/btrfs/volumes.c
> +++ b/fs/btrfs/volumes.c
> @@ -6372,6 +6372,25 @@ static void map_blocks_for_raid0(struct btrfs_chunk_map *map,
>  		io_geom->mirror_num = 1;
>  }
>  
> +static void map_blocks_for_raid1(struct btrfs_fs_info *fs_info,
> +				 struct btrfs_chunk_map *map,
> +				 enum btrfs_map_op op,
> +				 struct btrfs_io_geometry *io_geom, int replace)

replace looks like a bool to me.  Also elsewhere in the code it is
called dev_replace_is_ongoing.  Even if that name is a little clumsy
it's nice to not switch forth and back between names in a call chain.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ