at91sam9x5: fix ROM base address (bugfix for nand ECC)i
The ROM base address in the 9x5 processors lives at 1M, not 4M,
where SMD is, as defined later in the same file.

The ROM includes some tables that are used to build error-correction data
for NAND memory.  By using the wrong address, we get wrong data and
the result is undetected bit flips (data at 0x408000 is all zeroes).

Thus, even though our kernel was fixing bit errors in NAND, barebox
was not fixing them. With UBI (our situation) we got I/O errors because
the checksum verification for data nodes failed.

Using the proper address corrects the problem: barebox reports a
"bitflip" message, consistent with the kernel message for the same
file, and the files are properly loaded and booted.

Note: the kernel has the same wrong define, but then the magic number
0x00108000 as spelled in arch/arm/boot/dts/at91sam9x5.dtsi is used
instead of the symbolic name.

Signed-off-by: Edoardo Scaglia <scaglia@amelchem.com>
Signed-off-by: Federico Braghiroli <braghiroli@amelchem.com>
Signed-off-by: Alessandro Rubini <rubini@gnudd.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 16a6d8a commit 49a1eeb04b3e47d79e2bb08ff5fbdad945819872
@Edoardo Scaglia Edoardo Scaglia authored on 1 Oct 2015
Sascha Hauer committed on 2 Oct 2015
Showing 1 changed file
View
arch/arm/mach-at91/include/mach/at91sam9x5.h