From patchwork Sat Dec 13 12:05:51 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Goffredo Baroncelli X-Patchwork-Id: 5486631 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 EA374BEEBA for ; Sat, 13 Dec 2014 12:04:39 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2F2912011D for ; Sat, 13 Dec 2014 12:04:39 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0E52D2017A for ; Sat, 13 Dec 2014 12:04:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030689AbaLMMEe (ORCPT ); Sat, 13 Dec 2014 07:04:34 -0500 Received: from mail-wg0-f49.google.com ([74.125.82.49]:56521 "EHLO mail-wg0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966591AbaLMMEc (ORCPT ); Sat, 13 Dec 2014 07:04:32 -0500 Received: by mail-wg0-f49.google.com with SMTP id n12so11095913wgh.36 for ; Sat, 13 Dec 2014 04:04:30 -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=gobaTVlQU1os/tyi4ZdIPJVj5VXB6yyhOVOAvuZjzmQ=; b=XoFQNkrfxg+ekuR+OuEbuIN+S5Jjc+igaVmhVB6Ou20pIbeVLZ6CnNvPj2yglv9kHj fIBMW64rXbPqyMshfqKZ7yBjUMKvDZ4MUcm+SMIvNIKPrzTlNjuCJ2U4QX5UfgOL2Tzp cpCXsF2LLij0thNIUTxIj4DXn8esh3z25EBnJeUmluVxH+CJ7hf9UOSn0zm/gqzG0m8j K6wEqrjVuR2zY3zHb6nxWcaWG7zmbo3jUQxMvsMxVAs1Dhn+/5k81UU8sFal9U8S7O6M h2uBznb2Ra/n13CuU5Yqmg5QQoLik6Jl8h8MSMlXJvDblYGlPaDd+ZdTmgTV3H3joWD6 4irg== X-Received: by 10.194.237.101 with SMTP id vb5mr35930447wjc.30.1418472270944; Sat, 13 Dec 2014 04:04:30 -0800 (PST) Received: from venice.bhome (ppp-49-20.24-151.libero.it. [151.24.20.49]) by mx.google.com with ESMTPSA id n3sm5329239wjz.21.2014.12.13.04.04.30 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 13 Dec 2014 04:04:30 -0800 (PST) From: Goffredo Baroncelli X-Google-Original-From: Goffredo Baroncelli To: linux-btrfs@vger.kernel.org Cc: Goffredo Baroncelli Subject: [PATCH] BUG: use metadata_profile instead of data_profile Date: Sat, 13 Dec 2014 13:05:51 +0100 Message-Id: <1418472351-5113-2-git-send-email-kreijack@inwind.it> X-Mailer: git-send-email 2.1.3 In-Reply-To: <1418472351-5113-1-git-send-email-kreijack@inwind.it> References: <1418472351-5113-1-git-send-email-kreijack@inwind.it> 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, T_DKIM_INVALID, T_RP_MATCHES_RCVD, 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 The function test_num_disk_vs_raid() show an error message if the raid profile is incompatible with the number of devices. Unfortunately when the error is related to data profile, the message print the metadata profile. This patch correct the bug. Signed-off-by: Goffredo Baroncelli --- utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils.c b/utils.c index fc69e9b..e1b56ac 100644 --- a/utils.c +++ b/utils.c @@ -2116,7 +2116,7 @@ int test_num_disk_vs_raid(u64 metadata_profile, u64 data_profile, if (data_profile & ~allowed) { snprintf(estr, sz, "unable to create FS with data " "profile %llu (have %llu devices)\n", - metadata_profile, dev_cnt); + data_profile, dev_cnt); return 1; }