UCOS app crashes linux OS during AMP reset

UCOS app crashes linux OS during AMP reset

Home Forums Real-Time Kernels UCOS app crashes linux OS during AMP reset

This topic contains 2 replies, has 2 voices, and was last updated by  mike tran 5 months, 1 week ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • #27053

    mike tran

    Hi UCOS,

    vivado/sdk/petalinux 2017.4, Microzed(7020), Xilinx SDK Repository 1.43, xapp1078 AMP

    Following Xilinx example xapp1078, I am working on AMP project (Petalinux on cpu0 and UCOS app on cpu1) with Microzed. Now I want to reset and then restart UCOS app on CPU1, reference to https://www.xilinx.com/support/answers/53828.html . For comparison, I also made AMP (Petalinux on cpu0 and Xilinx SDK app on CPU1).

    zynq> poke 0x00000024 0x37000000 // app address
    zynq> poke 0xf8000008 0xdf0d // software reset CPU1
    zynq> poke 0xf8000244 0x22
    zynq> poke 0xf8000244 0x2
    zynq> poke 0xf8000244 0x20
    zynq> poke 0xf8000244 0x0
    zynq> poke 0xf8000004 0x0000767B // lock the slcr register access

    Above commands are able to reset/restart Xilinx SDK app on CPU1, however, linux OS on CPU0 crashes when trying to reset/restart UCOS app on CPU1. Interesting to find that UCOS app is able to restart on CPU1, i.e., CPU1 does reset and restart UCOS app, though CPU0 crashes.

    Below is linux on CPU0 crash information:

    Unable to handle kernel paging request at virtual address ddf4a540
    pgd = de5c8000
    [ddf4a540] *pgd=2de1141e(bad)
    Internal error: Oops – BUG: 8000000d [#1] PREEMPT SMP ARM
    Modules linked in:
    CPU: 0 PID: 700 Comm: poke Not tainted 4.9.0-xilinx #1
    Hardware name: Xilinx Zynq Platform
    task: de6c8580 task.stack: de564000
    PC is at 0xddf4a540
    LR is at __wake_up_common+0x4c/0x74
    pc : [<ddf4a540>] lr : [<c014a5e0>] psr: 20000093
    sp : de565db8 ip : 00000000 fp : a0000013
    r10: ddf4a540 r9 : 00000081 r8 : 00000000
    r7 : 00000001 r6 : 00000001 r5 : cfd69390 r4 : c0195130
    r3 : 00000004 r2 : 00000000 r1 : 00000001 r0 : cfdb9d38
    Flags: nzCv IRQs off FIQs on Mode SVC_32 ISA ARM Segment none
    Control: 18c5387d Table: 2e5c804a DAC: 00000051
    Process poke (pid: 700, stack limit = 0xde564210)
    Stack: (0xde565db8 to 0xde566000)
    5da0: cfd6938c 60000093
    5dc0: 00000001 00000001 00000004 dcd48c21 cfd69200 c014a63c 00000004 00000001
    5de0: cfd69200 00000114 00000021 c095a334 00000000 c0348a54 c095a334 c035b518
    5e00: 00000000 de533c00 00000021 c0358384 cfd69200 00000fff 00000021 cfd69200
    5e20: 00000021 dcd48c00 00000000 e098d270 cfd69280 de5190c0 de564000 c0344354
    5e40: 00000800 dcd48c00 cfd6938c e098b000 b6fd4000 00000002 de6c8580 c014a97c
    5e60: cfdb9d44 cfd69390 cfd69200 cfd69200 00000021 00000000 00000021 de5190c0
    5e80: de564000 b6fd4150 cfc1d100 c0340dbc c03440d4 dcd48c00 00000051 00000021
    5ea0: 00000001 de5190c0 00000000 00000001 00000021 de565f88 de565ed4 c0340ba4
    5ec0: 00000000 c01ca76c de565ed0 de565ed4 cfdd5700 00000001 00000000 00000067
    5ee0: cfdd5700 0000000a 00000000 00000017 b6fd4150 c09080cc de565fb0 18c5387d
    5f00: bebe3c50 0000ddb8 bebe3c3c c010128c 00000001 b6fda000 00000003 00000001
    5f20: cfd56380 c01b5518 000f8000 00000000 00001000 cfd563b8 de4a0b40 00000000
    5f40: 00001000 00000003 de564000 de5190c0 de5190c0 bebe3a0c 0000000a 00000000
    5f60: de564000 00000000 bebe3c3c c01ca924 de565f88 00000000 0000000a c01ca970
    5f80: 00000000 bebe3a0c 00000000 00000000 00000000 0000000a b6fd4194 00000092
    5fa0: c0106d24 c0106b60 00000000 0000000a 00000002 bebe3a0c 0000000a 00000000
    5fc0: 00000000 0000000a b6fd4194 00000092 00000000 bebe3c64 bebe3c58 bebe3c3c
    5fe0: bebe3c18 bebe39d8 b6fc59d4 b6fc58f4 60000010 00000002 d6feebfe 5c6fc5ff
    [<c014a5e0>] (__wake_up_common) from [<c014a63c>] (__wake_up+0x34/0x48)
    [<c014a63c>] (__wake_up) from [<c0348a54>] (tty_port_tty_wakeup+0x14/0x20)
    [<c0348a54>] (tty_port_tty_wakeup) from [<c035b518>] (cdns_uart_start_tx+0x74/0x9c)
    [<c035b518>] (cdns_uart_start_tx) from [<c0358384>] (uart_write+0xc4/0x174)
    [<c0358384>] (uart_write) from [<c0344354>] (n_tty_write+0x280/0x400)
    [<c0344354>] (n_tty_write) from [<c0340dbc>] (tty_write+0x218/0x25c)
    [<c0340dbc>] (tty_write) from [<c01ca76c>] (do_readv_writev+0x28c/0x2b8)
    [<c01ca76c>] (do_readv_writev) from [<c01ca924>] (vfs_writev+0x44/0x4c)
    [<c01ca924>] (vfs_writev) from [<c01ca970>] (do_writev+0x44/0x7c)
    [<c01ca970>] (do_writev) from [<c0106b60>] (ret_fast_syscall+0x0/0x3c)
    Code: 80390006 2434623f 813d0615 38cf6375 (dcd3e268)
    —[ end trace 8009f581d276c293 ]—
    note: poke[700] exited with preempt_count 2

    Please advise, thanks in advance



    Hello Mike,

    The xapp1078 example doesn’t work with newer releases of the uCOS repository.
    We are working on our AMP support and hope to have an update soon.



    mike tran

    Hi Sharbel Bousemaan,

    I tested OpenAMP for zynq in ucos_v1.41, as described in

    I also tried xilinx SDK openamp_echo_test project.

    Further, I replaced “image_echo_test” in Petalinux-build by ucos_openamp_slave.elf,


    # modprobe zynq_remoteproc firmware=image_echo_test

    only invokes “remoteproc”, while missing “virtio”. Therefore, echo_test would not start.

    Wish Micrium expert will come out a Petalinux-UCOS AMP solution.

    Thanks in advance.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

View the complete site map