linux4sam 6 not generating bootable image

Moderator: nferre

nathan
Posts: 4
Joined: Mon Sep 25, 2017 7:18 pm

linux4sam 6 not generating bootable image

Fri Nov 02, 2018 7:22 pm

I'm running an AT91SAM9G25 on an AT91SAM9x5-EK (rev. B) and when I check out https://github.com/linux4sam/buildroot-at91 and build with at91sam9x5ek_defconfig I get this on my console:
RomBOOT


AT91Bootstrap 3.8.11 (Fri Nov 2 12:57:58 EDT 2018)

1-Wire: Loading 1-Wire information ...
1-Wire: ROM Searching ... Done, 2 1-Wire chips found

1-Wire: BoardName | [Revid] | VendorName
#0 SAM9x5-EK [B0] FLEX
#1 SAM9G25-CM [B1] EMBEST

1-Wire: Board sn: 0x4000023 revision: 0x8401

NAND: ONFI flash detected
NAND: Manufacturer ID: 0x2c Chip ID: 0xda
NAND: Page Bytes: 2048, Spare Bytes: 64
NAND: ECC Correctability Bits: 4, ECC Sector Bytes: 512
NAND: Disable On-Die ECC
WARNING: ONFI requires 4-bit/512-byte ECC, but we use 2-bit/512-byte ECC.
NAND: Initialize PMECC params, cap: 2, sector: 512
NAND: Image: Copy 0xb0000 bytes from 0x40000 to 0x26f00000
NAND: Done to load image
No valid device tree binary found - please append one to U-Boot binary, use u-boot-dtb.bin or define CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>
initcall sequence 26f713f4 failed at call 26f66de4 (err=-1)
### ERROR ### Please RESET the board ###
I've got my git repo updated to the linux4sam_6.0 tag.

I flashed the board with

Code: Select all

board/atmel/flasher.sh output /dev/ttyACM0 at91sam9g25ek
which seemed to work fine.

I also tried using at91sam9x5ek_dev_defconfig with the same results.

I would expect a tagged release to work without needing lots of debugging work, so that suggests either I'm misconfiguring something or there's a serious problem with the testing process.

Anyone know what I'm doing wrong?

For reference, here's exactly what I'm doing to build and flash:

Code: Select all

$ make distclean
$ git checkout linux4sam_6.0
$ make at91sam9x5ek_defconfig
$ time make all
$ board/atmel/flasher.sh output/ /dev/ttyACM0 at91sam9g25ek
All of the above commands complete successfully.
nathan
Posts: 4
Joined: Mon Sep 25, 2017 7:18 pm

Re: linux4sam 6 not generating bootable image

Fri Nov 02, 2018 8:52 pm

Update: I tried updating to the linux4sam_5.8 release tag, and now I get this in a loop instead:
RomBOOT


AT91Bootstrap 3.8.9 (Fri Nov 2 14:43:28 EDT 2018)

1-Wire: Loading 1-Wire information ...
1-Wire: ROM Searching ... Done, 2 1-Wire chips found

1-Wire: BoardName | [Revid] | VendorName
#0 SAM9x5-EK [B0] FLEX
#1 SAM9G25-CM [B1] EMBEST

1-Wire: Board sn: 0x4000023 revision: 0x8401

NAND: ONFI flash detected
NAND: Manufacturer ID: 0x2c Chip ID: 0xda
NAND: Page Bytes: 2048, Spare Bytes: 64
NAND: ECC Correctability Bits: 4, ECC Sector Bytes: 512
NAND: Disable On-Die ECC
WARNING: ONFI requires 4-bit/512-byte ECC, but we use 2-bit/512-byte ECC.
NAND: Initialize PMECC params, cap: 2, sector: 512
NAND: Image: Copy 0xa0000 bytes from 0x40000 to 0x26f00000
NAND: Done to load image
<debug_uart> No serial driver found
resetting ...
blue_z
Location: USA
Posts: 1759
Joined: Thu Apr 19, 2007 10:15 pm

