<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><div>Hi,<br><br>I'm trying to set up the UPM RAM table for NAND access.<br>Here is how I do it:<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; char __iomem *lbc_addr;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; int i;<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; lbc_addr = ioremap(0xa0000000, 0x10);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* NAND chip (256MB) will be driven by UPM-A at LBC address 0xa0000000 */<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; out_be32(&amp;fsl_lbc_regs-&gt;bank[4].br, 0xa0000881);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; out_be32(&amp;fsl_lbc_regs-&gt;bank[4].or, 0xf0000001);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* setup MAMR for sequential write to UPM-A RAM */<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 out_be32(&amp;fsl_lbc_regs-&gt;mamr, 0x10000000);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for (i = 0; i &lt; 64; i++) {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; out_be32(&amp;fsl_lbc_regs-&gt;mdr, UPMATable[i]);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; out_8(lbc_addr, 0);&nbsp;&nbsp; /* dummy write, byte wide */<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* restore MAMR */<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; out_be32(&amp;fsl_lbc_regs-&gt;mamr, 0x00000000);<br><br>But this does not seem to be working. I have verified this in two ways<br><br>a) for each write to mdr in the for loop above, I read back mamr and print it. This should have an incrementing<br>MAD value, but it does not<br><br>b) I read back the data that I had stored in UPM-A RAM and that logic does not work
 either.<br><br>My take is that out_8(lbc_addr, 0) is not working because I'm not mapping lbc_addr correctly.<br>Can someone tell me what I'm doing wrong?<br><br>thanks for your help<br>LK<br><br></div></div><br>



      </body></html>