u-boot-at91 icon indicating copy to clipboard operation
u-boot-at91 copied to clipboard

is it possible to boot this from an spi eeprom

Open hannescam opened this issue 2 years ago • 14 comments

hannescam avatar Dec 05 '22 06:12 hannescam

I think i's possible but usually eeproms are very small 1 kByte , 2 kBytes and it would be difficult to fit a bootloader there It's definitely possible to boot from an SPI flash which is a bit more generous in size

ehristev avatar Dec 05 '22 08:12 ehristev

no this one is a 8 mega byte flash so no such 2 kb constrains (i never saw any smaller that 512 kb) so i hope it will be developed for spi eeprom/flash

hannescam avatar Dec 05 '22 08:12 hannescam

do you have a link to this memory online ?

ehristev avatar Dec 05 '22 08:12 ehristev

yes: https://datasheetspdf.com/pdf-file/792368/Spansion/FL064P/1

hannescam avatar Dec 05 '22 08:12 hannescam

From my opinion it should work. I suggest you try , to make sure it works. If you want to place also the Stage2 bootloader (boot.bin) make sure the ROM code is correctly configured to try booting from SPI with the correct IOset and boot config

ehristev avatar Dec 05 '22 08:12 ehristev

so if undertand it right you mean just try to flash it and if it works try to configure it else retry right

hannescam avatar Dec 05 '22 08:12 hannescam

I suggest so. Get one flash and use fly wires to connect it . Do not create a custom board unless you are sure it works in a proof of concept first.

ehristev avatar Dec 05 '22 09:12 ehristev

ok and i will flash the eeprom with an cha341 and the flashrom software and i dont design a board it is because i have about 5 xprintserver boards and i get more and i want use them

hannescam avatar Dec 05 '22 09:12 hannescam

i cant find any documentation how to build this for the at91sam9g25 under linux

hannescam avatar Dec 05 '22 13:12 hannescam

@ehristev can you help me compile the uboot for the at91sam9g25 chip under linux debian/arch

hannescam avatar Dec 13 '22 16:12 hannescam

@hannescam sam9g25 chip is part of the sam9x5 series. You can build U-boot for the sam9x5 series EK board, this is a board where you can insert a different module, in your case 9g25, it also supports 9x35, etc. So it should work for your chip as well. If you do not have the EK board I do not believe we support another board with this chip. The config files in Uboot for the sam9x5 series EK are as folllows:

at91sam9x5ek_dataflash_defconfig
at91sam9x5ek_mmc_defconfig
at91sam9x5ek_nandflash_defconfig
at91sam9x5ek_spiflash_defconfig

To build them, follow the general Uboot building procedure as for any other board as per Uboot documentation.

Hope this helps.

ehristev avatar Dec 21 '22 13:12 ehristev

ok i will try it but i dont have the ek board but i think my board is similar egnuth that it could work

hannescam avatar Dec 22 '22 06:12 hannescam

i tried to built it but it says "cc1: Fehler: falscher Wert »armv5te« für Schalter »-march=«" it means "cc1: error: wrong value »armv5te« for switch »-march=«" and a screenshot: image and i did type the command "make at91sam9x5ek_spiflash_defconfig" in before running make and the output of it:

[hannes@Hannes-VAIO u-boot-at91]$ make at91sam9x5ek_spiflash_defconfig
#
# configuration written to .config
#

hannescam avatar Dec 23 '22 16:12 hannescam

i compiled it using a arm sbc and the make option: "CROSS_COMPILE=arm-linux-gnueabi-" and i will flash u-boot.bin to the spi flash chip

hannescam avatar Dec 26 '22 07:12 hannescam