From patchwork Tue Jun 12 11:29:18 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Matias Bjorling X-Patchwork-Id: 10460091 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 16F846020F for ; Tue, 12 Jun 2018 11:30:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 073F028712 for ; Tue, 12 Jun 2018 11:30:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 05B2C2870E; Tue, 12 Jun 2018 11:30:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 210DB28725 for ; Tue, 12 Jun 2018 11:30:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754337AbeFLL3c (ORCPT ); Tue, 12 Jun 2018 07:29:32 -0400 Received: from mail-lf0-f66.google.com ([209.85.215.66]:43279 "EHLO mail-lf0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754048AbeFLL3b (ORCPT ); Tue, 12 Jun 2018 07:29:31 -0400 Received: by mail-lf0-f66.google.com with SMTP id n15-v6so35428844lfn.10 for ; Tue, 12 Jun 2018 04:29:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lightnvm-io.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZvEAc39P434CkCcOSMTcAuUZ3KCu4b2yBOGy1PfwQJ4=; b=S+5ZXhRpryAjvQWtS1AUtHpPEOPLoPXoeJpEm3/PwYjkW/TWekZ8IEtQBsI1NJsqQU WYgTzAruJSmilFmGICB/V/IFuuz3TTVlESEVmk+Ju+0DjpOCWhr7rWKsVHFhOw2GUYcJ UgJ6Bhqy+l2+wy7RzMKMd5ewLzKxqzNOUkdGG+N68l6mrkIhpg9pFIspe2XwXpOfCI6O lRnZTbRXsnMcHRXIzwsS7kGBQzp3ETogCbjRvOHc1hGpUB5YC4RfWmhbGh+B3A3hlabw xCfi74ZgkqypLkm3A7MsXxg/E832BZPxkncyn0BUfa66PRUXw93MvpmfX4DpHoPNU+Ic 8hEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZvEAc39P434CkCcOSMTcAuUZ3KCu4b2yBOGy1PfwQJ4=; b=JFTXHRmq6cjI2d4Imd7vPJirkbaR2AlfRdmLEq9VRh5TVCxwHc8H/zh6B4Klp2HRUL TwB6Ysiqs7l7HX8HfPV7VldkJsC+bGbTuPHsS2+A9187AZ7H9oXvdnn8r/e51q9EdqWs bY+fw/GoNBZ65f2z0BeaGtTWzphhb3b4DAkDU944dSMQ+6zaBqJR4iUyadxVdDKxidjs JzjNlnc+x6Xa9T1iJSAqpgzbdGRK9v8rJzMXfK1QlquQhVwcqMMh5UIIgQEO47wvr1YK D7dFLIsPCQh2qkftHUqCGLYCXtSDAI8Irp0PNLjpEHiELbdeyXcE1le5I81Lhx9OsUMl b/4g== X-Gm-Message-State: APt69E0LYfr92NPMBRziWkvweR7GcEA6Zi4KoRpyGYJrbwS+qz91Ex32 /+VtcNi/vp3CXHXgw0h4oTDoNg== X-Google-Smtp-Source: ADUXVKIyIGbKSRPNrU6VZSIVm/062sSl6FOsvsuXQFc4vJXWFoK8dWMTdSMCgkTgIRfb4LUegGk4tg== X-Received: by 2002:a2e:96c6:: with SMTP id d6-v6mr2147774ljj.21.1528802970027; Tue, 12 Jun 2018 04:29:30 -0700 (PDT) Received: from Macroninja.cnexlabs.com (95-166-82-66-cable.dk.customer.tdc.net. [95.166.82.66]) by smtp.gmail.com with ESMTPSA id h99-v6sm180779lji.19.2018.06.12.04.29.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 12 Jun 2018 04:29:28 -0700 (PDT) From: =?UTF-8?q?Matias=20Bj=C3=B8rling?= To: igor.j.konopko@intel.com, marcin.dziegielewski@intel.com, javier@cnexlabs.com, hans.holmberg@cnexlabs.com Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, =?UTF-8?q?Matias=20Bj=C3=B8rling?= Subject: [PATCH 2/2] lightnvm: pblk: enable line minor version detection Date: Tue, 12 Jun 2018 13:29:18 +0200 Message-Id: <20180612112918.25795-2-mb@lightnvm.io> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180612112918.25795-1-mb@lightnvm.io> References: <20180612112918.25795-1-mb@lightnvm.io> MIME-Version: 1.0 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP When recovering a line, an extra check was added when debugging was active, such that minor version where also checked. Unfortunately, this used the ifdef NVM_DEBUG, which is not correct. Instead use the proper DEBUG def, and now that it compiles, also fix the variable. Signed-off-by: Matias Bjørling Fixes: d0ab0b1ab991f ("lightnvm: pblk: check data lines version on recovery") Reviewed-by: Javier González --- drivers/lightnvm/pblk-recovery.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/lightnvm/pblk-recovery.c b/drivers/lightnvm/pblk-recovery.c index 598342833d0d..b1a91cb3ca4d 100644 --- a/drivers/lightnvm/pblk-recovery.c +++ b/drivers/lightnvm/pblk-recovery.c @@ -742,9 +742,10 @@ static int pblk_recov_check_line_version(struct pblk *pblk, return 1; } -#ifdef NVM_DEBUG +#ifdef CONFIG_NVM_PBLK_DEBUG if (header->version_minor > EMETA_VERSION_MINOR) - pr_info("pblk: newer line minor version found: %d\n", line_v); + pr_info("pblk: newer line minor version found: %d\n", + header->version_minor); #endif return 0;