summaryrefslogtreecommitdiff
path: root/fs/btrfs/root-tree.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2020-02-24 18:37:51 +0300
committerDavid Sterba <dsterba@suse.com>2020-03-23 19:01:47 +0300
commit807fc790aa804102df75b6ac0c943a4d205fc4b5 (patch)
tree929f8c52523c35b5c897be0607187ae95d193a93 /fs/btrfs/root-tree.c
parent48a2e88f53aea4dface64883157ad3c428132f75 (diff)
downloadlinux-807fc790aa804102df75b6ac0c943a4d205fc4b5.tar.xz
btrfs: switch to use new generic UUID API
There are new types and helpers that are supposed to be used in new code. As a preparation to get rid of legacy types and API functions do the conversion here. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/root-tree.c')
-rw-r--r--fs/btrfs/root-tree.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/fs/btrfs/root-tree.c b/fs/btrfs/root-tree.c
index b37904327c9e..98b6e0d980f9 100644
--- a/fs/btrfs/root-tree.c
+++ b/fs/btrfs/root-tree.c
@@ -22,7 +22,6 @@
static void btrfs_read_root_item(struct extent_buffer *eb, int slot,
struct btrfs_root_item *item)
{
- uuid_le uuid;
u32 len;
int need_reset = 0;
@@ -44,8 +43,7 @@ static void btrfs_read_root_item(struct extent_buffer *eb, int slot,
sizeof(*item) - offsetof(struct btrfs_root_item,
generation_v2));
- uuid_le_gen(&uuid);
- memcpy(item->uuid, uuid.b, BTRFS_UUID_SIZE);
+ generate_random_guid(item->uuid);
}
}