From patchwork Wed Jul 27 09:37:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Nazzareno Trimarchi X-Patchwork-Id: 2261 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-ed1-f72.google.com (mail-ed1-f72.google.com [209.85.208.72]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id E39C33F1F7 for ; Wed, 27 Jul 2022 11:37:52 +0200 (CEST) Received: by mail-ed1-f72.google.com with SMTP id r6-20020a05640251c600b0043c1883836csf4467579edd.8 for ; Wed, 27 Jul 2022 02:37:52 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1658914672; cv=pass; d=google.com; s=arc-20160816; b=U7vX5T6elBbJRQlj59zRX6pYdv2m9j5kQPee9XAvppLVdm3q00y+pByEd52eLG/NH3 IZZVXQnFl7kwz/ar3BhL9sJ3BCir7v//mb0s2OQAIUaZbvWSdlDwiV/MnnM9ogcHTtzQ 8/3DRuWLq240R6vBIPgllSADda4WgRB+xtrHlKI9DFwbCT1isLQObAQ0NAokdG3hgIEZ MdkYqzxdrvsQTo1fTl4WvSWSsPMSecfRa4h2vYEI/MbACq8R2rHY08bX15sxd2VLyUdV y2cTR1xUB+iWB6fLgDCF0xOMeKFje2arGBqW93CtkqeeiLaWPBpLif7tE+EuvTRa9m37 PFXg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:message-id:date:subject:to :from:dkim-signature; bh=8kfjTHqNN7M8O82+J5V33Q3OvreI34jaE5K28ZeUjTk=; b=jGRozCARe2s9lfCdazi8aSSdZbVLZ+HC6dyZ7o2jjmvfKROYO01UD39RYqR+XVwVoB 6nSqMgqvJ6LLR8Axg6pIR+8VKy/OVp1W69bDLiDI7vUw50DozavMMDlOBe0sjNZvzDFc dCwEL15a82Vw2x0DmSwVeI+90BhomKJhGUFX0A8FAUY0dWYYWc4q6z/26r91g4MR42JO UFGsGmXRk62+GHGuM7Ceit1vUkztfBT4DcLoBgFSmQo3YnCzlWsyDQLb/iTTUiTKSCX5 H40pqK3b0nPrTWNGsAijyDnWmSOtManW6WXlfxLicO80E3btBzT+KZz6iWWW5+P7dF6w f1lA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=S3egSQuN; spf=pass (google.com: domain of michael@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=michael@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:subject:date:message-id:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=8kfjTHqNN7M8O82+J5V33Q3OvreI34jaE5K28ZeUjTk=; b=cxNA7aABDBfKhcUm6Oai+IyrTcLZcolxbb5QzgvtcK5+EsuEBXBGNmtvGc0IBCpA6B asM6jQ8UBWyoNt/li4VZOjZ+xSr2O80wfSMbF0G6j23vTzdATQJmBRTiwW1hL0ZNEWVu nRyhsJaCfSJc8pUZMTrMfyTnKrq6OoK9q38Xk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :x-original-sender:x-original-authentication-results:precedence :mailing-list:list-id:x-spam-checked-in-group:list-post:list-help :list-archive:list-unsubscribe; bh=8kfjTHqNN7M8O82+J5V33Q3OvreI34jaE5K28ZeUjTk=; b=BrZ3NKAwgCxYSomXIgEflaJ2pMiyn3YLfnq2RHq0tuHyoCE5a74VeQ1qoObV+z2CMa MXmhFCJKB5f6bbJhIGlDCnYlUTymKHVbpzqahdrCjpNqnR7N+C+9uQ3eC8zGXgFQf1h+ s66aSOkgzF2IqVDSNhoLFgNJz+baSvBKQrom5IpBoILr4d3P5rDPISx3PbV2/EJoa/2a nN1EeieCcOtdMRL60meukz65laaTr1rqh4HqEjrPU4iZxzblwAcSDLB1t4OwUhoP92Io tcv3AIwj5YVNaQY0lNUTNbRKTXckiMAaAHr6OHp7v6Eyl+8RRrYviPCAl/k1lDwS5O9e k0wA== X-Gm-Message-State: AJIora/+DYPaeDiFilLx5J9ZwWGSuZ3BbQNrpnpzK6NL0a7JuLtX3xfw HgEM76127N6bYzcL83K12l/eejrf X-Google-Smtp-Source: AGRyM1s/XpejmhyqAYDEzumCSpyM3VxunJ6XTt92mLf3+ceYRGXTHgxAMEeohsh+f55akyYNtleH8Q== X-Received: by 2002:a05:6402:3217:b0:43b:dee8:4cb6 with SMTP id g23-20020a056402321700b0043bdee84cb6mr20801620eda.157.1658914672572; Wed, 27 Jul 2022 02:37:52 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6402:5253:b0:425:ff69:1a2d with SMTP id t19-20020a056402525300b00425ff691a2dls313952edd.1.-pod-prod-gmail; Wed, 27 Jul 2022 02:37:51 -0700 (PDT) X-Received: by 2002:a05:6402:2685:b0:43c:3c9a:816 with SMTP id w5-20020a056402268500b0043c3c9a0816mr9276630edd.92.1658914671229; Wed, 27 Jul 2022 02:37:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658914671; cv=none; d=google.com; s=arc-20160816; b=n7zX9K/PIhGqhh3vzcumARXlPoxDw4AeleWWtU6IMUU6Di8hHp80ncCakLj18/Bt7/ m5EUPYH78yq1QD1VDavaIPOhZDHVwEbkhFk0s05uI8DC725cNXIB3TaISkUaP0n4YQrp JOYIFWziLMbCaL6IdnLgzykxK4/0jb2GmCrszZqD5UFTNXtWPQvGt4anGlvP+v/AyCCB iG0Qn1mig1UCDOuiR6ArdNdLp7skRc4sJb8WTM0c0VxDZvxH6bMI/tHYURGjWbPx/iJT O7n8skSjiOqoKEKUbyTrXc051NA1hxEbrnI3wrhMHzVwHZBaiMJfuqHK47HaILe3A4LH J+Sw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:dkim-signature; bh=bh4VbXLwL7m3bRoN0bY5wzyGiQUx8YqdfbbyQA0hAhs=; b=lul64gxDqC9XGghU1Mefu2nFRBzmM3czM5PHjASUekMKVNxpeF1clVSA0l/l3nnyIm Bt7ruSgZTRlz5+qSbpGSsXCdaHwJBb18a7Sxs1DkIF+2LoZlEspeEaTgEFeoG8Nr4kLJ PDcGa30M7y5LxsryykZ/9MEHmMy/5OSwcZTDVWMon38StKw6On1EA0Y0Ep/AZRMEYb/F 542N1BBSgZYPhAVUi6aiLm2KW2g9HMEp6z0MqBxSQimraPG/0Z4koL3OsE4FxhRcDQ34 nqUk0W5TOgUUvGT4rsHIoVx733Rz7PBVZKkOMTOCKXCfWdo3kzB3zdVpaQE8pg2M52Vu vzXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=S3egSQuN; spf=pass (google.com: domain of michael@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=michael@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id n3-20020a05640205c300b0043bc6c29df3sor8075215edx.68.2022.07.27.02.37.51 for (Google Transport Security); Wed, 27 Jul 2022 02:37:51 -0700 (PDT) Received-SPF: pass (google.com: domain of michael@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:a05:6402:270d:b0:43c:2e9:53ae with SMTP id y13-20020a056402270d00b0043c02e953aemr13754160edd.135.1658914670624; Wed, 27 Jul 2022 02:37:50 -0700 (PDT) Received: from panicking.amarulasolutions.com (mob-37-181-33-55.net.vodafone.it. [37.181.33.55]) by smtp.gmail.com with ESMTPSA id q22-20020a17090676d600b006fece722508sm7317678ejn.135.2022.07.27.02.37.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Jul 2022 02:37:50 -0700 (PDT) From: Michael Trimarchi To: dario.binacchi@amarulasolutions.com, Tommaso Merciai , linux-amarula@amarulasolutions.com Subject: [PATCH 0/7] NAND new improvements Date: Wed, 27 Jul 2022 11:37:41 +0200 Message-Id: <20220727093748.1415135-1-michael@amarulasolutions.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Original-Sender: michael@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=S3egSQuN; spf=pass (google.com: domain of michael@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=michael@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Another series that move the mtd stack to be more similar to the linux one. This series include even the merging of the spl part of mxs and mt7621 in order to create a common layer for new driver and avoid duplication and small fixes in mxs nand Michael Trimarchi (7): mtd: nand: Rename the nand_manufacturers struct mtd: nand: change return type of nand_get_flash_type() to int mtd: nand: Rename nand_get_flash_type() into nand_detect() mtd: nand: samsung: Retrieve ECC requirements from extended mtd: nand: Fix ecc in mxs_nand_spl onfi mode mtd: nand: mxs_nand_spl Fix loop exit condition mtd: nand: Add a common spl layer for nand subsystem drivers/mtd/nand/raw/Makefile | 4 +- drivers/mtd/nand/raw/mt7621_nand.c | 9 +- drivers/mtd/nand/raw/mt7621_nand_spl.c | 188 +------------------ drivers/mtd/nand/raw/mxs_nand_spl.c | 190 ++----------------- drivers/mtd/nand/raw/nand_base.c | 37 ++-- drivers/mtd/nand/raw/nand_common_spl.c | 245 +++++++++++++++++++++++++ drivers/mtd/nand/raw/nand_common_spl.h | 15 ++ drivers/mtd/nand/raw/nand_ids.c | 2 +- drivers/mtd/nand/raw/nand_samsung.c | 20 ++ include/linux/mtd/rawnand.h | 13 +- 10 files changed, 327 insertions(+), 396 deletions(-) create mode 100644 drivers/mtd/nand/raw/nand_common_spl.c create mode 100644 drivers/mtd/nand/raw/nand_common_spl.h