btrfs: constify map parameter for nr_parity_stripes and nr_data_stripes
authorDavid Sterba <dsterba@suse.com>
Fri, 17 May 2019 09:43:43 +0000 (11:43 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 1 Jul 2019 11:34:58 +0000 (13:34 +0200)
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/raid56.h

index f5d4c13..2503485 100644 (file)
@@ -7,7 +7,7 @@
 #ifndef BTRFS_RAID56_H
 #define BTRFS_RAID56_H
 
-static inline int nr_parity_stripes(struct map_lookup *map)
+static inline int nr_parity_stripes(const struct map_lookup *map)
 {
        if (map->type & BTRFS_BLOCK_GROUP_RAID5)
                return 1;
@@ -17,7 +17,7 @@ static inline int nr_parity_stripes(struct map_lookup *map)
                return 0;
 }
 
-static inline int nr_data_stripes(struct map_lookup *map)
+static inline int nr_data_stripes(const struct map_lookup *map)
 {
        return map->num_stripes - nr_parity_stripes(map);
 }