aboutsummaryrefslogtreecommitdiff
path: root/fs/btrfs/compat.h
diff options
context:
space:
mode:
authorQu Wenruo <wqu@suse.com>2020-06-24 18:03:01 +0200
committerTom Rini <trini@konsulko.com>2020-09-07 20:57:27 -0400
commitf06bfcf54d0e91892fcd1379e04aae9cd031fc78 (patch)
treeaac26e518b93db18f3a3557e78340f9ad5483465 /fs/btrfs/compat.h
parent57f24f10733ac57754d4eae3666919480718b032 (diff)
downloadu-boot-f06bfcf54d0e91892fcd1379e04aae9cd031fc78.zip
u-boot-f06bfcf54d0e91892fcd1379e04aae9cd031fc78.tar.gz
u-boot-f06bfcf54d0e91892fcd1379e04aae9cd031fc78.tar.bz2
fs: btrfs: Crossport open_ctree_fs_info() from btrfs-progs
open_ctree_fs_info() is the main entry point to open btrfs. This version is a simplfied version of __open_ctree_fd() of btrfs-progs, the main differences are: - Parameters on how to specify a block device Instead of @fd and @path, U-Boot uses blk_desc and disk_partition_t. - Remove open_ctree flags There won't be multiple open ctree modes in U-Boot. Otherwise functions structures are all kept the same. With open_ctree_fs_info() implemented, also introduce the global current_fs_info pointer to show the current opened btrfs. Signed-off-by: Qu Wenruo <wqu@suse.com> Reviewed-by: Marek BehĂșn <marek.behun@nic.cz>
Diffstat (limited to 'fs/btrfs/compat.h')
-rw-r--r--fs/btrfs/compat.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/compat.h b/fs/btrfs/compat.h
index be4f4e7..52de9db 100644
--- a/fs/btrfs/compat.h
+++ b/fs/btrfs/compat.h
@@ -12,6 +12,8 @@
/* A simple wraper to for error() used in btrfs-progs */
#define error(fmt, ...) pr_err("BTRFS: " fmt "\n", ##__VA_ARGS__)
+#define ASSERT(c) assert(c)
+
#define BTRFS_UUID_UNPARSED_SIZE 37
/*