<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;"><span>Thanks</span> for info!<br>Ok I have to modify some things, but anyway:<br>1- dts is an old version (I know that and this isn't a problem because kernel is an old version too 2.6.x)<br>2- The main mistake is that I'm tring to use the NAND flash, but the DTS node that i've modified refers to NOR flash.<br><br>So i think that I must modify the following part of code:<br><br> nfc@40000000 {<br> compatible = "fsl,mpc5121rev2-nfc";<br> reg = <40000000 100000>; // 1M at 0x40000000<br> interrupts = <6 8>;<br> interrupt-parent = < &ipic >;<br> #address-cells = <1>;<br> #size-cells =
<1>;<br> bank-width = <1>;<br> write-size = <800>;<br> spare-size = <40>;<br> // ADS has two Hynix 512MB Nand flash chips in a single<br> // stacked package .<br> chips = <2>;<br> // UBIFS works fine on large partitions so use all of it<br> nand@0 {<br> label = "nand";<br> reg = <00000000 40000000>; // Entire 1G (512M + 512M)<br> };<br> // JFFS2 really doesn't do large partitions well use UBIFS instead<br>
//nand0@0 {<br> // label = "nand0";<br> // reg = <00000000 02000000>; // first 32 MB of chip 0<br> //};<br> //nand1@20000000 {<br> // label = "nand1";<br> // reg = <20000000 02000000>; // first 32 MB of chip 1<br> //};<br> };<br><br>This part of device tree concern nand flash controller od ads5121ev board.<br>In your opinion kernel obtains all flash info from device tree? or I must modify some part of kernel code?<br>It seems like that nand flash controller could mangae two banks of nand flash:<br><br>// JFFS2 really doesn't do large
partitions well use UBIFS instead<br>//nand0@0 {<br>// label = "nand0";<br>// reg = <00000000 02000000>; // first 32 MB of chip 0<br> //};<br> //nand1@20000000 {<br> // label = "nand1";<br> // reg = <20000000 02000000>; // first 32 MB of chip 1<br> //};<br><br>What do you think? It could could be an hard work!?<br><br>Thanks in advance<br>@s<br><br>--- <b>Mar 8/9/09, Angelo <i><s104259@yahoo.it></i></b> ha scritto:<br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><br>Da: Angelo <s104259@yahoo.it><br>Oggetto: Question on flash node on device tree source<br>A: devicetree-discuss@ozlabs.org<br>Data: Marted́ 8 settembre 2009, 14:18<br><br><div id="yiv1145874053"><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td style="font-family: inherit; font-style:
inherit; font-variant: inherit; font-weight: inherit; font-size: inherit; line-height: inherit; font-size-adjust: inherit; font-stretch: inherit;" valign="top">Hi all.<br><br>I need some info about device tree blob.<br>I'm testing a powerpc board (very similar to mpc512xev) with the following feature:<br> - 256MB flash (only 1 bank)<br><br>Changes some lines of device tree source about flash<br><br>localbus@80000020 {<br> compatible = "fsl,mpc5121ads-localbus";<br> #address-cells = <2>;<br> #size-cells = <1>;<br> reg = <0000020 40>;<br><br> ranges = <0 0 fc000000 04000000<br> 2 0 82000000 00008000>;<br><br> flash@0,0 {<br>
device_type =
"rom";<br> compatible = "direct-mapped";<br> probe-type = "CFI";<br> reg = <0 0 4000000>;<br> #address-cells = <1>;<br> #size-cells = <1>;<br> bank-width = <4>;<br> device-width = <2>;<br> partitions = <00000000 00040000 // first sector is protected<br> 00040000 03c00000 // 60 Mb for
filesystem<br> 03c40000 00280000 // 2.5 Mb for kernel<br> 03ec0000 00040000 // one sector for device tree<br> 03f00000 00100000>; // one Mb for u-boot<br> partition-names = "protected", "filesystem", "kernel", "device-tree", "u-boot";<br> };<br>....<br>with these changes:<br>....<br> flash@0,0 {<br> device_type = "rom";<br>
compatible = "direct-mapped";<br> probe-type = "CFI";<br> reg = <0 0 1000000>;<br> #address-cells = <1>;<br> #size-cells = <1>;<br> bank-width = <1>;<br> device-width = <1>;<br> partitions = <300000 200000 //uimage<br> 400000 3200000>; // fs<br> partition-names = "uimage",
"fs";<br> };<br>....<br><br>The problem is that on bootstrap stage, kernel truncate the flash memory to 16MB, so i cannot access to the whole flash. kernel messages:<br><br>mtd: partition "fs" extends beyond the end of device "60000000.flash" size truncated to 0xc00000.<br><br>I'd like to know if i have to specify into the dtb file the size of flash mem. What about nand flash controller and its functionality? <br>If you have more info about this, please write to me.<br><br>Thanks in advance,<br>@s<br><br></td></tr></tbody></table><br>
</div></blockquote></td></tr></table><br>