From patchwork Tue Feb 25 11:48:57 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wang Shilong X-Patchwork-Id: 3716031 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 66C4ABF13A for ; Tue, 25 Feb 2014 11:51:10 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 94A51201CD for ; Tue, 25 Feb 2014 11:51:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C23D1201C7 for ; Tue, 25 Feb 2014 11:51:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752934AbaBYLvB (ORCPT ); Tue, 25 Feb 2014 06:51:01 -0500 Received: from cn.fujitsu.com ([222.73.24.84]:39303 "EHLO song.cn.fujitsu.com" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1752039AbaBYLu7 (ORCPT ); Tue, 25 Feb 2014 06:50:59 -0500 X-IronPort-AV: E=Sophos;i="4.97,539,1389715200"; d="scan'208";a="9600713" Received: from unknown (HELO tang.cn.fujitsu.com) ([10.167.250.3]) by song.cn.fujitsu.com with ESMTP; 25 Feb 2014 19:47:00 +0800 Received: from fnstmail02.fnst.cn.fujitsu.com (tang.cn.fujitsu.com [127.0.0.1]) by tang.cn.fujitsu.com (8.14.3/8.13.1) with ESMTP id s1PBon6r016049 for ; Tue, 25 Feb 2014 19:50:51 +0800 Received: from wangs.fnst.cn.fujitsu.com ([10.167.226.104]) by fnstmail02.fnst.cn.fujitsu.com (Lotus Domino Release 8.5.3) with ESMTP id 2014022519482984-208060 ; Tue, 25 Feb 2014 19:48:29 +0800 From: Wang Shilong To: linux-btrfs@vger.kernel.org Subject: [PATCH 2/2] Btrfs-progs: use bitfield instead of integer for some variants in fs_info Date: Tue, 25 Feb 2014 19:48:57 +0800 Message-Id: <1393328937-26171-2-git-send-email-wangsl.fnst@cn.fujitsu.com> X-Mailer: git-send-email 1.9.0 In-Reply-To: <1393328937-26171-1-git-send-email-wangsl.fnst@cn.fujitsu.com> References: <1393328937-26171-1-git-send-email-wangsl.fnst@cn.fujitsu.com> X-MIMETrack: Itemize by SMTP Server on mailserver/fnst(Release 8.5.3|September 15, 2011) at 2014/02/25 19:48:30, Serialize by Router on mailserver/fnst(Release 8.5.3|September 15, 2011) at 2014/02/25 19:48:32, Serialize complete at 2014/02/25 19:48:32 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, 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 Signed-off-by: Wang Shilong --- ctree.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ctree.h b/ctree.h index 3cc3477..9b461af 100644 --- a/ctree.h +++ b/ctree.h @@ -984,9 +984,11 @@ struct btrfs_fs_info { struct btrfs_fs_devices *fs_devices; struct list_head space_info; int system_allocs; - int readonly; - int on_restoring; - int is_chunk_recover; + + unsigned int readonly:1; + unsigned int on_restoring:1; + unsigned int is_chunk_recover:1; + int (*free_extent_hook)(struct btrfs_trans_handle *trans, struct btrfs_root *root, u64 bytenr, u64 num_bytes, u64 parent,