modify mfgtool for ddr cal

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

modify mfgtool for ddr cal

692 Views
dluberger
Contributor V

i'm running the i.mx6ul on a custom board.

1.) I've run the ddr stress test gui to get new calibration values.  the read and write cal values are stable, but the dqs gating keeps changing between two fairly different values, but always the same ones (0x41540150 and 0x4158004e). every time i update the .inc script the result gives me the other dqs value. i'm not sure if it matters or indicates something is wrong, but the read and write cal values are rock solid after the first cal update.

2.) i'm told that i should not be building and loading u-boot, dtb, kernel, and rootfs directly from my linux host using the dd command (e.g., sudo dd if=u-boot.imx of=/dev/sdb bs=1k seek=1 conv=fsync) but that i should always use the mfg tool. i'm also told, however, that i can't use the mfg tool as downloaded from the processor product page because it was pre-built for the eval boards, and has to be modified for a custom board, with it's own u-boot updated for the new ddr cal values.furthermore, i'm told that i really should be using yocto to do all my builds, not just the mfgtool. the problem is that -- and i have to gripe a bit -- the yocto project stuff is incredibly convoluted and confusing to me.  doing direct builds with the make command is fairly straightforward; all i have to do is modify the <my-board>.c file for u-boot, the device tree dts file for the kernel, maybe some other tweaks, run the make my-board-defconfig and make commands for u-boot and kernel and i'm off and running; it's super easy.  but the yocto project stuff is really really hard to follow and understand. all i see are recipes but no c files, no dts files, no rootfs files. and there are no clear instructions that point me to the files i need to modify to customize my builds.  i've looked at the bsp porting guide and it only talks about copying and modifying conf files, it doesn't say anything about how to find and modify the c files and dts files like i do with direct building as above.  how do i customize u-boot? how do i customize my device tree?? i can't figure out how to do any of the stuff i did simply using the make command and modified board files.  i've already looked through the yocto user guide, the linux user guide, all docs, and nothing that tells me step by step how use yocto to do the same stuff i'm doing building the 4 pieces directly.  and to make matters worse, doing the direct builds took minutes, but i did one yocto build for the imx6ul-14x14-evk board and xwayland distro and it literally took all night! i don't have time to build with yocto if it takes hours on end to build.

please help!

Labels (4)
0 Kudos
2 Replies

502 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello David Luberger,

The Yocto project may indeed look a bit convoluted because it’s not meant as a development tool but rather as a mean to distribute custom Linux distributions. This is why you mostly see what is refered to as “meta data” on the Yocto recipes and not the actual source code.

The source code is referenced on the Yocto recipes and then fetch on demand as required. You can look at the fetched sources on the temp/work directory inside your build directory. For example, for the Kernel in:

<BSP_DIR>/<BUILD_DIR>/tmp/work/<MACHINE>-poky-linux-gnueabi/linux-imx/<KERNEL_VER>/git

There is an example of how to make some changes on the kernel configuration on the link below:

https://community.nxp.com/docs/DOC-334088

Yocto is not meant for development so it does not track changes on the source files. You could clone the git repositories (links below) for the kernel and u-boot and work directly there and once you are done making changes create a recipe that patches the bootloader and kernel.

U-boot
http://git.freescale.com/git/cgit.cgi/imx/uboot-imx.git/

https://source.codeaurora.org/external/imx/uboot-imx/

 

Kernel
http://git.freescale.com/git/cgit.cgi/imx/linux-imx.git/

https://source.codeaurora.org/external/imx/linux-imx/

I hope this helps!

Regards,

0 Kudos

502 Views
dluberger
Contributor V

Thanks for the info. I was told (by Igor, I think) that I should be building with Yocto and not directly from the sources. I was having problems at the time with mfgtool but I've since gone to solely writing to the SD card directly from my linux host environment. It's a bit of a pain but it works.

That said, I've managed to fully bring up my board by compiling the u-boot, device tree, and kernel, and simply copying a suitable rootfs/OS into the rootfs partition.  At this point, with everything coming up, I'm just having to tweak my device tree and run "make dtbs" to get a new dtb file.  Eventually my plan is, once I get a working system, our final product will just use clone copies of this SD card.

One question I do have is: how/where do I get a suitable operating system/file system.  There seem to be a lot but not many that seem to be good for my setup, which is a matrix-scan keypad, a 5" 800x480 parallel LCD with touchscreen.  I tried linaro debian jessie but that just seems to big for the amount of memory i'm using. I compiled the imx validation image in yocto and there's nothing that tells me how to use it and all I get is an empty desktop with no icons to press.  Is there somewhere I can download the OS/rootfs that comes with the imx6ull eval board sd card? I no longer have that sd card.

Thanks.

0 Kudos