From mboxrd@z Thu Jan 1 00:00:00 1970 From: Timo Ketola Date: Thu, 12 Apr 2012 14:21:56 +0300 Subject: [U-Boot] [PATCH 2/8] i.MX: Add target flashable to offset 0 In-Reply-To: <4F86B87D.9000206@denx.de> References: <1334223234-23383-1-git-send-email-timo@exertus.fi> <1334223234-23383-3-git-send-email-timo@exertus.fi> <4F86B87D.9000206@denx.de> Message-ID: <4F86BAD4.40709@exertus.fi> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 12.04.2012 14:11, Stefano Babic wrote: > On 12/04/2012 11:33, Timo Ketola wrote: >> +$(obj)u-boot-nand.imx: $(obj)u-boot.imx >> + dd if=$< of=$@ seek=2 >> + > > I wonder why we need this in u-boot code and to set this rule in the > main Makefile. You can always do this after generating u-boot. Older U-Boot (from FreeScale) made an .imx image with 1KB padding which I could flash directly into the NAND at offset 0. Now I had to do manually that dd-magic (before I put it in Makefile) because openocd doesn't allow to flash at offset 0x400 (it demands write-page alignment). > The rules here are to generate the u-boot.imx. Then the same image can > be stored at different addresses. Depending on the i.MX SOC, ofssets can > be different (MX5 / MX6 have different offsets for NOR / NAND / oneNAND). I prefer a build system which generates an image ready for flashing but perhaps I have to do that outside of U-Boot, somehow. -- Timo