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 Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4758BC433EF for ; Sun, 15 May 2022 09:25:56 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 860E38405A; Sun, 15 May 2022 11:25:53 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=amarulasolutions.com header.i=@amarulasolutions.com header.b="fAgYF3EI"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B52FA8405A; Sun, 15 May 2022 11:25:50 +0200 (CEST) Received: from mail-ej1-x630.google.com (mail-ej1-x630.google.com [IPv6:2a00:1450:4864:20::630]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 1267C83F72 for ; Sun, 15 May 2022 11:25:43 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=michael@amarulasolutions.com Received: by mail-ej1-x630.google.com with SMTP id tk15so46293ejc.6 for ; Sun, 15 May 2022 02:25:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=PYmK0S+t3O0g8+3ntQsGqbsf9tS2JzNFcChqJrfJbxU=; b=fAgYF3EIiHjB8iM2WO/8ygR35hhU+2E0IN620fKLgtaGEM3x3y8530dAVdNdHxb2kE SqeThMaKHEohJefC4+SaGCk2VMwEPNkrKpdffzhi5HkfQbyMxNKC3YaRldSg7WuIz8Ci Q3tt6mAS8Gwrs/X2VR/qlfMN8DmEd83pSsa2k= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=PYmK0S+t3O0g8+3ntQsGqbsf9tS2JzNFcChqJrfJbxU=; b=jnQGbJvkyhU0GoOkqK42OYWZMIXT6T4djgkZ6UKcANNu8V4yH7yAGVXla9za5LAPez 9BOog8jx8hwbx2d8Wl6fJ5p2jE9YOv25vrZBjMRFWZBe3RWiLho9DNFQlzWepW3sWgvf leaDWAOiKUiQPgy1ZUCv1n8oh6qwpRifI0c4TldxjKezlOYgo/ob+V9uBUZYv+62uDOo IWLu+sJgensPY2BA7Am3tqO9fARCR3wcRVRNawnjnl1l+72cmmrbKol/JOnQu+HYRUbd eHoRmVRIVCti3SON/6PYcrbSQtPb+a65kBwRGeKophRemBucELPofFB68bF9fFdfHYuY HyBw== X-Gm-Message-State: AOAM531BXQ31u+sgqQLCIGXSdbTqDa/Eyx+KtqngD5tdzYxZsb0tTDsV fUF2WS8gzFKkzBPPoPBrD/jOfg== X-Google-Smtp-Source: ABdhPJz4aE7iplN6AlCC6OhkxGOux1TNNgeocqHBPOnDZ7yWp1VlHP8YTktOgTNieo20M6IGqN/5+Q== X-Received: by 2002:a17:907:6d17:b0:6f4:6b6e:32da with SMTP id sa23-20020a1709076d1700b006f46b6e32damr11498775ejc.301.1652606742403; Sun, 15 May 2022 02:25:42 -0700 (PDT) Received: from localhost.localdomain (mob-109-118-140-232.net.vodafone.it. [109.118.140.232]) by smtp.gmail.com with ESMTPSA id m17-20020a17090677d100b006f3ef214dc5sm2509888ejn.43.2022.05.15.02.25.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 15 May 2022 02:25:41 -0700 (PDT) From: Michael Trimarchi To: Han Xu , U-Boot-Denx Cc: Ye Li , Stefano Babic , Miquel Raynal , Fabio Estevam , Dario Binacchi , Sean Anderson , linux-amarula@amarulasolutions.com, Jagan Teki , Ariel D'Alessandro , Tom Rini Subject: [PATCH V3 0/5] MXS nand fixes in SPL Date: Sun, 15 May 2022 11:25:33 +0200 Message-Id: <20220515092538.1736154-1-michael@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean Those patches come after some testing of failing in factory on some unit. We found out that the bootrom imx loader was not able to handling badblock. This can be a limit of the implementation right now in imx8mn. Anyway not all the imx platform has the support of this loader. I found some problems on the implementation so I have fixed it up according the experience of Sitara (coming from Dario). I tested only using a Fit Image as a flash container. This version add in the series the fix of cmd_nandbcb and the fix of spl_nand load. I can imagine that a lot of boards and users are affected. I have started to backport this changes in some older uboot and adapt it. Move BSH board using the spl loading instead the romapi Michael Trimarchi (5): nand: raw: mxs_nand: Fix specific hook registration mtd: nand: mxs_nand_spl: Fix bad block skipping arm: mach-imx: cmd_nandbcb fix bad block handling spl: spl_nand: Fix bad block handling in fitImage board: bsh: Switch to nand spl load instead of romapi arch/arm/mach-imx/cmd_nandbcb.c | 21 +++---- board/bsh/imx8mn_smm_s2/spl.c | 3 + common/spl/spl_nand.c | 5 +- drivers/mtd/nand/raw/mxs_nand.c | 32 +++++----- drivers/mtd/nand/raw/mxs_nand_spl.c | 90 ++++++++++++++++------------- 5 files changed, 76 insertions(+), 75 deletions(-) -- 2.25.1