]> git.ipfire.org Git - thirdparty/u-boot.git/blame - cmd/btrfs.c
treewide: Fix Marek's name and change my e-mail address
[thirdparty/u-boot.git] / cmd / btrfs.c
CommitLineData
83d290c5 1// SPDX-License-Identifier: GPL-2.0+
9d845509 2/*
61143f74 3 * 2017 by Marek Behún <kabel@kernel.org>
9d845509
MB
4 */
5
6#include <common.h>
7#include <command.h>
8#include <btrfs.h>
9#include <fs.h>
10
09140113 11int do_btrsubvol(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
9d845509
MB
12{
13 if (argc != 3)
14 return CMD_RET_USAGE;
15
16 if (fs_set_blk_dev(argv[1], argv[2], FS_TYPE_BTRFS))
17 return 1;
18
19 btrfs_list_subvols();
20 return 0;
21}
22
23U_BOOT_CMD(btrsubvol, 3, 1, do_btrsubvol,
24 "list subvolumes of a BTRFS filesystem",
25 "<interface> <dev[:part]>\n"
26 " - List subvolumes of a BTRFS filesystem."
27)