Re: linux4sam 6 not generating bootable image

Mon Nov 05, 2018 3:53 am

Suggest you perform a sanity test with a pre-built demo.
If you still cannot boot, then you may have a HW issue.

Regards
nathan
Posts: 4
Joined: Mon Sep 25, 2017 7:18 pm

Re: linux4sam 6 not generating bootable image

Wed Nov 07, 2018 9:15 pm

I tried flashing the pre-built yocto nand flash demo at linux4sam/bin/view/Linux4SAM/AT91sam9x5ekMainPage#Demo and couldn't get sam-ba to work. However, I found a copy of the buildroot repo from https://github.com/buildroot/buildroot that had previously been used with my kit and revision 84eee43369a1afae6905f4a8f2c2b0afc23098f0 boots up fine.

Looks like there's a regression somewhere.
Last edited by nathan on Fri Nov 09, 2018 7:17 pm, edited 2 times in total.
blue_z
Location: USA
Posts: 1759
Joined: Thu Apr 19, 2007 10:15 pm

Re: linux4sam 6 not generating bootable image

Fri Nov 09, 2018 12:44 am

nathan wrote: I tried flashing the pre-built yocto nand flash demo ... and couldn't get sam-ba to work.
However, I found a copy of the buildroot repo ... boots up fine.
Your summations provoke more uncertainties than provide useful information.

nathan wrote: Looks like there's a regression somewhere.
No, that's hasty.
You have not proven that there is no HW issue.
By "HW issue" I'm including the concept of 100% compatiblity between Atmel EK boards and Linux4SAM demo software.

Why could you not get SAM-BA "to work"?
Did you check for any modifications to the kernel source code in this "copy of the buildroot repo" that you "found"? What kernel did it build?

What are the silkscreen marking on the NAND flash chip of your module?
FYI your reported ONFI ECC requirement (i.e. "4-bit/512-byte ECC") does not match (old) datasheets that I have for "Manufacturer ID: 0x2c Chip ID: 0xda", nor the boot log from this old post.

Code: Select all

AT91: Detected soc type: at91sam9x5                                             
AT91: Detected soc subtype: at91sam9g25                                         
 ...  
NAND device: Manufacturer ID: 0x2c, Chip ID: 0xda (Micron MT29F2G08AAD), page size: 2048, OOB size: 64                                                          
atmel_nand 40000000.nand: ONFI params, minimum required ECC: 1 bits in 512 bytes

What is the provenance of your SAM9G25-CM module?


Regards
nathan
Posts: 4
Joined: Mon Sep 25, 2017 7:18 pm

Re: linux4sam 6 not generating bootable image

Fri Nov 09, 2018 9:54 pm

I am very confident that there's nothing wrong with my development kit. It's unmodified and runs the buildroot 2017.05.2 release at github (Linux 4.4.26) just fine with no problems. The next release, 2017.08, fails to boot in the same way that the linux4sam buildroot does. Looks like it broke somewhere in there. I'm in the process of searching through the changes between those releases to find one that broke things, but it's made harder by the fact that 2017.05.2 is not a direct ancestor of 2017.08.

The SAM9G25-CM came with the AT91X5-EK.

sam-ba 3 gave me an error about being unable to load some applet, though as I recall it didn't say which. Since I could flash the board just fine with flasher.sh in my buildroot build, I decided something was wrong with sam-ba or my installation of it, and I'm not interested in debugging it.

The NAND says "29f2g08abaea" on it, along with "1327" above a Micron logo, "WP" under it, and PHT8 in a corner. That makes me think it's this Micron 2Gb part.

I'm not sure why an incompatibility between the Atmel EK boards and the Linux4SAM demo software would be a hardware issue. If the software's not compatible with the hardware it's designed to run on, it's misconfigured. If buildroot generates an image that runs correctly on the board, then changes and no longer does that, it's regressed.

Return to “SAM9-based”

Who is online

Users browsing this forum: No registered users and 1 guest