From patchwork Thu Feb 21 09:15:12 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Miquel Raynal X-Patchwork-Id: 10823323 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5D09114E1 for ; Thu, 21 Feb 2019 09:16:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4B817301EA for ; Thu, 21 Feb 2019 09:16:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3F088301FC; Thu, 21 Feb 2019 09:16:41 +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=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D127E301EA for ; Thu, 21 Feb 2019 09:16:40 +0000 (UTC) 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: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:In-Reply-To:References: List-Owner; bh=ZkAwVs/ug7mC8KYNnthwMAkv6vpSLfd5fi2/mhVDCJU=; b=J+bLz4R5XQSmmo +8qfOpFd/VNOhx4VfyxAHHUvL7WAkZ2yW7OaE3SErBkEwJS4ZsyyT8Dbs/fAeu1kO/3BaT+sx5xfQ MLbsKta6j1UEhZQDJgyahZmIt1xscnbLWinkmcYmy1I5vs/L5fHvB0G4qq77O7ZbY2FkGcEYRWPJ3 g1t/yzrDxpQTHiIikEn0VwWrVtnrkdkXRqbjK9M1RWxfpdQyeJb0rkRu/eJFkQ2o0mkb4YfThg3wG 72f79CckzEnRqWt8BNwzIdL2dAhCZzVPMP+zW8OsLPaXJG2x+zxeWbBmYDCmGdBibKlXfG9Reb+Yr SvqTR0w4AlXYvUVA6xVg==; 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 1gwkT4-0002S3-1Y; Thu, 21 Feb 2019 09:16:34 +0000 Received: from relay8-d.mail.gandi.net ([217.70.183.201]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gwkSF-0001T3-EV; Thu, 21 Feb 2019 09:15:47 +0000 X-Originating-IP: 90.88.23.190 Received: from localhost.localdomain (aaubervilliers-681-1-81-190.w90-88.abo.wanadoo.fr [90.88.23.190]) (Authenticated sender: miquel.raynal@bootlin.com) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id B987B1BF20A; Thu, 21 Feb 2019 09:15:29 +0000 (UTC) From: Miquel Raynal To: Boris Brezillon , Richard Weinberger , David Woodhouse , Brian Norris , Marek Vasut , Tudor Ambarus Subject: [PATCH 00/15] mtd: rawnand: 5th batch of cleanups Date: Thu, 21 Feb 2019 10:15:12 +0100 Message-Id: <20190221091527.20497-1-miquel.raynal@bootlin.com> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190221_011543_829936_7DF3E46A X-CRM114-Status: GOOD ( 10.27 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Vignesh R , Tudor Ambarus , Julien Su , Masahiro Yamada , linux-mtd@lists.infradead.org, Thomas Petazzoni , Miquel Raynal , Mason Yang , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Hello, This time I am the one who send the cleanups on behalf of Boris, I just took his patches because I needed them for my 'generic ECC engine' work. Between this cleanup series and the ECC engine series there will be an additional one, to prepare the field. Patch 1 adds a field to the memorg structure, patch 2 & 3 add helpers in the raw NAND core, following patches are general cleanups in the raw NAND area that prepares the use of the (generic) NAND core shared between raw NANDs and SPI-NANDs and finally a few nand_chip entries are dropped. Regards, Miquèl Boris Brezillon (15): mtd: nand: Add max_bad_eraseblocks_per_lun info to memorg mtd: nand: Add an helper returning the number of eraseblocks per target mtd: nand: Add an helper to retrieve the number of pages per target mtd: spinand: Implement mtd->_max_bad_blocks mtd: rawnand: Use nand_to_mtd() in nand_{set,get}_flash_node() mtd: rawnand: Prepare things to reuse the generic NAND layer mtd: rawnand: Fill memorg during detection mtd: rawnand: Initialize the nand_device object mtd: rawnand: Provide an helper to get chip->data_buf mtd: rawnand: Move all page cache related fields to a sub-struct mtd: rawnand: Use nanddev_mtd_max_bad_blocks() mtd: rawnand: Get rid of chip->bits_per_cell mtd: rawnand: Get rid of chip->chipsize mtd: rawnand: Get rid of chip->numchips mtd: rawnand: Get rid of chip->ecc_{strength,step}_ds drivers/mtd/nand/core.c | 34 +++ drivers/mtd/nand/raw/Kconfig | 1 + drivers/mtd/nand/raw/atmel/nand-controller.c | 8 +- .../mtd/nand/raw/bcm47xxnflash/ops_bcm4706.c | 2 +- drivers/mtd/nand/raw/brcmnand/brcmnand.c | 7 +- drivers/mtd/nand/raw/denali.c | 6 +- drivers/mtd/nand/raw/diskonchip.c | 6 +- drivers/mtd/nand/raw/fsl_elbc_nand.c | 4 +- drivers/mtd/nand/raw/fsl_ifc_nand.c | 4 +- drivers/mtd/nand/raw/gpmi-nand/gpmi-nand.c | 17 +- drivers/mtd/nand/raw/hisi504_nand.c | 2 +- drivers/mtd/nand/raw/internals.h | 2 +- drivers/mtd/nand/raw/jz4740_nand.c | 7 +- drivers/mtd/nand/raw/marvell_nand.c | 49 ++-- drivers/mtd/nand/raw/mtk_nand.c | 4 +- drivers/mtd/nand/raw/nand_amd.c | 11 +- drivers/mtd/nand/raw/nand_base.c | 253 +++++++++++------- drivers/mtd/nand/raw/nand_bbt.c | 45 ++-- drivers/mtd/nand/raw/nand_esmt.c | 10 +- drivers/mtd/nand/raw/nand_hynix.c | 90 ++++--- drivers/mtd/nand/raw/nand_jedec.c | 27 +- drivers/mtd/nand/raw/nand_micron.c | 14 +- drivers/mtd/nand/raw/nand_onfi.c | 35 ++- drivers/mtd/nand/raw/nand_samsung.c | 42 +-- drivers/mtd/nand/raw/nand_toshiba.c | 19 +- drivers/mtd/nand/raw/nandsim.c | 11 +- drivers/mtd/nand/raw/qcom_nandc.c | 8 +- drivers/mtd/nand/raw/sh_flctl.c | 9 +- drivers/mtd/nand/raw/sunxi_nand.c | 15 +- drivers/mtd/nand/raw/tegra_nand.c | 8 +- drivers/mtd/nand/spi/core.c | 1 + drivers/mtd/nand/spi/gigadevice.c | 6 +- drivers/mtd/nand/spi/macronix.c | 4 +- drivers/mtd/nand/spi/micron.c | 2 +- drivers/mtd/nand/spi/toshiba.c | 2 +- drivers/mtd/nand/spi/winbond.c | 4 +- include/linux/mtd/nand.h | 32 ++- include/linux/mtd/rawnand.h | 97 ++++--- 38 files changed, 548 insertions(+), 350 deletions(-)