
I tried to follow your suggestion, but so far I have been unsuccessful.
I cloned Linus' latest source code, and then did:
make ARCH=arm mxs_defconfig make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- cat arch/arm/boot/zImage ./arch/arm/boot/dts/imx28-evk.dtb > arch/arm/boot/zImage_with_dtb cd arch/arm/boot mkimage -T kernel -A arm -O linux -a 0x40008000 -e 0x40008000 -C none -d ./zImage_with_dtb uImage_with_dtb
then copied onto the Wink hub and did:
flash_erase /dev/mtd4 0 0 nandwrite -p -m /dev/mtd4 uImage_with_dtb reboot
I then interrupted u-boot, and had to update the number of bytes read from the mtd4 partition (was 0x00400000, now 0x00600000), as the new kernel was about 4 times larger than the vendor kernel, and I was getting checksum errors due to only partial read of the image.
setenv app_boot 'run appboot_args && nand read ${loadaddr} app-kernel 0x00600000 && bootm ${loadaddr}' run app_boot
NAND read: device 0 offset 0x2b00000, size 0x600000 6291456 bytes read: OK ## Booting kernel from Legacy Image at 42000000 ... Image Name: Created: 2023-06-22 21:37:11 UTC Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 6279041 Bytes = 6 MiB Load Address: 40008000 Entry Point: 40008000 Verifying Checksum ... OK Loading Kernel Image ... OK
Starting kernel ...
And it stopped there after dumping some garbage to the screen.
I did note that the mxs_defconfig did not define the appended DTB config, so I updated my .config as follows:
$ grep DTB .config CONFIG_ARM_APPENDED_DTB=y CONFIG_ARM_ATAG_DTB_COMPAT=y CONFIG_ARM_ATAG_DTB_COMPAT_CMDLINE_FROM_BOOTLOADER=y # CONFIG_ARM_ATAG_DTB_COMPAT_CMDLINE_EXTEND is not set
And rebuilt as above, with no change.
Am I doing something obviously wrong?
Thanks
Rogan
On Sat, 17 Jun 2023 at 16:28, Rogan Dawes rogan@dawes.za.net wrote:
Thank you so much for the response! It is much appreciated!
I do hope to get JTAG working on the Hub v1, and then will be able to try to build a modern U-Boot which I can flash.
Regards,
Rogan
On Thu, 15 Jun 2023 at 22:01, Fabio Estevam festevam@gmail.com wrote:
Hi Rogan,
On Thu, Jun 15, 2023 at 9:00 AM Rogan Dawes rogan@dawes.za.net wrote:
Hi folks,
I am trying to boot a custom kernel on a Wink Hub v1, which has an
i.MX28
CPU, and is running U-Boot (U-Boot 2014.01-14400-gda781c6-dirty (Apr 30 2014 - 22:35:38)).
I have tried compiling my own modern kernel and putting it in place of
the
vendor (Linux version 2.6.35.3-flex-dvt) kernel on the flash chip, but
when
loading, I simply get the expected U-Boot loading messages, but then nothing at all from the serial port after that.
I'm trying to figure out where my problem is most likely to be. As far
as I
am aware from long-ago poking at U-Boot, the way that U-Boot passes arguments to the kernel has changed recently? Previously it was ATAGS,
and
now it expects a Device Tree Blob? Might this explain the failure to
boot
that I am seeing? And yes, I understand that given that
Yes, to boot a modern kernel, you need to generate a devicetree for the Wink Hubv1 board.
Then you build it and generate a .dtb file.
To boot zImage + dtb using an old bootloader that does not support booting dtb, you would need to select the following options in the kernel:
CONFIG_ARM_APPENDED_DTB=y CONFIG_ARM_ATAG_DTB_COMPAT=y
And then:
cat arch/arm/boot/zImage arch/arm/boot/dts/imx28-wink-hub-v1.dtb > zImage_with_dtb
And then boot zImage_with_dtb as you do with 2.6.35.
Ideally, you should also port a modern U-Boot version, which supports dtb by default and then you don't need the steps above.
Take a look at board/freescale/mx28eevk support for a reference.
Regards,
Fabio Estevam