arm32
中断初始化
qemu-system-arm -serial null -serial mon:stdio -nographic -M xilinx-zynq-a9 -m 256M -net tap,ifname=qtap,script=no,downscript=no -net nic,model=cadence_gem,macaddr=0e:b0:ba:5e:ba:12 -kernel build/arm-rtems6-xilinx_zynq_a9_qemu-default/media01.exe -s -S
(gdb) target remote:1234 Remote debugging using :1234 bsp_start_vector_table_end () at ../../../bsps/arm/shared/start/start.S:192 192 ../../../bsps/arm/shared/start/start.S: No such file or directory. (gdb) c Continuing. Breakpoint 1, bsp_interrupt_facility_initialize () at ../../../bsps/shared/dev/irq/arm-gicv2.c:181 181 ../../../bsps/shared/dev/irq/arm-gicv2.c: No such file or directory. (gdb) bt #0 bsp_interrupt_facility_initialize () at ../../../bsps/shared/dev/irq/arm-gicv2.c:181 #1 0x001ea576 in bsp_interrupt_initialize () at ../../../bsps/shared/irq/irq-generic.c:163 #2 0x001ea3b2 in bsp_start () at ../../../bsps/arm/xilinx-zynq/start/bspstart.c:40 #3 0x001f5cbc in rtems_initialize_executive () at ../../../cpukit/sapi/src/exinit.c:116 #4 0x001e9d62 in boot_card (cmdline=<optimized out>) at ../../../bsps/shared/start/bootcard.c:55 #5 0x0010426a in bsp_start_hook_0_done () at ../../../bsps/arm/shared/start/start.S:528 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb)
void bsp_interrupt_facility_initialize(void) { volatile gic_cpuif *cpuif = GIC_CPUIF; volatile gic_dist *dist = ARM_GIC_DIST; uint32_t id_count = get_id_count(dist); uint32_t id; arm_interrupt_facility_set_exception_handler(); for (id = 0; id < id_count; id += 32) { #ifdef BSP_ARM_GIC_ENABLE_FIQ_FOR_GROUP_0 dist->icdigr[id / 32] = 0xffffffff; #endif dist->icdicer[id / 32] = 0xffffffff; } for (id = 0; id < id_count; ++id) { gic_id_set_priority(dist, id, PRIORITY_DEFAULT); } for (id = 32; id < id_count; ++id) { gic_id_set_targets(dist, id, 0x01); } cpuif->iccpmr = GIC_CPUIF_ICCPMR_PRIORITY(0xff); cpuif->iccbpr = GIC_CPUIF_ICCBPR_BINARY_POINT(0x0); cpuif->iccicr = CPUIF_ICCICR; dist->icddcr = GIC_DIST_ICDDCR_ENABLE_GRP_1 | GIC_DIST_ICDDCR_ENABLE; enable_fiq(); }
arm32是空函数
static inline void arm_interrupt_facility_set_exception_handler(void) { /* * There is no need to install _ARMV4_Exception_interrupt() since this * handler is already set by start.S. */ }
arm64
static inline void arm_interrupt_facility_set_exception_handler(void) { AArch64_set_exception_handler( AARCH64_EXCEPTION_SPx_IRQ, _AArch64_Exception_interrupt_no_nest ); AArch64_set_exception_handler( AARCH64_EXCEPTION_SP0_IRQ, _AArch64_Exception_interrupt_nest ); }
./kernel2/rtems/cpukit/score/cpu/arm/arm_exc_interrupt.S
[root@centos7 rtems]# ls ./kernel2/rtems/cpukit/score/cpu/arm/arm_exc_interrupt.S ./kernel2/rtems/cpukit/score/cpu/arm/arm_exc_interrupt.S [root@centos7 rtems]# ls ./kernel2/rtems/cpukit/ acinclude.m4 doxy-filter doxygen.h ftpd libblock libcsupport libdl libfs libi2c libmisc librtemscxx libtest mghttpd rtems score vc-key.sh dev doxygen dtc include libcrypt libdebugger libdrvmgr libgnat libmd libpci libstdthreads libtrace posix sapi telnetd zlib [root@centos7 rtems]# ls ./kernel2/rtems/ bsps c cpukit gccdeps.py INSTALL LICENSE.BSD-2-Clause LICENSE.CC-BY-SA-4.0 LICENSE.JFFS2 LICENSE.RPCXDR MAINTAINERS Makefile.maint rtems-bsps spec waf yaml build config.ini Doxyfile gccdeps.pyc LICENSE LICENSE.BSD-3-Clause LICENSE.GPL-2.0 LICENSE.NET long_gcc.py make README rtemslogo.png testsuites wscript [root@centos7 rtems]#
[root@centos7 rtems]# cat ./kernel2/rtems/cpukit/score/cpu/arm/arm_exc_interrupt.S /** * @file * * @ingroup RTEMSScoreCPUARM * * @brief ARM interrupt exception prologue and epilogue. */ /* * Copyright (c) 2009, 2016 embedded brains GmbH. All rights reserved. * * embedded brains GmbH * Dornierstr. 4 * 82178 Puchheim * Germany * <rtems@embedded-brains.de> * * The license and distribution terms for this file may be * found in the file LICENSE in this distribution or at * http://www.rtems.org/license/LICENSE. */ /* * The upper EXCHANGE_SIZE bytes of the INT stack area are used for data * exchange between INT and SVC mode. Below of this is the actual INT stack. * The exchange area is only accessed if INT is disabled. */ #ifdef HAVE_CONFIG_H #include "config.h" #endif #include <rtems/asm.h> #ifdef ARM_MULTILIB_ARCH_V4 #define EXCHANGE_LR r4 #define EXCHANGE_SPSR r5 #define EXCHANGE_CPSR r6 #define EXCHANGE_INT_SP r8 #define EXCHANGE_LIST {EXCHANGE_LR, EXCHANGE_SPSR, EXCHANGE_CPSR, EXCHANGE_INT_SP} #define EXCHANGE_SIZE 16 #define SELF_CPU_CONTROL r7 #define NON_VOLATILE_SCRATCH r9 #define CONTEXT_LIST {r0, r1, r2, r3, EXCHANGE_LR, EXCHANGE_SPSR, SELF_CPU_CONTROL, r12} #define CONTEXT_SIZE 32 .arm .globl _ARMV4_Exception_interrupt _ARMV4_Exception_interrupt: /* Save exchange registers to exchange area */ stmdb sp, EXCHANGE_LIST /* Set exchange registers */ mov EXCHANGE_LR, lr mrs EXCHANGE_SPSR, SPSR mrs EXCHANGE_CPSR, CPSR sub EXCHANGE_INT_SP, sp, #EXCHANGE_SIZE /* Switch to SVC mode */ orr EXCHANGE_CPSR, EXCHANGE_CPSR, #0x1 msr CPSR_c, EXCHANGE_CPSR /* * Save context. We save the link register separately because it has * to be restored in SVC mode. The other registers can be restored in * INT mode. Ensure that stack remains 8 byte aligned. Use register * necessary for the stack alignment for the stack pointer of the * interrupted context. */ stmdb sp!, CONTEXT_LIST stmdb sp!, {NON_VOLATILE_SCRATCH, lr} #ifdef ARM_MULTILIB_VFP /* Save VFP context */ vmrs r0, FPSCR vstmdb sp!, {d0-d7} #ifdef ARM_MULTILIB_VFP_D32 vstmdb sp!, {d16-d31} #endif stmdb sp!, {r0, r1} #endif /* ARM_MULTILIB_VFP */ /* Get per-CPU control of current processor */ GET_SELF_CPU_CONTROL SELF_CPU_CONTROL /* Remember INT stack pointer */ mov r1, EXCHANGE_INT_SP /* Restore exchange registers from exchange area */ ldmia r1, EXCHANGE_LIST /* Get interrupt nest level */ ldr r2, [SELF_CPU_CONTROL, #PER_CPU_ISR_NEST_LEVEL] /* Switch stack if necessary and save original stack pointer */ mov NON_VOLATILE_SCRATCH, sp cmp r2, #0 moveq sp, r1 /* Switch to Thumb-2 instructions if necessary */ SWITCH_FROM_ARM_TO_THUMB_2 r1 /* Increment interrupt nest and thread dispatch disable level */ ldr r3, [SELF_CPU_CONTROL, #PER_CPU_THREAD_DISPATCH_DISABLE_LEVEL] add r2, #1 add r3, #1 str r2, [SELF_CPU_CONTROL, #PER_CPU_ISR_NEST_LEVEL] str r3, [SELF_CPU_CONTROL, #PER_CPU_THREAD_DISPATCH_DISABLE_LEVEL] /* Call BSP dependent interrupt dispatcher */ #ifdef RTEMS_PROFILING cmp r2, #1 bne .Lskip_profiling BLX_TO_THUMB_1 _CPU_Counter_read mov SELF_CPU_CONTROL, r0 BLX_TO_THUMB_1 bsp_interrupt_dispatch BLX_TO_THUMB_1 _CPU_Counter_read mov r2, r0 mov r1, SELF_CPU_CONTROL GET_SELF_CPU_CONTROL r0 mov SELF_CPU_CONTROL, r0 BLX_TO_THUMB_1 _Profiling_Outer_most_interrupt_entry_and_exit .Lprofiling_done: #else BLX_TO_THUMB_1 bsp_interrupt_dispatch #endif /* Load some per-CPU variables */ ldr r0, [SELF_CPU_CONTROL, #PER_CPU_THREAD_DISPATCH_DISABLE_LEVEL] ldrb r1, [SELF_CPU_CONTROL, #PER_CPU_DISPATCH_NEEDED] ldr r2, [SELF_CPU_CONTROL, #PER_CPU_ISR_DISPATCH_DISABLE] ldr r3, [SELF_CPU_CONTROL, #PER_CPU_ISR_NEST_LEVEL] /* Restore stack pointer */ mov sp, NON_VOLATILE_SCRATCH /* Save CPSR in non-volatile register */ mrs NON_VOLATILE_SCRATCH, CPSR /* Decrement levels and determine thread dispatch state */ eor r1, r0 sub r0, #1 orr r1, r0 orr r1, r2 sub r3, #1 /* Store thread dispatch disable and ISR nest levels */ str r0, [SELF_CPU_CONTROL, #PER_CPU_THREAD_DISPATCH_DISABLE_LEVEL] str r3, [SELF_CPU_CONTROL, #PER_CPU_ISR_NEST_LEVEL] /* * Check thread dispatch necessary, ISR dispatch disable and thread * dispatch disable level. */ cmp r1, #0 bne .Lthread_dispatch_done /* Thread dispatch */ mrs NON_VOLATILE_SCRATCH, CPSR .Ldo_thread_dispatch: /* Set ISR dispatch disable and thread dispatch disable level to one */ mov r0, #1 str r0, [SELF_CPU_CONTROL, #PER_CPU_ISR_DISPATCH_DISABLE] str r0, [SELF_CPU_CONTROL, #PER_CPU_THREAD_DISPATCH_DISABLE_LEVEL] /* Call _Thread_Do_dispatch(), this function will enable interrupts */ mov r0, SELF_CPU_CONTROL mov r1, NON_VOLATILE_SCRATCH mov r2, #0x80 bic r1, r2 BLX_TO_THUMB_1 _Thread_Do_dispatch /* Disable interrupts */ msr CPSR, NON_VOLATILE_SCRATCH #ifdef RTEMS_SMP GET_SELF_CPU_CONTROL SELF_CPU_CONTROL #endif /* Check if we have to do the thread dispatch again */ ldrb r0, [SELF_CPU_CONTROL, #PER_CPU_DISPATCH_NEEDED] cmp r0, #0 bne .Ldo_thread_dispatch /* We are done with thread dispatching */ mov r0, #0 str r0, [SELF_CPU_CONTROL, #PER_CPU_ISR_DISPATCH_DISABLE] .Lthread_dispatch_done: /* Switch to ARM instructions if necessary */ SWITCH_FROM_THUMB_2_TO_ARM #ifdef ARM_MULTILIB_VFP /* Restore VFP context */ ldmia sp!, {r0, r1} #ifdef ARM_MULTILIB_VFP_D32 vldmia sp!, {d16-d31} #endif vldmia sp!, {d0-d7} vmsr FPSCR, r0 #endif /* ARM_MULTILIB_VFP */ /* Restore NON_VOLATILE_SCRATCH register and link register */ ldmia sp!, {NON_VOLATILE_SCRATCH, lr} /* * XXX: Remember and restore stack pointer. The data on the stack is * still in use. So the stack is now in an inconsistent state. The * FIQ handler implementation must not use this area. */ mov r0, sp add sp, #CONTEXT_SIZE /* Get INT mode program status register */ mrs r1, CPSR bic r1, r1, #0x1 /* Switch to INT mode */ msr CPSR_c, r1 /* Save EXCHANGE_LR and EXCHANGE_SPSR registers to exchange area */ stmdb sp!, {EXCHANGE_LR, EXCHANGE_SPSR} /* Restore context */ ldmia r0, CONTEXT_LIST /* Set return address and program status */ mov lr, EXCHANGE_LR msr SPSR_fsxc, EXCHANGE_SPSR /* Restore EXCHANGE_LR and EXCHANGE_SPSR registers from exchange area */ ldmia sp!, {EXCHANGE_LR, EXCHANGE_SPSR} #ifdef ARM_MULTILIB_HAS_LOAD_STORE_EXCLUSIVE /* * We must clear reservations here, since otherwise compare-and-swap * atomic operations with interrupts enabled may yield wrong results. * A compare-and-swap atomic operation is generated by the compiler * like this: * * .L1: * ldrex r1, [r0] * cmp r1, r3 * bne .L2 * strex r3, r2, [r0] * cmp r3, #0 * bne .L1 * .L2: * * Consider the following scenario. A thread is interrupted right * before the strex. The interrupt updates the value using a * compare-and-swap sequence. Everything is fine up to this point. * The interrupt performs now a compare-and-swap sequence which fails * with a branch to .L2. The current processor has now a reservation. * The interrupt returns without further strex. The thread updates the * value using the unrelated reservation of the interrupt. */ clrex #endif /* Return from interrupt */ subs pc, lr, #4 #ifdef RTEMS_PROFILING #ifdef __thumb2__ .thumb #else .arm #endif .Lskip_profiling: BLX_TO_THUMB_1 bsp_interrupt_dispatch b .Lprofiling_done #endif #endif /* ARM_MULTILIB_ARCH_V4 */
bsps/arm/shared/start/start.S
或者采用
_CPU_ISR_install_vector(ARM_EXCEPTION_IRQ, _ARMV4_Exception_interrupt, NULL);
[root@centos7 rtems-libbsd-a64]# arm-rtems6-gdb build/arm-rtems6-xilinx_zynq_a9_qemu-default/media01.exe GNU gdb (GDB) 10.1.90.20210409-git Copyright (C) 2021 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "--host=aarch64-linux-gnu --target=arm-rtems6". Type "show configuration" for configuration details. For bug reporting instructions, please see: <https://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from build/arm-rtems6-xilinx_zynq_a9_qemu-default/media01.exe... (gdb) b arm_exc_interrupt Function "arm_exc_interrupt" not defined. Make breakpoint pending on future shared library load? (y or [n]) n (gdb) b _ARMV4_Exception_interrupt Breakpoint 1 at 0x1faf1c: file ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S, line 56. (gdb) c The program is not being run. (gdb) target remote:1234 Remote debugging using :1234 bsp_start_vector_table_end () at ../../../bsps/arm/shared/start/start.S:192 192 ../../../bsps/arm/shared/start/start.S: No such file or directory. (gdb) c Continuing. Breakpoint 1, _ARMV4_Exception_interrupt () at ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S:56 56 ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S: No such file or directory. (gdb) bt #0 _ARMV4_Exception_interrupt () at ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S:56 #1 0x001fb18c in ?? () Backtrace stopped: previous frame identical to this frame (corrupt stack?)
bsp_interrupt_dispatch_entries
(gdb) p *entry $1 = {handler = 0x1e99fd <Clock_isr>, arg = 0x0, next = 0x0, info = 0x257ba4 "Clock"} (gdb)
(gdb) p *entry $1 = {handler = 0x1e99fd <Clock_isr>, arg = 0x0, next = 0x0, info = 0x257ba4 "Clock"} (gdb)
(gdb) bt #0 Clock_isr (arg=0x0) at ../../../bsps/arm/include/../../shared/dev/clock/clockimpl.h:142 #1 0x001ea40a in bsp_interrupt_dispatch_entries (entry=0x47b4d8) at ../../../bsps/include/bsp/irq-generic.h:455 #2 bsp_interrupt_handler_dispatch_unchecked (vector=0) at ../../../bsps/include/bsp/irq-generic.h:482 #3 bsp_interrupt_handler_dispatch (vector=0) at ../../../bsps/include/bsp/irq-generic.h:509 #4 arm_interrupt_handler_dispatch (vector=0) at ../../../bsps/arm/include/dev/irq/arm-gic-arch.h:50 #5 bsp_interrupt_dispatch () at ../../../bsps/shared/dev/irq/arm-gicv2.c:61 #6 0x001faf82 in _ARMV4_Exception_interrupt () at ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S:130 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb)
clock
cock install
Breakpoint 14, bsp_interrupt_entry_install (entry=0x47b4d8, options=1, vector=27) at ../../../bsps/shared/irq/irq-generic.c:218 218 ../../../bsps/shared/irq/irq-generic.c: No such file or directory. (gdb) bt #0 bsp_interrupt_entry_install (entry=0x47b4d8, options=1, vector=27) at ../../../bsps/shared/irq/irq-generic.c:218 #1 rtems_interrupt_entry_install (vector=vector@entry=27, options=options@entry=1, entry=entry@entry=0x47b4d8) at ../../../bsps/shared/irq/irq-generic.c:280 #2 0x001e9d96 in rtems_interrupt_handler_install (vector=vector@entry=27, info=info@entry=0x257ba4 "Clock", options=options@entry=1, routine=routine@entry=0x1e99fd <Clock_isr>, arg=0x0) at ../../../bsps/shared/irq/irq-handler-install.c:107 #3 0x001e9ae2 in a9mpcore_clock_handler_install () at ../../../bsps/arm/shared/clock/clock-a9mpcore.c:48 #4 _Clock_Initialize () at ../../../bsps/arm/include/../../shared/dev/clock/clockimpl.h:216 #5 0x001f5cbc in rtems_initialize_executive () at ../../../cpukit/sapi/src/exinit.c:116 #6 0x001e9d62 in boot_card (cmdline=<optimized out>) at ../../../bsps/shared/start/bootcard.c:55 #7 0x0010426a in bsp_start_hook_0_done () at ../../../bsps/arm/shared/start/start.S:528 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb)
Clock_isr
Breakpoint 12, Clock_isr (arg=0x0) at ../../../bsps/arm/include/../../shared/dev/clock/clockimpl.h:142 142 ../../../bsps/arm/include/../../shared/dev/clock/clockimpl.h: No such file or directory. (gdb) bt #0 Clock_isr (arg=0x0) at ../../../bsps/arm/include/../../shared/dev/clock/clockimpl.h:142 #1 0x001ea40a in bsp_interrupt_dispatch_entries (entry=0x47b4d8) at ../../../bsps/include/bsp/irq-generic.h:455 #2 bsp_interrupt_handler_dispatch_unchecked (vector=0) at ../../../bsps/include/bsp/irq-generic.h:482 #3 bsp_interrupt_handler_dispatch (vector=0) at ../../../bsps/include/bsp/irq-generic.h:509 #4 arm_interrupt_handler_dispatch (vector=0) at ../../../bsps/arm/include/dev/irq/arm-gic-arch.h:50 #5 bsp_interrupt_dispatch () at ../../../bsps/shared/dev/irq/arm-gicv2.c:61 #6 0x001faf82 in _ARMV4_Exception_interrupt () at ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S:130 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb)
uart
(gdb) c Continuing. Breakpoint 14, bsp_interrupt_entry_install (entry=0x4840d0, options=0, vector=82) at ../../../bsps/shared/irq/irq-generic.c:218 218 in ../../../bsps/shared/irq/irq-generic.c (gdb) bt #0 bsp_interrupt_entry_install (entry=0x4840d0, options=0, vector=82) at ../../../bsps/shared/irq/irq-generic.c:218 #1 rtems_interrupt_entry_install (vector=vector@entry=82, options=options@entry=0, entry=entry@entry=0x4840d0) at ../../../bsps/shared/irq/irq-generic.c:280 #2 0x001e9d96 in rtems_interrupt_handler_install (vector=82, info=info@entry=0x257d34 "UART", options=options@entry=0, routine=routine@entry=0x1ea2e5 <zynq_uart_interrupt>, arg=arg@entry=0x483cf0) at ../../../bsps/shared/irq/irq-handler-install.c:107 #3 0x001ea380 in zynq_uart_first_open (tty=0x483cf0, base=0x413130 <zynq_uart_instances+44>, term=<optimized out>, args=<optimized out>) at ../../../bsps/shared/dev/serial/zynq-uart.c:83 #4 0x001efb10 in rtems_termios_open_tty (major=<optimized out>, minor=<optimized out>, args=args@entry=0x47aedc <_ISR_Stack_area_begin+2780>, tty=0x483cf0, device_node=device_node@entry=0x47b570, callbacks=callbacks@entry=0x0) at ../../../cpukit/libcsupport/src/termios.c:549 #5 0x001eff08 in rtems_termios_imfs_open (iop=<optimized out>, path=<optimized out>, oflag=<optimized out>, mode=<optimized out>) at ../../../cpukit/libcsupport/src/termios.c:2093 #6 0x001eea8c in do_open (mode=<optimized out>, oflag=0, path=0x22855c "/dev/console", iop=0x459d80 <rtems_libio_iops>) at ../../../cpukit/libcsupport/src/open.c:123 #7 open (path=path@entry=0x22855c "/dev/console", oflag=0) at ../../../cpukit/libcsupport/src/open.c:165 --Type <RET> for more, q to quit, c to continue without paging-- #8 0x001eeb96 in rtems_libio_post_driver () at ../../../cpukit/libcsupport/src/open_dev_console.c:31 #9 0x001f5cbc in rtems_initialize_executive () at ../../../cpukit/sapi/src/exinit.c:116 #10 0x001e9d62 in boot_card (cmdline=<optimized out>) at ../../../bsps/shared/start/bootcard.c:55 #11 0x0010426a in bsp_start_hook_0_done () at ../../../bsps/arm/shared/start/start.S:528 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb) b zynq_uart_interrupt Breakpoint 16 at 0x1ea2e4: file ../../../bsps/shared/dev/serial/zynq-uart.c, line 37. (gdb)
zynq_uart_interrupt
(gdb) bt #0 bsp_interrupt_entry_install (entry=0x4840d0, options=0, vector=82) at ../../../bsps/shared/irq/irq-generic.c:218 #1 rtems_interrupt_entry_install (vector=vector@entry=82, options=options@entry=0, entry=entry@entry=0x4840d0) at ../../../bsps/shared/irq/irq-generic.c:280 #2 0x001e9d96 in rtems_interrupt_handler_install (vector=82, info=info@entry=0x257d34 "UART", options=options@entry=0, routine=routine@entry=0x1ea2e5 <zynq_uart_interrupt>, arg=arg@entry=0x483cf0) at ../../../bsps/shared/irq/irq-handler-install.c:107 #3 0x001ea380 in zynq_uart_first_open (tty=0x483cf0, base=0x413130 <zynq_uart_instances+44>, term=<optimized out>, args=<optimized out>) at ../../../bsps/shared/dev/serial/zynq-uart.c:83 #4 0x001efb10 in rtems_termios_open_tty (major=<optimized out>, minor=<optimized out>, args=args@entry=0x47aedc <_ISR_Stack_area_begin+2780>, tty=0x483cf0, device_node=device_node@entry=0x47b570, callbacks=callbacks@entry=0x0) at ../../../cpukit/libcsupport/src/termios.c:549 #5 0x001eff08 in rtems_termios_imfs_open (iop=<optimized out>, path=<optimized out>, oflag=<optimized out>, mode=<optimized out>) at ../../../cpukit/libcsupport/src/termios.c:2093 #6 0x001eea8c in do_open (mode=<optimized out>, oflag=0, path=0x22855c "/dev/console", iop=0x459d80 <rtems_libio_iops>) at ../../../cpukit/libcsupport/src/open.c:123 #7 open (path=path@entry=0x22855c "/dev/console", oflag=0) at ../../../cpukit/libcsupport/src/open.c:165 --Type <RET> for more, q to quit, c to continue without paging--n #8 0x001eeb96 in rtems_libio_post_driver () at ../../../cpukit/libcsupport/src/open_dev_console.c:31 #9 0x001f5cbc in rtems_initialize_executive () at ../../../cpukit/sapi/src/exinit.c:116 #10 0x001e9d62 in boot_card (cmdline=<optimized out>) at ../../../bsps/shared/start/bootcard.c:55 #11 0x0010426a in bsp_start_hook_0_done () at ../../../bsps/arm/shared/start/start.S:528 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb) p *entry $2 = {handler = 0x1ea2e5 <zynq_uart_interrupt>, arg = 0x483cf0, next = 0x0, info = 0x257d34 "UART"} (gdb) b zynq_uart_interrupt Breakpoint 2 at 0x1ea2e4: file ../../../bsps/shared/dev/serial/zynq-uart.c, line 37. (gdb) c Continuing. Breakpoint 2, zynq_uart_interrupt (arg=0x483cf0) at ../../../bsps/shared/dev/serial/zynq-uart.c:37 37 ../../../bsps/shared/dev/serial/zynq-uart.c: No such file or directory. (gdb) bt #0 zynq_uart_interrupt (arg=0x483cf0) at ../../../bsps/shared/dev/serial/zynq-uart.c:37 #1 0x001ea40a in bsp_interrupt_dispatch_entries (entry=0x4840d0) at ../../../bsps/include/bsp/irq-generic.h:455 #2 bsp_interrupt_handler_dispatch_unchecked (vector=0) at ../../../bsps/include/bsp/irq-generic.h:482 #3 bsp_interrupt_handler_dispatch (vector=0) at ../../../bsps/include/bsp/irq-generic.h:509 #4 arm_interrupt_handler_dispatch (vector=0) at ../../../bsps/arm/include/dev/irq/arm-gic-arch.h:50 #5 bsp_interrupt_dispatch () at ../../../bsps/shared/dev/irq/arm-gicv2.c:61 #6 0x001faf82 in _ARMV4_Exception_interrupt () at ../../../cpukit/score/cpu/arm/arm_exc_interrupt.S:130 Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb)
(gdb) bt #0 bsp_interrupt_entry_install (entry=0x511328, options=0, vector=54) at ../../../bsps/shared/irq/irq-generic.c:218 #1 rtems_interrupt_entry_install (vector=vector@entry=54, options=options@entry=0, entry=entry@entry=0x511328) at ../../../bsps/shared/irq/irq-generic.c:280 #2 0x001e9d96 in rtems_interrupt_handler_install (vector=54, info=info@entry=0x2410a8 "IRQS", options=0, routine=routine@entry=0x1e9e25 <bsp_interrupt_server_trigger>, arg=arg@entry=0x511308) at ../../../bsps/shared/irq/irq-handler-install.c:107 #3 0x001e9f32 in bsp_interrupt_server_install_helper (arg=0x4834c4) at ../../../bsps/shared/irq/irq-server.c:180 #4 0x001e9ff8 in bsp_interrupt_server_task (arg=4676060) at ../../../bsps/shared/irq/irq-server.c:363 #5 0x001f95b4 in _Thread_Handler () at ../../../cpukit/score/src/threadhandler.c:145 #6 0x001f945e in _Thread_Do_dispatch (cpu_self=<optimized out>, level=<optimized out>) at ../../../cpukit/score/src/threaddispatch.c:309 #7 0x00000000 in ?? () Backtrace stopped: previous frame identical to this frame (corrupt stack?) (gdb) p *entry $3 = {handler = 0x1e9e25 <bsp_interrupt_server_trigger>, arg = 0x511308, next = 0x0, info = 0x2410a8 "IRQS"} (gdb)