hello everyone:)<br>&nbsp;&nbsp;&nbsp; i am learning the u-boot-1.1.3 .<br>&nbsp;&nbsp;&nbsp; i got a question about copying the vector to the ram,the following is the piece of code.<br>the path :u-boot/u-boot-1.1.3/cpu/s3c44b0/start.s<br><br>****************************************************************<br>/*<br>&nbsp;&nbsp;&nbsp; now copy to sram the interrupt vector<br>*/<br>&nbsp;&nbsp;&nbsp; adr&nbsp;&nbsp;&nbsp; r0, real_vectors<br>&nbsp;&nbsp;&nbsp; add&nbsp;&nbsp;&nbsp; r2, r0, #1024<br>&nbsp;&nbsp;&nbsp; ldr&nbsp;&nbsp;&nbsp; r1, =0x0c000000<br>&nbsp;&nbsp;&nbsp; add&nbsp;&nbsp;&nbsp; r1, r1, #0x08<br>vector_copy_loop:<br>&nbsp;&nbsp;&nbsp; ldmia&nbsp;&nbsp;&nbsp; r0!, {r3-r10}<br>&nbsp;&nbsp;&nbsp; stmia&nbsp;&nbsp;&nbsp; r1!, {r3-r10}<br>&nbsp;&nbsp;&nbsp; cmp&nbsp;&nbsp;&nbsp; r0, r2<br>&nbsp;&nbsp;&nbsp; ble&nbsp;&nbsp;&nbsp; vector_copy_loop<br>*****************************************************************<br><br>a) "add r2,r0,#1024"<br>&nbsp;&nbsp;&nbsp; is the real_vectors size 1024 byte? how and where to define it?<br><br>b) what will happend if there is not the command "add r1,r1,#0x08"? the first ASM command of real_vectors in the ram begin from 0x0c000000 or 0x0c000008? i think it should be at the 0x0c000000,but it looks the 0x0c000008 is correct...so i lost :(<br><br>thanks all of you:)<br><br><!-- footer --><br><hr>
<a style="font-size:14px;line-height:15px; color:#000; text-decoration:none" href="http://event.mail.163.com/chanel/click.htm?from=NO_23&domain=163" target="_blank"><span style="text-decoration:underline; color:blue">网 易 股 吧, 每 天 有 500 万 股 民 在 此 讨 论 >></span> </a>