From baafb020b76258ec7a87d8608f3ac3603e4630f8 Mon Sep 17 00:00:00 2001 From: "Fajar A. Nugraha" Date: Thu, 2 Jun 2011 09:54:27 +0700 Subject: make "btrfs filesystem label" command actually work This simple patch makes "btrfs filesystem label" command actually work. On tmp branch, commit d1dc6a9, "btrfs filesystem label" functionality was introduced. However the commit lacks one component that lets "btrfs" accept "filesystem label" command. Test case: /dev/loop0 WARNING! - Btrfs Btrfs v0.19 IS EXPERIMENTAL WARNING! - see http://btrfs.wiki.kernel.org before using fs created label old on /dev/loop0 nodesize 4096 leafsize 4096 sectorsize 4096 size 1.00GB Btrfs Btrfs v0.19 old new FATAL: the filesystem has to be unmounted new Not sure if you need if you need a signoff for something as trivial as this, but here it is just in case. Signed-off-by: Fajar A. Nugraha Signed-off-by: Hugo Mills --- btrfs.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/btrfs.c b/btrfs.c index 9cc2665f..ff84260c 100644 --- a/btrfs.c +++ b/btrfs.c @@ -119,6 +119,12 @@ static struct Command commands[] = { "Balance the chunks across the device.", NULL }, + { do_change_label, -1, + "filesystem label", " []\n" + "With one argument, get the label of filesystem on .\n" + "If is passed, set the filesystem label to .\n" + "The filesystem must be unmounted.\n" + }, { do_scan, 999, "device scan", "[...]\n" "Scan all device for or the passed device for a btrfs\n" -- cgit v1.2.3