From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, T_DKIMWL_WL_HIGH,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3468DC04AB5 for ; Thu, 6 Jun 2019 08:52:50 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0C5782070B for ; Thu, 6 Jun 2019 08:52:50 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="szgJ7lAw" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0C5782070B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kontron.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mtd-bounces+linux-mtd=archiver.kernel.org@lists.infradead.org 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:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-ID:In-Reply-To: References:Message-ID:Date:Subject:To:From:Reply-To:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=zbWxb4Cj/U/DP2f3q49Itf2EQWxjtmwGOWgL0uCoYdI=; b=szgJ7lAw/Pkm0n Ns4Ijcs0IErzAvK5hINRcvApS5WsWCb2gTdMi6Juk1YuJUDRWt+4EP0MmhbTGsJi2vVqntuAmMbJL IsvXmZoXJQ+B8wqH9xEXMVg/+r29ogTiXf8MrvPA7HA0CUa5BcDfzCbeZMlFuguGoJeh5DVPH1oIS yLWk8biivoqe2SX7o9AFKgdinI0h8/d26NXol0biGH7EGWEvU9s1ROSeNeo9kSq7N6xzT6SHQkAc4 q9XcouWLyxunjSHbtQhz+4R5OMFxqGM9ss07hv/VdPDyLF/wmBjop1vcgE61ET5aadHi7hxizHGOj PDLSqgb4tysvWOhoKv6g==; 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 1hYo8c-00075h-Cq; Thu, 06 Jun 2019 08:52:46 +0000 Received: from skedge04.snt-world.com ([91.208.41.69]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hYo8U-0006y4-LT; Thu, 06 Jun 2019 08:52:40 +0000 Received: from sntmail11s.snt-is.com (unknown [10.203.32.181]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by skedge04.snt-world.com (Postfix) with ESMTPS id 3E8A9661182; Thu, 6 Jun 2019 10:52:23 +0200 (CEST) Received: from sntmail12r.snt-is.com (10.203.32.182) by sntmail11s.snt-is.com (10.203.32.181) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Thu, 6 Jun 2019 10:52:22 +0200 Received: from sntmail12r.snt-is.com ([fe80::e551:8750:7bba:3305]) by sntmail12r.snt-is.com ([fe80::e551:8750:7bba:3305%3]) with mapi id 15.01.1713.004; Thu, 6 Jun 2019 10:52:22 +0200 From: Schrempf Frieder To: Boris Brezillon Subject: Re: [PATCH v2 01/15] mtd: nand: Add max_bad_eraseblocks_per_lun info to memorg Thread-Topic: [PATCH v2 01/15] mtd: nand: Add max_bad_eraseblocks_per_lun info to memorg Thread-Index: AQHU0scN55ZCxKZqF0m+9YUbyTEVtKaLkFoAgAMr1oCAAAOKgIAAA36A Date: Thu, 6 Jun 2019 08:52:22 +0000 Message-ID: <0e04c73d-13cd-4416-569b-ee9e7c19ea4d@kontron.de> References: <20190304201522.11323-1-miquel.raynal@bootlin.com> <20190304201522.11323-2-miquel.raynal@bootlin.com> <5e5d473b-2f08-4230-0920-247c2c463c55@kontron.de> <20190606103951.1d774b9a@collabora.com> In-Reply-To: <20190606103951.1d774b9a@collabora.com> Accept-Language: de-DE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.25.9.193] x-c2processedorg: 51b406b7-48a2-4d03-b652-521f56ac89f3 Content-ID: MIME-Version: 1.0 X-SnT-MailScanner-Information: Please contact the ISP for more information X-SnT-MailScanner-ID: 3E8A9661182.ACF8D X-SnT-MailScanner: Not scanned: please contact your Internet E-Mail Service Provider for details X-SnT-MailScanner-SpamCheck: X-SnT-MailScanner-From: frieder.schrempf@kontron.de X-SnT-MailScanner-To: bbrezillon@kernel.org, boris.brezillon@collabora.com, computersforpeace@gmail.com, dwmw2@infradead.org, emil.lenngren@gmail.com, juliensu@mxic.com.tw, linux-arm-kernel@lists.infradead.org, linux-mtd@lists.infradead.org, marek.vasut@gmail.com, masonccyang@mxic.com.tw, miquel.raynal@bootlin.com, richard@nod.at, thomas.petazzoni@bootlin.com, tudor.ambarus@microchip.com, vigneshr@ti.com, yamada.masahiro@socionext.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190606_015239_033502_C15C8393 X-CRM114-Status: GOOD ( 13.90 ) 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: Mason Yang , Vignesh R , Boris Brezillon , Julien Su , Richard Weinberger , Emil Lenngren , Tudor Ambarus , Marek Vasut , Masahiro Yamada , "linux-mtd@lists.infradead.org" , Thomas Petazzoni , Miquel Raynal , Brian Norris , David Woodhouse , "linux-arm-kernel@lists.infradead.org" Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-mtd" Errors-To: linux-mtd-bounces+linux-mtd=archiver.kernel.org@lists.infradead.org On 06.06.19 10:39, Boris Brezillon wrote: > On Thu, 6 Jun 2019 08:27:11 +0000 > Schrempf Frieder wrote: > >> Hi Emil, >> >> On 04.06.19 10:01, Emil Lenngren wrote: >>> Hi Miquel, >>> >>>> static const struct spinand_info macronix_spinand_table[] = { >>>> SPINAND_INFO("MX35LF1GE4AB", 0x12, >>>> - NAND_MEMORG(1, 2048, 64, 64, 1024, 1, 1, 1), >>>> + NAND_MEMORG(1, 2048, 64, 64, 1024, 40, 1, 1, 1), >>>> NAND_ECCREQ(4, 512), >>>> SPINAND_INFO_OP_VARIANTS(&read_cache_variants, >>>> &write_cache_variants, >>>> @@ -103,7 +103,7 @@ static const struct spinand_info macronix_spinand_table[] = { >>>> SPINAND_ECCINFO(&mx35lfxge4ab_ooblayout, >>>> mx35lf1ge4ab_ecc_get_status)), >>>> SPINAND_INFO("MX35LF2GE4AB", 0x22, >>>> - NAND_MEMORG(1, 2048, 64, 64, 2048, 2, 1, 1), >>>> + NAND_MEMORG(1, 2048, 64, 64, 2048, 20, 2, 1, 1), >>>> NAND_ECCREQ(4, 512), >>> >>> Maybe a bit late to the discussion, but shouldn't 20 and 40 be swapped >>> here, i.e. isn't it the larger flash that has more max bad blocks than >>> the smaller one? >> >> I think Miquel is out of office for some days, so I just checked and you >> are right, the maximum number of bad blocks should be swapped. >> >> Actually there is also a wrong value in the GigaDevice driver: For the >> GD5F4GQ4xA it should be 80 instead of 40. > > Haven't checked the datasheet, but keep in mind that this is the max > number of eraseblock per LUN. The datasheet gives 20 for the 1G type and 40 for the 2G type. Both types have only one LUN. Only the 2G type has 2 planes, but that shouldn't make a difference, right? ______________________________________________________ Linux MTD discussion mailing list http://lists.infradead.org/mailman/listinfo/linux-mtd/