From patchwork Wed Dec 10 15:06:51 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Sterba X-Patchwork-Id: 5469671 Return-Path: X-Original-To: patchwork-linux-btrfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 9102DBEEA8 for ; Wed, 10 Dec 2014 15:07:00 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C73ED20121 for ; Wed, 10 Dec 2014 15:06:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B3B7F200E1 for ; Wed, 10 Dec 2014 15:06:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757777AbaLJPGx (ORCPT ); Wed, 10 Dec 2014 10:06:53 -0500 Received: from cantor2.suse.de ([195.135.220.15]:43565 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757600AbaLJPGx (ORCPT ); Wed, 10 Dec 2014 10:06:53 -0500 Received: from relay2.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 52A2DAB09 for ; Wed, 10 Dec 2014 15:06:52 +0000 (UTC) Received: by ds.suse.cz (Postfix, from userid 10065) id 08253DA82F; Wed, 10 Dec 2014 16:06:52 +0100 (CET) From: David Sterba To: linux-btrfs@vger.kernel.org Cc: David Sterba Subject: [PATCH 1/3] btrfs-progs: let subvol delete print commit mode inline Date: Wed, 10 Dec 2014 16:06:51 +0100 Message-Id: <47bbff777e73fb392bf84a2a84a3d4d7e7aa2279.1418223710.git.dsterba@suse.cz> X-Mailer: git-send-email 2.1.3 In-Reply-To: References: Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP There are options to specify if the subvolume deletion should wait for commit after each subvol or at the end. This is reported at the beginning and considered as a noise. We'd like to report the mode for each subvolume instead. http://www.mail-archive.com/linux-btrfs%40vger.kernel.org/msg34617.html Reported-by: Marc MERLIN --- cmds-subvolume.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmds-subvolume.c b/cmds-subvolume.c index 53eec467251d..4e452f4f4eb7 100644 --- a/cmds-subvolume.c +++ b/cmds-subvolume.c @@ -303,7 +303,9 @@ again: goto out; } - printf("Delete subvolume '%s/%s'\n", dname, vname); + printf("Delete subvolume (%s): '%s/%s'\n", + sync_mode == 2 || (sync_mode == 1 && cnt + 1 == argc) + ? "commit" : "no-commit", dname, vname); strncpy_null(args.name, vname); res = ioctl(fd, BTRFS_IOC_SNAP_DESTROY, &args); e = errno;