Error Running HelloWorld on new BSP

Gedare Bloom gedare at rtems.org
Fri Jun 17 21:27:23 UTC 2016


Break at get_baud_div() or initialize(), since they appear in your
printout of the *frame, which is the interrupted thread context at the
point of the unhandled exception.

On Fri, Jun 17, 2016 at 1:44 PM, Olufowobi, Habeeb
<habeeb.olufowobi at bison.howard.edu> wrote:
> Hi Joel,
>
> When I set the breakpoint at boot_card, this how far I could get;
>
> (gdb) step
> _Terminate (the_source=RTEMS_FATAL_SOURCE_EXCEPTION,
>     is_internal=false, the_error=536874976)
>     at
> ../../../../../../../rtems.git/c/src/../../cpukit/score/src/interr.c:52
> 52      _CPU_Fatal_halt( the_source, the_error );
> (gdb) step
> arm_interrupt_disable ()
>     at ../../cpukit/../../../tm4c129e/lib/include/rtems/score/cpu.h:345
> 345      uint32_t basepri = 0x80;
> (gdb) step
> 347      __asm__ volatile (
> (gdb) step
> 357      return level;
> (gdb) step
> 358    }
> (gdb) step
>
>
>
>
> And the backtrace is below
>
> Program received signal SIGINT, Interrupt.
> 0x0000a6ac in _Terminate (
>     the_source=RTEMS_FATAL_SOURCE_EXCEPTION, is_internal=false,
>     the_error=536874976)
>     at
> ../../../../../../../rtems.git/c/src/../../cpukit/score/src/interr.c:52
> 52      _CPU_Fatal_halt( the_source, the_error );
> (gdb) bt
> #0  0x0000a6ac in _Terminate (
>     the_source=RTEMS_FATAL_SOURCE_EXCEPTION, is_internal=false,
>     the_error=536874976)
>     at
> ../../../../../../../rtems.git/c/src/../../cpukit/score/src/interr.c:52
> #1  0x000085b0 in rtems_fatal (
>     source=RTEMS_FATAL_SOURCE_EXCEPTION, error=536874976)
>     at
> ../../../../../../../rtems.git/c/src/../../cpukit/sapi/src/fatal2.c:34
> #2  0x00013bfc in _ARM_Exception_default (frame=0x20000fe0)
>     at
> ../../../../../../../../../rtems.git/c/src/../../cpukit/score/cpu/arm/arm-exception-default.c:24
> #3  <signal handler called>
> #4  0x00000000 in bsp_start_vector_table_begin ()
> Backtrace stopped: previous frame identical to this frame (corrupt stack?)
> (gdb)
>
>
> Regards,
> Habeeb
>
>
> On Fri, Jun 17, 2016 at 12:51 PM, Joel Sherrill <joel at rtems.org> wrote:
>>
>>
>>
>> On Fri, Jun 17, 2016 at 11:33 AM, Olufowobi, Habeeb
>> <habeeb.olufowobi at bison.howard.edu> wrote:
>>>
>>> Hi,
>>>
>>> I was able to print the frame and below is the result. Also, I realised
>>> the problem is from the uart. Any ideas on how to resolve this?
>>>
>>>
>>> (gdb) print *frame
>>> $1 = {register_r0 = 115200, register_r1 = 1, register_r2 = 0,
>>>   register_r3 = 1073790976, register_r4 = 0, register_r5 = 0,
>>>   register_r6 = 0, register_r7 = 536875096, register_r8 = 0,
>>>   register_r9 = 0, register_r10 = 0, register_r11 = 0,
>>>   register_r12 = 536894384, register_sp = 120,
>>>   register_lr = 0x138d <initialize+60>,
>>>   register_pc = 0x1290 <get_baud_div>,
>>>   register_xpsr = 1090519040, vector = 3,
>>>   vfp_context = 0x0 <bsp_start_vector_table_begin>,
>>>   reserved_for_stack_alignment = 536875056}
>>>
>>>
>>
>> Not knowing this particular BSP, can you set a breakpoint at various
>> points in
>> the assembly startup? At boot_card? How far do you get?
>>
>> Does the code in memory look like it is supposed to versus
>> arm-rtems4.12-objdump?
>>
>>
>>
>>>
>>> On Wed, Jun 15, 2016 at 12:04 PM, Olufowobi, Habeeb
>>> <habeeb.olufowobi at bison.howard.edu> wrote:
>>>>
>>>> Hi,
>>>>
>>>> I have been working on getting the console running for the past few days
>>>> but I am still getting some errors.
>>>> I realized that the system control configuration of the board family
>>>> (LM3S69XX) was different so I had to rewrite the bspstart.c and the
>>>> lm3s69xx.h to suit the TM4C129E I am working on.
>>>> Presently, HelloWorld halt at "CPU_FATAL_HALT(the_source, the_error)"
>>>> and I am getting RTEMS_FATAL_SOURCE_EXCEPTION in the_source and an error
>>>> code. I am not sure how to debug this but reading about it.
>>>>
>>>> Below is the backtrace of the error message.
>>>> Kindly assist.
>>>>
>>>> ^C
>>>> Program received signal SIGINT, Interrupt.
>>>> 0x00004b22 in _Terminate (
>>>>     the_source=the_source at entry=RTEMS_FATAL_SOURCE_EXCEPTION,
>>>>     is_internal=is_internal at entry=false, the_error=536875064)
>>>>     at
>>>> ../../../../../../../rtems.git/c/src/../../cpukit/score/src/interr.c:52
>>>> 52  _CPU_Fatal_halt( the_source, the_error );
>>>> (gdb) bt
>>>> #0  0x00004b22 in _Terminate (
>>>>     the_source=the_source at entry=RTEMS_FATAL_SOURCE_EXCEPTION,
>>>>     is_internal=is_internal at entry=false, the_error=536875064)
>>>>     at
>>>> ../../../../../../../rtems.git/c/src/../../cpukit/score/src/interr.c:52
>>>> #1  0x0000404a in rtems_fatal (
>>>>     source=source at entry=RTEMS_FATAL_SOURCE_EXCEPTION,
>>>>     error=<optimized out>)
>>>>     at
>>>> ../../../../../../../rtems.git/c/src/../../cpukit/sapi/src/fatal2.c:34
>>>> #2  0x00007be2 in _ARM_Exception_default (frame=<optimized out>)
>>>>     at
>>>> ../../../../../../../../../rtems.git/c/src/../../cpukit/score/cpu/arm/arm-exception-default.c:24
>>>> #3  <signal handler called>
>>>> #4  0x00000080 in bsp_start_vector_table_begin ()
>>>> #5  0x00000000 in ?? ()
>>>> (gdb)
>>>>
>>>
>>>
>>> _______________________________________________
>>> devel mailing list
>>> devel at rtems.org
>>> http://lists.rtems.org/mailman/listinfo/devel
>>
>>
>
>
> _______________________________________________
> devel mailing list
> devel at rtems.org
> http://lists.rtems.org/mailman/listinfo/devel



More information about the devel mailing list