From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ob0-f174.google.com ([209.85.214.174]:49355 "EHLO mail-ob0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751684Ab2HNEzB (ORCPT ); Tue, 14 Aug 2012 00:55:01 -0400 Received: by obbuo13 with SMTP id uo13so7964198obb.19 for ; Mon, 13 Aug 2012 21:55:00 -0700 (PDT) Message-ID: <5029DA19.4060401@gmail.com> Date: Tue, 14 Aug 2012 12:54:49 +0800 From: Wang Sheng-Hui MIME-Version: 1.0 To: Chris Mason , linux-btrfs@vger.kernel.org Subject: [PATCH] btrfs-progs: remove redundant value set to path->reada in ctree.c/btrfs_alloc_path Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-btrfs-owner@vger.kernel.org List-ID: btrfs_init_path has init the path to 0s. No need to set ->reada 0 after path init. Signed-off-by: Wang Sheng-Hui --- ctree.c | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/ctree.c b/ctree.c index 2d86b1e..a04e0da 100644 --- a/ctree.c +++ b/ctree.c @@ -43,10 +43,9 @@ struct btrfs_path *btrfs_alloc_path(void) { struct btrfs_path *path; path = kmalloc(sizeof(struct btrfs_path), GFP_NOFS); - if (path) { + if (path) btrfs_init_path(path); - path->reada = 0; - } + return path; } -- 1.7.1