From patchwork Mon Dec 9 16:14:34 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wang Shilong X-Patchwork-Id: 3311681 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 CAE23C0D4A for ; Mon, 9 Dec 2013 16:15:30 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BE34C202EC for ; Mon, 9 Dec 2013 16:15:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5BF54202E9 for ; Mon, 9 Dec 2013 16:15:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933944Ab3LIQO7 (ORCPT ); Mon, 9 Dec 2013 11:14:59 -0500 Received: from mail-pb0-f47.google.com ([209.85.160.47]:37665 "EHLO mail-pb0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933967Ab3LIQOk (ORCPT ); Mon, 9 Dec 2013 11:14:40 -0500 Received: by mail-pb0-f47.google.com with SMTP id um1so5692345pbc.34 for ; Mon, 09 Dec 2013 08:14:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=O1OXl/Ji2kAPH0a+mosMlsoxOTt72Q6pqh51SVvlP4U=; b=tdq9JfUQaB2PQHbhYxxTc4hhlHfM4V2m51D4HIiLid2ns8XIl54OR3bxpfbvTQGrMU 7gWAbqvCOUJDRAFxIq5+QV9FvM+oex0ukvArFew81DrZwmTETYYMiSGv6V1L3/zzp1Cg oh32kOO+4fwOE/rRZjCuLLY7qnoRNaGiIDLc7Nvw81y0lfp7wtFZJhcgJt4sQEBKFcyE CfQwEc81AxCFw+6iq6BLJMISCcRA00TBQR6iNj9C5imFkmpx9Pq9GNom7ROmpSjdp9+f x71tN7uGJSz/VOEvBvnz24M/AWCcbFYW2WQWkqdBllXzpEPlxIHabW2X990WUct8ddjT gi9A== X-Received: by 10.67.14.67 with SMTP id fe3mr21764028pad.134.1386605679866; Mon, 09 Dec 2013 08:14:39 -0800 (PST) Received: from linux-b0ol.localdomain ([223.65.188.80]) by mx.google.com with ESMTPSA id ql10sm19065866pbc.44.2013.12.09.08.14.38 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 09 Dec 2013 08:14:39 -0800 (PST) From: Wang Shilong To: linux-btrfs@vger.kernel.org Cc: wangsl.fnst@cn.fujitsu.com Subject: [PATCH 2/2] Btrfs: skip building backref tree for uuid and quota tree when doing balance relocation Date: Tue, 10 Dec 2013 00:14:34 +0800 Message-Id: <1386605674-3320-2-git-send-email-wangshilong1991@gmail.com> X-Mailer: git-send-email 1.8.4 In-Reply-To: <1386605674-3320-1-git-send-email-wangshilong1991@gmail.com> References: <1386605674-3320-1-git-send-email-wangshilong1991@gmail.com> 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.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham 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 From: Wang Shilong Quota tree and UUID Tree is only cowed, they can not be snapshoted. Signed-off-by: Wang Shilong --- fs/btrfs/relocation.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c index 4dc7f26..df6e18e 100644 --- a/fs/btrfs/relocation.c +++ b/fs/btrfs/relocation.c @@ -571,7 +571,9 @@ static int is_cowonly_root(u64 root_objectid) root_objectid == BTRFS_CHUNK_TREE_OBJECTID || root_objectid == BTRFS_DEV_TREE_OBJECTID || root_objectid == BTRFS_TREE_LOG_OBJECTID || - root_objectid == BTRFS_CSUM_TREE_OBJECTID) + root_objectid == BTRFS_CSUM_TREE_OBJECTID || + root_objectid == BTRFS_UUID_TREE_OBJECTID || + root_objectid == BTRFS_QUOTA_TREE_OBJECTID) return 1; return 0; }