From patchwork Tue Jun 19 05:31:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Packham X-Patchwork-Id: 931393 X-Patchwork-Delegate: miquel.raynal@bootlin.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=alliedtelesis.co.nz Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="W9Z4VjX+"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=alliedtelesis.co.nz header.i=@alliedtelesis.co.nz header.b="h7q9Dxv8"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 418xSl1lcCz9s37 for ; Tue, 19 Jun 2018 15:33:11 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=kTvFsK2f/H7akbuIooiKpZybgcuSVllxx6xgSgQVYBc=; b=W9Z4VjX+T6tIfILgu5s642/m/A raSap90nRn9CudLE+0HsTsw5RBwlsY1adJ8nvvpKlJOtCIFgcpvd+33+7IbjO5QYAPz8fQIHfgygk FmNPpLgbwwbsMpxVh0DrA2+wkGS47PfuEOVdGYDKJNBS3ZpxXUvqfq6W4uTrKlYrvCqEBazvech4x zcr7P/NSRCAu/ph81K27r5ZHIUD8MbcdvUOWRWt0C4EjmgzyAKdOKGhP1Za3N8cBuVjasaxCi2gEk lOMWRMEg/zbkRNoq/Jhmhdjl6y6Or2/qbwW8xn4RcKc9ixjhzDZGuOdlr2ASo1L/cCaOe+06wRxmA +tQmyvoA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fV9GI-0006Za-7V; Tue, 19 Jun 2018 05:33:02 +0000 Received: from gate2.alliedtelesis.co.nz ([202.36.163.20]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fV9FH-0005xF-9f for linux-mtd@lists.infradead.org; Tue, 19 Jun 2018 05:32:04 +0000 Received: from mmarshal3.atlnz.lc (mmarshal3.atlnz.lc [10.32.18.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by gate2.alliedtelesis.co.nz (Postfix) with ESMTPS id BDCA684484; Tue, 19 Jun 2018 17:31:42 +1200 (NZST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alliedtelesis.co.nz; s=mail; t=1529386302; bh=+QxjOAv90xsLZbmQ3FloDXnrjuTHlR0rdZo/AYI8UJI=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=h7q9Dxv8qE4jZiUguX5yQv7iKG8g/XF6uc7Tm5hZvUnB5OH0nJ23mQBaPz1c3mINh G6flPgPzHZh3axKivRfPdEHCIoF67CUjG9sj4wbTYLgvoikhHgRvtwWwhvSVFAqvBE 3bkRFttp89J6LDCrZBQyWpnts+altO9iBJahJ62M= Received: from smtp (Not Verified[10.32.16.33]) by mmarshal3.atlnz.lc with Trustwave SEG (v7, 5, 8, 10121) id ; Tue, 19 Jun 2018 17:31:43 +1200 Received: from chrisp-dl.ws.atlnz.lc (chrisp-dl.ws.atlnz.lc [10.33.22.30]) by smtp (Postfix) with ESMTP id 9160213EEAD; Tue, 19 Jun 2018 17:31:45 +1200 (NZST) Received: by chrisp-dl.ws.atlnz.lc (Postfix, from userid 1030) id 779F91E2626; Tue, 19 Jun 2018 17:31:42 +1200 (NZST) From: Chris Packham To: miquel.raynal@bootlin.com, boris.brezillon@bootlin.com, dwmw2@infradead.org, computersforpeace@gmail.com, linux-mtd@lists.infradead.org Subject: [RFC PATCH v2 4/6] mtd: rawnand: marvell: Support page size of 2048 with 8-bit ECC Date: Tue, 19 Jun 2018 17:31:23 +1200 Message-Id: <20180619053125.16792-5-chris.packham@alliedtelesis.co.nz> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180619053125.16792-1-chris.packham@alliedtelesis.co.nz> References: <20180619053125.16792-1-chris.packham@alliedtelesis.co.nz> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180618_223159_542528_6BDB4446 X-CRM114-Status: GOOD ( 10.77 ) X-Spam-Score: -0.1 (/) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-0.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [202.36.163.20 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Richard Weinberger , Chris Packham , linux-kernel@vger.kernel.org, Marek Vasut MIME-Version: 1.0 Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org The MT29F1G08ABAFAWP-ITE:F chip has 2048 byte pages and requires a minimum ECC strength of 8-bits. Allow for this combination of requirements using the marvell_nand controller. Signed-off-by: Chris Packham --- I've tried to follow the recommended AN-379 from Marvell. They do seem to have information that covers this particular set of chip requirements. As discussed I don't think my particular configuration will be supported with this change due to the conflict with the on-die ECC. But this may be useful for others so I've left it in. Changes in v2: - update as suggested by miquel drivers/mtd/nand/raw/marvell_nand.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/mtd/nand/raw/marvell_nand.c b/drivers/mtd/nand/raw/marvell_nand.c index ba6889bbe802..96aee8ffd408 100644 --- a/drivers/mtd/nand/raw/marvell_nand.c +++ b/drivers/mtd/nand/raw/marvell_nand.c @@ -217,6 +217,7 @@ static const struct marvell_hw_ecc_layout marvell_nfc_layouts[] = { MARVELL_LAYOUT( 512, 512, 1, 1, 1, 512, 8, 8, 0, 0, 0), MARVELL_LAYOUT( 2048, 512, 1, 1, 1, 2048, 40, 24, 0, 0, 0), MARVELL_LAYOUT( 2048, 512, 4, 1, 1, 2048, 32, 30, 0, 0, 0), + MARVELL_LAYOUT( 2048, 512, 8, 2, 1, 1024, 0, 30, 1024, 32, 30), MARVELL_LAYOUT( 4096, 512, 4, 2, 2, 2048, 32, 30, 0, 0, 0), MARVELL_LAYOUT( 4096, 512, 8, 5, 4, 1024, 0, 30, 0, 64, 30), };