<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">2017-07-17 19:03 GMT+02:00 Joel Sherrill <span dir="ltr"><<a href="mailto:joel.sherrill@gmail.com" target="_blank">joel.sherrill@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="auto">Take some of the ideas from low ticker and apply them to hello world. Use printk for one and unified workspace as a starter. You can switch to the simple scheduler and save a few K<div dir="auto"><br></div><div dir="auto">There is also a configure option about the init task being the idle thread. Try that last.<div dir="auto"><div dir="auto"><div dir="auto"><br></div><div dir="auto">What's your default stack size?</div></div></div></div></div><div class="gmail-HOEnZb"><div class="gmail-h5"><div class="gmail_extra"><br><div class="gmail_quote">On Jul 17, 2017 5:59 PM, "Gedare Bloom" <<a href="mailto:gedare@rtems.org" target="_blank">gedare@rtems.org</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">See if you can produce a further stripped down version of hello world,<br>
although I'm not sure there is much else that can be removed...<br>
<br>
Maybe some more tweaking needs to be done to the CPU specific feature<br>
macros in cpukit/score/cpu/riscv/rtems/s<wbr>core/cpu.h and similar?<br>
<br>
What does riscv-rtems4.12-size report about your executable?<br>
<br>
Gedare<br>
<br>
On Mon, Jul 17, 2017 at 11:31 AM, Denis Obrezkov<br>
<<a href="mailto:denisobrezkov@gmail.com" target="_blank">denisobrezkov@gmail.com</a>> wrote:<br>
> I have some bad and good news.<br>
> First of all, I was able to receive a message from hello example:<br>
> Fatal Error 0.2 Halted<br>
> So, uart now works (transmitting), but hello application complains that<br>
> there is not<br>
> enough workspace.<br>
><br>
> Low ticker example, doesn't work neither, and hangs during clock<br>
> initialization<br>
> routine.<br>
><br>
> --<br>
> Regards, Denis Obrezkov<br>
><br>
> ______________________________<wbr>_________________<br>
> devel mailing list<br>
> <a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
> <a href="http://lists.rtems.org/mailman/listinfo/devel" rel="noreferrer" target="_blank">http://lists.rtems.org/mailman<wbr>/listinfo/devel</a><br>
______________________________<wbr>_________________<br>
devel mailing list<br>
<a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
<a href="http://lists.rtems.org/mailman/listinfo/devel" rel="noreferrer" target="_blank">http://lists.rtems.org/mailman<wbr>/listinfo/devel</a><br>
</blockquote></div></div>
</div></div></blockquote></div><br>Yes, I copied some options from low ticker example, and now Hello World outputs:</div><div class="gmail_extra"><div class="gmail_extra">Hello World, oh almost forgot, from RISC-V port ;) </div><div class="gmail_extra">                                                   Fatal Error 5.0 Halted</div><div class="gmail_extra"><br></div><div class="gmail_extra">The last error occurs exiting:</div><div class="gmail_extra"><div class="gmail_extra">0x20402396 in _Terminate (the_source=RTEMS_FATAL_SOURCE_EXIT, the_error=0) at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../cpukit/score/src/interr.c:44</div><div class="gmail_extra">44        _CPU_Fatal_halt( the_source, the_error );</div><div class="gmail_extra">(gdb) i s</div><div class="gmail_extra">#0  0x20402396 in _Terminate (the_source=RTEMS_FATAL_SOURCE_EXIT, the_error=0)</div><div class="gmail_extra">    at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../cpukit/score/src/interr.c:44</div><div class="gmail_extra">#1  0x20419198 in rtems_shutdown_executive (result=0) at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../cpukit/sapi/src/exshutdown.c:21</div><div class="gmail_extra">#2  0x20412828 in _exit (status=0) at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../cpukit/libcsupport/src/newlibc_exit.c:42</div><div class="gmail_extra">#3  0x20411b1c in exit (code=0) at ../../../../../gcc-7.1.0/newlib/libc/stdlib/exit.c:69</div><div class="gmail_extra">#4  0x204003c2 in Init (ignored=2147486792) at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../testsuites/samples/hello/init.c:36</div><div class="gmail_extra">#5  0x20407128 in _Thread_Entry_adaptor_numeric (executing=0x80001588)</div><div class="gmail_extra">    at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../cpukit/score/src/threadentryadaptornumeric.c:25</div><div class="gmail_extra">#6  0x20410056 in _Thread_Handler () at /home/reprofy/Projects/riscv/rtems/development/rtems/kernel/rtems-riscv/c/src/../../cpukit/score/src/threadhandler.c:73</div><div class="gmail_extra">#7  0x2040fff4 in _User_extensions_Thread_exitted (executing=0x80001588) at ../../cpukit/../../../hifive1/lib/include/rtems/score/userextimpl.h:298</div><div><br></div><div>And it seems that it's ok.</div></div><div class="gmail_extra"><br></div></div><div class="gmail_extra">I had to use printk version - I haven't implemented general console initialization.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Now, I want to implement console initialization and make the external 16 MHz oscillator be</div><div class="gmail_extra">default, because it's more precise and stable (it is easier to calculate the baudrate divider value).  <br clear="all"><div><br></div>-- <br><div class="gmail_signature">Regards, Denis Obrezkov</div>
</div></div>