From patchwork Fri Jan 8 18:14:31 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Matias_Bj=C3=B8rling?= X-Patchwork-Id: 7988671 Return-Path: X-Original-To: patchwork-linux-block@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 25400BEEED for ; Fri, 8 Jan 2016 18:17:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 64574201CE for ; Fri, 8 Jan 2016 18:17:50 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5A57E201EC for ; Fri, 8 Jan 2016 18:17:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756313AbcAHSRs (ORCPT ); Fri, 8 Jan 2016 13:17:48 -0500 Received: from mail-wm0-f45.google.com ([74.125.82.45]:37622 "EHLO mail-wm0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932417AbcAHSOs (ORCPT ); Fri, 8 Jan 2016 13:14:48 -0500 Received: by mail-wm0-f45.google.com with SMTP id f206so183748406wmf.0 for ; Fri, 08 Jan 2016 10:14:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bjorling.me; s=google; h=from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; bh=vDqBnHUG1LlAYzecqVcDN2NCnzd83KYSfG0BleljZPg=; b=oAYk8xQ94sFRvtiUixkD9LCnVAJO3WndMCdF9FU4GBQu5tUUXK458/67svd4nMUG0F a1vb2xEJJM2r7NsqYi3/RtW5F85mRwi/L/UZ5XzvGEwdLeVU4XqXP8hRcc40FwWGt+Sp atC/iBzMq4VrOf1JPfrtnPsZcVfWWQb09Nf4k= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-type:content-transfer-encoding; bh=vDqBnHUG1LlAYzecqVcDN2NCnzd83KYSfG0BleljZPg=; b=P8XA0krSVpmB2paCdfLUfZQd/0xYpAiJHCSpRfWoMuhAQBMKNR7QZNfeNE0+l8gWpZ jvPNb8Der4WcW46eTam/SqEwAjjbKPch3ONwVYCDd5vGbMORy+N5j8ih2rHZQjRZDKZq i92G8dL/EIMC3IeoInQjiaCN1mRleqahJf7ZsMSqcGqRw4qwts04ZGYzO2ySXmWY9+O/ UHCt29GhMXZfGAh5P+8hQ1npEj7b4ESvAvwM2d6kHxusV6nnScCTfH5Yt+INgtgzyrno azVBZogCmLCsnUkXWjy2jLJowqBDbw/JdNryVp+bBfIMuqTg/U0dsq2Al/IE4j+WAMLD bpNg== X-Gm-Message-State: ALoCoQkQv5kbvTyy00gshehUDe9jpLN3xGIPoYEpnEA3ruygKlbxdiSzEdSQzivxUxSkLqWejf2Zb8SWSQq0i6JUyuuBzqS34w== X-Received: by 10.28.22.199 with SMTP id 190mr318993wmw.54.1452276887314; Fri, 08 Jan 2016 10:14:47 -0800 (PST) Received: from localhost.localdomain (6164198-cl69.boa.fiberby.dk. [193.106.164.198]) by smtp.gmail.com with ESMTPSA id t9sm52713200wjf.33.2016.01.08.10.14.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 08 Jan 2016 10:14:46 -0800 (PST) From: =?UTF-8?q?Matias=20Bj=C3=B8rling?= To: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org Cc: =?UTF-8?q?Matias=20Bj=C3=B8rling?= Subject: [PATCH 1/7] lightnvm: fix missing grown bad block type Date: Fri, 8 Jan 2016 19:14:31 +0100 Message-Id: <1452276877-390-1-git-send-email-m@bjorling.me> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, 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 The get/set bad block interface defines good block, factory bad block, grown bad block, device reserved block, and host reserved block. Unfortunately the grown bad block was missing, leaving the offsets wrong for device and host side reserved blocks. This patch adds the missing type and corrects the offsets. Signed-off-by: Matias Bjørling --- include/linux/lightnvm.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/include/linux/lightnvm.h b/include/linux/lightnvm.h index 96c8ad1..aa35907 100644 --- a/include/linux/lightnvm.h +++ b/include/linux/lightnvm.h @@ -58,8 +58,9 @@ enum { /* Block Types */ NVM_BLK_T_FREE = 0x0, NVM_BLK_T_BAD = 0x1, - NVM_BLK_T_DEV = 0x2, - NVM_BLK_T_HOST = 0x4, + NVM_BLK_T_GRWN_BAD = 0x2, + NVM_BLK_T_DEV = 0x4, + NVM_BLK_T_HOST = 0x8, }; struct nvm_id_group {