<html><body><div><br></div><div><br>On Aug 03, 2015, at 08:34 AM, QIAO YANG <yangqiao0505@me.com> wrote:<br><br><div><blockquote type="cite"><div class="msg-quote"><div>On Jul 29, 2015, at 02:03 PM, Chris Johns <<a href="mailto:chrisj@rtems.org" data-mce-href="mailto:chrisj@rtems.org">chrisj@rtems.org</a>> wrote:<br><br><div><blockquote type="cite"><div class="msg-quote"><div class="_stretch"><span class="body-text-content"><span class="body-text-content">On 29/07/2015 8:04 pm, Sebastian Huber wrote:<br></span></span><blockquote class="quoted-plain-text" type="cite"><br></blockquote><blockquote class="quoted-plain-text" type="cite">A custom workspace initialization can be done via</blockquote><blockquote class="quoted-plain-text" type="cite">bsp_work_area_initialize().</blockquote><blockquote class="quoted-plain-text" type="cite"><br></blockquote><span class="body-text-content"><br>On the zynq the ethernet driver from Ric (SLAC) for the in tree<br>(existing) IP stack there is:<br><br> uint8_t* start;<br> size_t size = 0x100000;<br> uintptr_t boundary = (uintptr_t) 0;<br> uintptr_t alignment = (uintptr_t) 0x100000;<br> start = (uint8_t*) rtems_heap_allocate_aligned_with_boundary(size,<br> alignment,<br> boundary);<br> arm_cp15_set_translation_table_entries(start,<br> @start[size],<br> ARMV7_MMU_DEVICE);</span></div></div></blockquote><span><br>The </span><span class="body-text-content">arm_cp15_set_translation_table_entries function does help me to setup MMU entry at runtime.<br><br>What exactly means the "boundary"? For exemple, is it possible to allocate the memory with a given start address(memory from 0xC100000 to </span><span class="body-text-content"><span class="body-text-content">0xD100000</span>)? Because in my case, the start address and its length is given by GPU.<br><br>Actually, I've got everything worked without heap allocate and I've only setup the entry. Is it normal? I know little about how the memory managed and </span><span class="body-text-content"><span class="body-text-content">what happened here. </span></span></div></div></div></blockquote><span> </span><br>I couldn't tell the difference between that I add a section in arm_cp15_start_mmu_config_table, then change the start address, end address to the right value, and that I add the entry at runtime. I didn't see any allocation in both ways. Maybe I just need to setup the entry? Or maybe what I've got is an undetermined result. <br><br><br><blockquote type="cite"><div class="msg-quote"><div><div><span class="body-text-content"><span class="body-text-content"></span><br></span><br><blockquote type="cite"><div class="msg-quote"><div class="_stretch"><span class="body-text-content"><br><br>This creates an MMU entry at runtime for a 1M aligned block of memory<br>that has the cache disabled.<br><br>Chris<br>_______________________________________________<br>devel mailing list<br><a href="mailto:devel@rtems.org" data-mce-href="mailto:devel@rtems.org">devel@rtems.org</a><br><a href="http://lists.rtems.org/mailman/listinfo/devel" data-mce-href="http://lists.rtems.org/mailman/listinfo/devel">http://lists.rtems.org/mailman/listinfo/devel</a><br></span></div></div></blockquote></div></div><div class="_stretch"><span class="body-text-content">_______________________________________________<br>devel mailing list<br><a href="mailto:devel@rtems.org" data-mce-href="mailto:devel@rtems.org">devel@rtems.org</a><br><a href="http://lists.rtems.org/mailman/listinfo/devel" data-mce-href="http://lists.rtems.org/mailman/listinfo/devel">http://lists.rtems.org/mailman/listinfo/devel</a></span></div></div></blockquote></div></div></body></html>