mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Marco Felsch <m.felsch@pengutronix.de>
Cc: Barebox List <barebox@lists.infradead.org>
Subject: Re: [PATCH 13/14] ARM: i.MX: xload nand: Implement i.MX7 support
Date: Wed, 2 Nov 2022 09:46:02 +0100	[thread overview]
Message-ID: <20221102084602.GJ3143@pengutronix.de> (raw)
In-Reply-To: <20221102084118.monxfljt7z2jorjm@pengutronix.de>

On Wed, Nov 02, 2022 at 09:41:18AM +0100, Marco Felsch wrote:
> Hi Sascha,
> 
> On 22-11-01, Sascha Hauer wrote:
> > i.MX7 xload NAND support works like on i.MX6, but the FCB is in a
> > different format. The FCB page uses BCH62 ECC, has 8 ECC chunks with
> > 128 bytes each with a resulting total page size of 1862 bytes. Also
> > the page data is written with a pseudo randomizer enabled.
> > 
> > Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> > ---
> >  arch/arm/mach-imx/include/mach/imx7-regs.h |  1 +
> >  arch/arm/mach-imx/include/mach/xload.h     |  1 +
> >  arch/arm/mach-imx/xload-gpmi-nand.c        | 95 ++++++++++++++++++++--
> >  3 files changed, 91 insertions(+), 6 deletions(-)
> > 
> > diff --git a/arch/arm/mach-imx/include/mach/imx7-regs.h b/arch/arm/mach-imx/include/mach/imx7-regs.h
> > index 1ee7d86e0e..379be9e062 100644
> > --- a/arch/arm/mach-imx/include/mach/imx7-regs.h
> > +++ b/arch/arm/mach-imx/include/mach/imx7-regs.h
> > @@ -118,6 +118,7 @@
> >  #define MX7_ENET1_BASE_ADDR		(MX7_AIPS3_BASE_ADDR + 0x3E0000)
> >  #define MX7_ENET2_BASE_ADDR		(MX7_AIPS3_BASE_ADDR + 0x3F0000)
> >  
> > +#define	MX7_APBH_BASE			0x33000000
> >  #define MX7_GPMI_BASE			0x33002000
> >  #define MX7_BCH_BASE			0x33004000
> >  
> > diff --git a/arch/arm/mach-imx/include/mach/xload.h b/arch/arm/mach-imx/include/mach/xload.h
> > index 82bf663c42..ca0055aee2 100644
> > --- a/arch/arm/mach-imx/include/mach/xload.h
> > +++ b/arch/arm/mach-imx/include/mach/xload.h
> > @@ -12,6 +12,7 @@ int imx6_spi_start_image(int instance);
> >  int imx6_esdhc_start_image(int instance);
> >  int imx6_nand_start_image(void);
> >  int imx7_esdhc_start_image(int instance);
> > +int imx7_nand_start_image(void);
> >  int imx8m_esdhc_load_image(int instance, bool start);
> >  int imx8mn_esdhc_load_image(int instance, bool start);
> >  int imx8mp_esdhc_load_image(int instance, bool start);
> > diff --git a/arch/arm/mach-imx/xload-gpmi-nand.c b/arch/arm/mach-imx/xload-gpmi-nand.c
> > index 7e4033d74f..edffd69e6b 100644
> > --- a/arch/arm/mach-imx/xload-gpmi-nand.c
> > +++ b/arch/arm/mach-imx/xload-gpmi-nand.c
> > @@ -13,6 +13,7 @@
> >  #include <linux/mtd/rawnand.h>
> >  #include <soc/imx/gpmi-nand.h>
> >  #include <mach/imx6-regs.h>
> > +#include <mach/imx7-regs.h>
> >  #include <mach/clock-imx6.h>
> >  #include <dma/apbh-dma.h>
> >  
> > @@ -228,7 +229,7 @@ static uint32_t mxs_nand_aux_status_offset(void)
> >  }
> >  
> >  static int mxs_nand_read_page(struct mxs_nand_info *info, int writesize,
> > -		int oobsize, int pagenum, void *databuf, int raw)
> > +		int oobsize, int pagenum, void *databuf, int raw, bool randomizer)
> 
> Here the change comes, so this anwers my question.

Yes, moved the offending hunk here.

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



  reply	other threads:[~2022-11-02  8:47 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-01 15:30 [PATCH 00/14] Add i.MX7 NAND xload support Sascha Hauer
2022-11-01 15:30 ` [PATCH 01/14] mtd: nand: nand-mxs: Move register definitions to separate file Sascha Hauer
2022-11-02  8:08   ` Marco Felsch
2022-11-01 15:30 ` [PATCH 02/14] ARM: i.MX: xload nand: Use common register defines Sascha Hauer
2022-11-02  8:10   ` Marco Felsch
2022-11-01 15:30 ` [PATCH 03/14] ARM: i.MX: xload nand: add common readid Sascha Hauer
2022-11-02  8:23   ` Marco Felsch
2022-11-01 15:30 ` [PATCH 04/14] dma: apbh-dma: Simplify code Sascha Hauer
2022-11-01 15:30 ` [PATCH 05/14] dma: apbh-dma: unify register defines Sascha Hauer
2022-11-01 15:30 ` [PATCH 06/14] ARM: i.MX: xload-gpmi-nand: refactor for more SoC support Sascha Hauer
2022-11-01 15:30 ` [PATCH 07/14] imx-bbu-nand-fcb: pull printing debug info out of get_fcb() Sascha Hauer
2022-11-01 15:30 ` [PATCH 08/14] ARM: i.MX: xload nand: Pull ECC status checking out of read page Sascha Hauer
2022-11-02  8:33   ` Marco Felsch
2022-11-01 15:30 ` [PATCH 09/14] ARM: i.MX: xload nand: Use final page layout from FCB Sascha Hauer
2022-11-01 15:30 ` [PATCH 10/14] imx-bbu-nand-fcb: Fix reading FCB information from BCH registers Sascha Hauer
2022-11-01 15:30 ` [PATCH 11/14] ARM: i.MX: xload nand: reset NAND before accessing it Sascha Hauer
2022-11-01 15:30 ` [PATCH 12/14] ARM: i.MX: xload nand: Move mxs_nand_mode_fcb_62bit() to header file Sascha Hauer
2022-11-02  8:37   ` Marco Felsch
2022-11-01 15:30 ` [PATCH 13/14] ARM: i.MX: xload nand: Implement i.MX7 support Sascha Hauer
2022-11-02  8:41   ` Marco Felsch
2022-11-02  8:46     ` Sascha Hauer [this message]
2022-11-01 15:30 ` [PATCH 14/14] imx-bbu-nand-fcb: Add fcb command Sascha Hauer
2022-11-02  8:44   ` Marco Felsch
2022-11-02 10:55     ` Sascha Hauer
2022-11-02 11:01       ` Marco Felsch
2022-11-02 11:29         ` Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20221102084602.GJ3143@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=m.felsch@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox