I have imx8mm evk
I am using this u-boot.
git clone https://github.com/nxp-imx/uboot-imx
I installed aarch64-linux-gnu- /usr/bin (ubuntu 22.04),
and I also have the aarch64--glibc--stable-2022.08-1 (I tried both compilers)
I am building like this.
COMPILER=aarch64-linux-gnu- # from apt
##COMPILER=aarch64-linux-
export PATH=/path/to/tc/bin:$PATH
ARCH=arm CROSS_COMPILE=$COMPILER make imx8mm_evk_defconfig
ARCH=arm CROSS_COMPILE=COMPILER make clean
ARCH=arm CROSS_COMPILE=COMPILER make
after building I have these files
find -name '*.bin' -o -name '*.img'
./u-boot-dtb.img
./u-boot-nodtb.bin
./spl/u-boot-spl-nodtb.bin
./spl/u-boot-spl.bin
./tools/binman/test/descriptor.bin
./u-boot-dtb.bin
./u-boot.img
./u-boot.bin
I tried to dd the u-boot and/or spl as all kinds of combinations I've could find in scripts.
sudo dd if=./u-boot-*.bin<img> of=/dev/mmcblk0 bs=1k seek=XX=33/69
What is the right dd command and what u-boot files and what seek (ofsets) are correct ones for IMX8MM
sdcard and emmc?
I also tried all these
$ sudo dd if=<U-Boot image> of=/dev/sdx bs=1k seek=<offset> conv=fsync
Where offset is:
• 1 - for i.MX 6 or i.MX 7
• 33 - for i.MX 8QuadMax A0, i.MX 8QuadXPlus A0, and i.MX 8M Quad, and i.MX 8M Mini
• 32 - for i.MX 8QuadXPlus B0, i.MX 8QuadMax B0, i.MX 8DualX, i.MX 8DXL, i.MX 8M Nano, i.MX 8M Plus,
i.MX 8ULP, and i.MX 9
Thank you
Solved! Go to Solution.
Thank you,
I skipped the yocto thing. I will try with yocto, as looks like there is no escape from it.
I will reply as soon I get some positive results.
I'd suggest you refer to the <4.5.12 How to build U-Boot and Kernel in standalone environment> and <4.5.13 How to build imx-boot image by using imx-mkimage> of i.MX Linux User's Guide (nxp.com)
Best regards
Harvey
Thank you,
I skipped the yocto thing. I will try with yocto, as looks like there is no escape from it.
I will reply as soon I get some positive results.
make distclean
make imx8mm_evk_defconfig
make
...
cc1: warning: unknown register name: x18
cc1: error: bad value (‘armv8-a+crc’) for ‘-march=’ switch
and for arch64 with latest bootlin 2022 compiler
export PATH=/opt/tc/aarch64--glibc--stable-2022.08-1/bin:${PATH}
ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- && make distclean
ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- && make imx8mm_evk_defconfig
ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- && make
CLEAN spl/u-boot.cfg
CLEAN include/generated/env.in u-boot.cfg
CLEAN scripts/basic
CLEAN scripts/kconfig
CLEAN include/config include/generated spl
CLEAN .config .config.old include/autoconf.mk include/autoconf.mk.dep include/config.h
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
YACC scripts/kconfig/zconf.tab.c
LEX scripts/kconfig/zconf.lex.c
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
#
# configuration written to .config
#
scripts/kconfig/conf --syncconfig Kconfig
UPD include/config.h
CFG u-boot.cfg
cc1: warning: unknown register name: x18
GEN include/autoconf.mk
GEN include/autoconf.mk.dep
cc1: warning: unknown register name: x18
CFG spl/u-boot.cfg
cc1: warning: unknown register name: x18
GEN spl/include/autoconf.mk
UPD include/config/uboot.release
UPD include/generated/version_autogenerated.h
UPD include/generated/timestamp_autogenerated.h
UPD include/generated/dt.h
ENVC include/generated/env.txt
ENVP include/generated/env.in
ENVT include/generated/environment.h
CC lib/asm-offsets.s
cc1: warning: unknown register name: x18
cc1: error: bad value (‘armv8-a+crc’) for ‘-march=’ switch
cc1: note: valid arguments to ‘-march=’ switch are: nocona core2 nehalem corei7 westmere sandybridge corei7-avx ivybridge core-avx-i haswell core-avx2 broadwell skylake skylake-avx512 cannonlake icelake-client icelake-server cascadelake tigerlake bonnell atom silvermont slm goldmont goldmont-plus tremont knl knm x86-64 eden-x2 nano nano-1000 nano-2000 nano-3000 nano-x2 eden-x4 nano-x4 k8 k8-sse3 opteron opteron-sse3 athlon64 athlon64-sse3 athlon-fx amdfam10 barcelona bdver1 bdver2 bdver3 bdver4 znver1 znver2 btver1 btver2 native
make[1]: *** [scripts/Makefile.build:143: lib/asm-offsets.s] Error 1
make: *** [Makefile:1954: prepare0] Error 2
/sdaone/PEG_PROJ/Kohler_wc/ICP_u_boot
I found that I need the imx-atf as well.
I cloned this:
https://github.com/nxp-imx/imx-atf
I Have gcc/c++ 9..to 11
git checkout imx_4.9.123_imx8mm_ga
ARCH=arm64 CROSS_COMPILE=aarch64-linux- && make PLAT=imx8mm CFG_ARM64_core=y
I tried all of them and I cannot pass
gcc: error: unrecognized command line option ‘-mstrict-align’; did you mean ‘-Wstrict-aliasing’?
gcc: error: unrecognized command line option ‘-mfix-cortex-a53-835769’
I tried to comment those then The errors goes deeper.
cc1: error: bad value (‘armv8-a’) for ‘-march=’ switch
Any help would be appreciated
RESOLVED WITH:
https://github.com/varigit/imx-atf.git
7575633e03ff952a18c0a2c0aa543dee793fda5f
https://github.com/nxp-imx/imx-mkimage.git
6745ccdcf15384891639b7ced3aa6ce938682365
https://github.com/varigit/uboot-imx.git
9458fd59dd6d69230438350c3aeb8ac803ff1b1c
and
aarch64--glibc--stable-2022.08-1