From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from ems.wolfvision.net ([194.208.11.114]) by casper.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1SC5w0-0001KV-Fa for barebox@lists.infradead.org; Mon, 26 Mar 2012 09:09:54 +0000 From: Matthias Fend Date: Mon, 26 Mar 2012 11:09:40 +0200 Message-ID: <0769D45835157F4282BC17DF611B07F00D1ED6910B@wolfserver9> References: In-Reply-To: Content-Language: de-DE Content-Type: multipart/mixed; boundary="_003_0769D45835157F4282BC17DF611B07F00D1ED6910Bwolfserver9_" MIME-Version: 1.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: barebox-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: AW: imx53 internal boot from NAND To: "guenter.gebhardt@rafi.de" , "barebox@lists.infradead.org" --_003_0769D45835157F4282BC17DF611B07F00D1ED6910Bwolfserver9_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi, For a quick start you can use the provided FCB (fcb.bin). This FCB was generated with the attached tool (fcbgen.c) - note that the ba= d block handling is disabled. Then you can "merge" your barebox image with the FCB with something like: cat fcb.bin barebox-image > barebox-fcb.bin This works at least on our custom i.MX53 hardware. ~Matthias Von: barebox-bounces@lists.infradead.org [mailto:barebox-bounces@lists.infr= adead.org] Im Auftrag von guenter.gebhardt@rafi.de Gesendet: Montag, 26. M=E4rz 2012 10:48 An: barebox@lists.infradead.org Betreff: imx53 internal boot from NAND Hello,=20 I tried to use barebox in order to boot from NAND.=20 The ROM loader needs a FCB (Firmware Configuration Block) table at the begi= nning of the flash (according to chapter 7.5.2.2 of the reference manual).= =20 I looked at the existing imx53 boards within the barebox sources but I foun= x that no one used this mode there.=20 Has someone done this or can give me some advice?=20 -- Gebhardt --_003_0769D45835157F4282BC17DF611B07F00D1ED6910Bwolfserver9_ Content-Type: text/plain; name="fcbgen.c" Content-Description: fcbgen.c Content-Disposition: attachment; filename="fcbgen.c"; size=1875; creation-date="Mon, 26 Mar 2012 09:03:30 GMT"; modification-date="Mon, 26 Mar 2012 09:03:30 GMT" Content-Transfer-Encoding: base64 LyoKICogZ2VuZXJhdGUgZmlybXdhcmUgY29udHJvbCBibG9jayAoRkNCKSAtIHJlcXVpcmVkIHRv IGJvb3QgaU1YNTMgZnJvbSBOQU5ECiAqCiAqIG9ubHkgd29ya3MgZm9yIDJrIHBhZ2UgTkFORHMK ICogYmFkIGJsb2NrIGhhbmRsaW5nIG9mIFJPTSBib290bG9hZGVyIGlzIGRpc2FibGVkCiAqCiAq IGZjYiBsZW5ndGggaXMgNGtCICgyIHBhZ2VzKQogKiBpbWFnZSBzdGFydCBhdCBwYWdlIDIKICov CiNpbmNsdWRlIDxzdGRpby5oPgojaW5jbHVkZSA8c3RkbGliLmg+CiNpbmNsdWRlIDxzdHJpbmcu aD4KI2luY2x1ZGUgPHN0ZGludC5oPgoKc3RydWN0IGZjYl9lbnRyeQp7CiAgdWludDMyX3QgYWRk cjsKICB1aW50MzJfdCB2YWx1ZTsKfTsKCnN0cnVjdCBmY2JfZW50cnkgZmNiX2VudHJpZXNbXSA9 CnsKICB7IDB4MDAsIDB4MDAwMDAwMDAgfSwgLy8gcmVzLgogIHsgMHgwNCwgMHg0NjQzNDIyMCB9 LCAvLyBmaW5nZXJwcmludCAjMiAoYXNjaWkgRkNCKQogIHsgMHgwOCwgMHgwMTAwMDAwMCB9LCAv LyBmaW5nZXJwcmludCAjMyAodmVyc2lvbikKICB7IDB4NjgsIDB4MDIwMDAwMDAgfSwgLy8gcHJp bWFyeSBpbWFnZSBzdGFydCBwYWdlIChwYWdlIDIpCiAgeyAweDZDLCAweDAyMDAwMDAwIH0sIC8v IHNlY29uZGFyeSBpbWFnZSBzdGFydCBwYWdlIChwYWdlIDIpCiAgeyAweDc4LCAweDAwMDAwMDAw IH0sIC8vIFN0YXJ0IHBhZ2UgYWRkcmVzcyBvZiBEQkJ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VzW2ldLmFk ZHIgKyAzXSA9IGZjYl9lbnRyaWVzW2ldLnZhbHVlID4+IDA7CiAgfQoKICBpZigoZnAgPSBmb3Bl bihmbmFtZSwgInciKSkgPT0gTlVMTCkKICB7CiAgICBwcmludGYoImNvdWxkIG5vdCBvcGVuICVz IVxuIiwgZm5hbWUpOwogICAgcmV0dXJuIC0xOwogIH0KCiAgcmV0ID0gZndyaXRlKGZjYmltYWdl LCAxLCBzaXplb2YoZmNiaW1hZ2UpLCBmcCk7CiAgcHJpbnRmKCJ3cm90ZSAlZCBieXRlcy5cbiIs IHJldCk7CiAgaWYocmV0ICE9IHNpemVvZihmY2JpbWFnZSkpCiAgICBwcmludGYoImVycm9yIC0g aW5jb21wbGV0ZSBmaWxlIVxuIik7CiAgZmNsb3NlKGZwKTsKCiAgcmV0dXJuIDA7Cn0K --_003_0769D45835157F4282BC17DF611B07F00D1ED6910Bwolfserver9_ Content-Type: application/octet-stream; name="fcb.bin" Content-Description: fcb.bin Content-Disposition: attachment; filename="fcb.bin"; size=4096; creation-date="Mon, 26 Mar 2012 09:03:30 GMT"; modification-date="Mon, 26 Mar 2012 09:03:30 GMT" Content-Transfer-Encoding: base64 AAAAAEZDQiABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAAAAgAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox --_003_0769D45835157F4282BC17DF611B07F00D1ED6910Bwolfserver9_--