[i.mx8mn] Applying kernel changes I modifed

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

[i.mx8mn] Applying kernel changes I modifed

Jump to solution
1,587 Views
bryan_hong
Senior Contributor I

dear nxp

When I modifed setup.c on `tmp/work-shared/imx8mn-lpddr4-evk/kernel-sourcearch/arm64/kernel/setup.c` as below.

pr_info("BBBooting Linux on physical CPU 0x%010lx [0x%08x]\n",
 (unsigned long)mpidr, read_cpuid_id());

then, I have executed below command.

$ bitbake -c compile -f linux-imx && bitbake -c deploy linux-imx

$ bitbake core-image-base

 

then I have flash the image as below.

tmp\deploy\images\imx8mn-lpddr4-evk> uuu -b emmc_all imx-boot-imx8mn-lpddr4-evk-sd.bin-flash_evk imx-image-core-imx8mn-lpddr4-evk.wic.zst

 

BUT, It still present not `BBBooting ` but `Booting`.

Starting kernel ...

[ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
[ 0.000000] Linux version 6.1.36+g04b05c5527e9 (oe-user@oe-host) (aarch64-poky-linux-gcc (GCC) 12.3.0, GNU ld (GNU Binutils) 2.40.0.20230620) #1 SMP PREEMPT Mon Sep 4 21:11:15 UTC 2023

How to apply changes in setup.c to the kernel.

Thanks,
Bryan

Tags (1)
0 Kudos
Reply
1 Solution
1,030 Views
bryan_hong
Senior Contributor I

dear Zhiming

I have checked the boot using kernel I modifed with below command on uboot mode.

setenv ipaddr 192.168.1.162

setenv serverip 192.168.1.143

tftpboot ${loadaddr} Image

tftpboot ${fdt_addr_r} imx8mn-evk-imx8mn-lpddr4-evk.dtb

booti ${loadaddr} - ${fdt_addr_r}

 

Thanks for your support. 

View solution in original post

Tags (1)
0 Kudos
Reply
5 Replies
1,467 Views
bryan_hong
Senior Contributor I

dear  Zhiming_Liu

I'm looking for the way to flash kernel image to the i.mx8mn EVK without toggling dip switch download mode(SW1101).

Alike `fastboot flash boot boot.img` on android.

Thanks,
Bryan

0 Kudos
Reply
1,440 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @bryan_hong 

You can run fastboot usb 0 in uboot, try to use fastboot to flash.

platform-tools> .\fastboot.exe getvar version-bootloader
version-bootloader: U-Boot 2025.04-g44898b9f3cfe
Finished. Total time: 0.005s

u-boot/doc/android/fastboot.rst at master · u-boot/u-boot



Best Regards,
Zhiming

0 Kudos
Reply
1,031 Views
bryan_hong
Senior Contributor I

dear Zhiming

I have checked the boot using kernel I modifed with below command on uboot mode.

setenv ipaddr 192.168.1.162

setenv serverip 192.168.1.143

tftpboot ${loadaddr} Image

tftpboot ${fdt_addr_r} imx8mn-evk-imx8mn-lpddr4-evk.dtb

booti ${loadaddr} - ${fdt_addr_r}

 

Thanks for your support. 

Tags (1)
0 Kudos
Reply
1,132 Views
bryan_hong
Senior Contributor I

dear Zhiming

As you know, ADB, fastboot did not work because I use linux OS.

Thanks,
Bryan

0 Kudos
Reply
1,558 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @bryan_hong 

Please use 'devtool modify linux-imx' to unpack linux-imx into build-xxx/workspace/source/, then recompile it.

Best Regards,
Zhiming

0 Kudos
Reply