<div dir="ltr">How to turn off optimizations, while debugging some of the variables get<div>optimized out.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jan 1, 2020 at 12:02 PM Niteesh <<a href="mailto:gsnb.gn@gmail.com">gsnb.gn@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Good news, The FDT works. For testing purposes, I used a different DTB file provided by<div>raspberrpi foundation. It has a different structure than the DTB from FreeBSD, so I modified the</div><div>initialization code a little bit, but anyhow it works, the registers are initialized from the DTB file. But they are</div><div>virtual addresses we need to offset them before initializing the registers.</div><div><br></div><div>(gdb) p pl011_context<br>$23 = {base = {lock = {interrupt = {<No data fields>}, mutex = {_Queue = {_Lock = {_next_ticket = 0,<br>            _now_serving = 0}, _heads = 0x0, _owner = 0x0, _name = 0x0}}},<br>    lock_acquire = 0x2095d1 <rtems_termios_device_lock_acquire_default>,<br>    lock_release = 0x2095e1 <rtems_termios_device_lock_release_default>},<b> regs = 0x7e201000</b>, irq = 0,<br>  initial_baud = 0}<br>(gdb) <br></div><div><br></div><div>I will add the offset function, and send in the patch. I am also planning to replace a manual search with</div><div>fdt_node_offset_by_compatible. <br></div></div>
</blockquote></div>