Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5724147ybv; Tue, 18 Feb 2020 02:48:19 -0800 (PST) X-Google-Smtp-Source: APXvYqxlNgoAq8K8cI6xagYgM8wUD0dcCZzap0NqhX0THTDLwaaB2T/0aP5T0nRUwXGr4HcVy0S0 X-Received: by 2002:aca:4994:: with SMTP id w142mr768931oia.178.1582022898982; Tue, 18 Feb 2020 02:48:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582022898; cv=none; d=google.com; s=arc-20160816; b=aBib2SpXwrY+4ZaHb2uyY4gxYbRnZqTZLjanNv8++Ka8uFl0/YoxFWJXLKe639fh9S WD+GYlOj6aDTfKC+C492SaRgYawGcw/e4kESTeNsNorgUu4sdg0BXkbE7ZTiZjlNbUIn H9vw35vV3VbdERoUG8J211Pglty3bGAv7w/vDiEiA6ISleQY0I93aqud1RkzfqWExxQy M/fOzrwx6h/7sBIABxpHkKKwKC5mn2OYF3gYNwl3kV0AtLnPP33l7vXHAY3kPPBjQ8TO KUVg/maaRsO12TOq7L6aMDeUms4Fq5Jy+hINnepESIFnervSXMFjTLRhZFy0SXNB/6S/ o06w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=JcejbRUKsGk+OG3oKsVBzJ+3XJts6yo0MTGeb2ahzYQ=; b=Y4+puYtEa4kfWC3lbdB/lC6tiA5WodBASH8HX8xWvX/v0pb5JTfw7uHNjRf4kUjQV6 oyJLY7MrZmJmdesAhhRVBHC9LbCrv58OZdpxy7aG1zAFFkfIobuSpXLcC/Eff8pPOXip O3/CF/AW7xmIolVvsIFqhxqveIVCfG/13SNHScFbhGvbWQfpga1dMvnCpHHW9P7hxW+w pqL9MsSeiGlsbCL9wiCyg9NH5GxSGsx5PnB3jHzSBtdYSl7fsGObioOd4M25+tD2RKoS Y28cvw6mHZPqJvmAPPaVsNPELChf/CQ1/bVlb6BZRB/vYw4HQLqZBqja3wHlrzqYg/TT v4uA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q131si7930491oig.203.2020.02.18.02.48.06; Tue, 18 Feb 2020 02:48:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726403AbgBRKry convert rfc822-to-8bit (ORCPT + 99 others); Tue, 18 Feb 2020 05:47:54 -0500 Received: from relay11.mail.gandi.net ([217.70.178.231]:39791 "EHLO relay11.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726298AbgBRKry (ORCPT ); Tue, 18 Feb 2020 05:47:54 -0500 Received: from xps13 (lfbn-tou-1-1151-102.w90-76.abo.wanadoo.fr [90.76.211.102]) (Authenticated sender: miquel.raynal@bootlin.com) by relay11.mail.gandi.net (Postfix) with ESMTPSA id 0F8B8100003; Tue, 18 Feb 2020 10:47:51 +0000 (UTC) Date: Tue, 18 Feb 2020 11:47:51 +0100 From: Miquel Raynal To: Piotr Sroka Cc: Kazuhiro Kasai , Richard Weinberger , David Woodhouse , Brian Norris , Marek Vasut , Vignesh Raghavendra , , Subject: Re: [PATCH 3/4] mtd: rawnand: cadence: change bad block marker size Message-ID: <20200218114751.70efa015@xps13> In-Reply-To: <1581328530-29966-3-git-send-email-piotrs@cadence.com> References: <1581328530-29966-1-git-send-email-piotrs@cadence.com> <1581328530-29966-3-git-send-email-piotrs@cadence.com> Organization: Bootlin X-Mailer: Claws Mail 3.17.4 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Piotr, Piotr Sroka wrote on Mon, 10 Feb 2020 10:55:27 +0100: > Increase bad block marker size from one byte to two bytes. > Bad block marker is handled by skip bytes feature of HPNFC. > Controller excpects this value to be an even number. expects Do we break existing users with this change? Do you know how the controller behaved until now? Also needs a Fixes/stable tag I guess? > > Signed-off-by: Piotr Sroka > --- > drivers/mtd/nand/raw/cadence-nand-controller.c | 9 +++------ > 1 file changed, 3 insertions(+), 6 deletions(-) > > diff --git a/drivers/mtd/nand/raw/cadence-nand-controller.c b/drivers/mtd/nand/raw/cadence-nand-controller.c > index 2ebfd0934739..5c1bbb05ab51 100644 > --- a/drivers/mtd/nand/raw/cadence-nand-controller.c > +++ b/drivers/mtd/nand/raw/cadence-nand-controller.c > @@ -2612,12 +2612,9 @@ int cadence_nand_attach_chip(struct nand_chip *chip) > chip->options |= NAND_NO_SUBPAGE_WRITE; > > cdns_chip->bbm_offs = chip->badblockpos; > - if (chip->options & NAND_BUSWIDTH_16) { > - cdns_chip->bbm_offs &= ~0x01; > - cdns_chip->bbm_len = 2; > - } else { > - cdns_chip->bbm_len = 1; > - } > + cdns_chip->bbm_offs &= ~0x01; > + /* this value should be even number */ > + cdns_chip->bbm_len = 2; > > ret = nand_ecc_choose_conf(chip, > &cdns_ctrl->ecc_caps, Thanks, Miquèl