Kernel panic when running GPU SDK examples using L3.0.35_4.1.0 on i.MX6Q

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Kernel panic when running GPU SDK examples using L3.0.35_4.1.0 on i.MX6Q

1,803 Views
mcyeung
Contributor I

When running GPU SDK examples (i.e. IMX6_GPU_SDK) using L3.0.35_4.1.0 on i.MX6Q, it often gives kernel panic.  Here are some facts and observations:

  • The i.MX6 board is based on the SabreSD board with some modifications, and is connecting with a LCD panel (i.e. video=mxcfb0:dev=lcd,CLAA-WVGA,if=RGB24 in u-boot environment).
  • The GPU libraries libGAL*, libEGL* and libVIVNATE* being used are that from the ltib output in the same BSP release on Ubuntu rootfs.  Similar results for X11 and fbdev versions.
  • GPU libraries from L3.0.35_4.1.0_DEMO_IMAGE_BSP as well as from L3.0.35_4.1.0_MM_CODECS (Ubuntu binary or compiled versions from source) have also been tried, but kernel panic still exists.
  • Lowering the maximum CPU frequencies or reducing the number of running CPU cores (e.g. set maxcpus=1) improves the situation to certain extent, but it still gives kernel panic eventually when some demanding GPU SDK examples are executed.
  • When the same set of GPU SDK examples are executed on SabreLite board using HDMI as video output, they work properly.

Here are the typical debug outputs for the kernel panic:

fbdev version:

root@localhost:/gpu_sdk_v1.00/Samples/GLES2.0/bin/GLES20_fbdev# ./02_ColoredTriangle

Internal error: Oops - undefined instruction: 0 [#1] PREEMPT SMP

Modules linked in: vivante drm tw9912_tvin

CPU: 0    Not tainted  (3.0.35-2666-gbdde708 #1)

PC is at rb_erase+0x40/0x36c

LR is at timerqueue_del+0x34/0x88

pc : [<8022de7c>]    lr : [<8022f2d4>]    psr: a0000093

sp : 806f3f28  ip : 00000000  fp : 00000000

r10: 8c0084b8  r9 : 00000000  r8 : 8c008568

r7 : 00000043  r6 : 00000000  r5 : 8c0084c4  r4 : 8c008568

r3 : ba38fad0  r2 : ba92db68  r1 : 8c0084c4  r0 : 8c008568

Flags: NzCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment kernel

Control: 10c53c7d  Table: 49a6404a  DAC: 00000015

Process swapper (pid: 0, stack limit = 0x806f22f0)

Stack: (0x806f3f28 to 0x806f4000)

3f20:                   8c008568 8c0084c4 00000000 8022f2d4 00000001 ba47fb58

3f40: 00000000 8008b5d4 8c008568 00000001 00000000 00000043 8c008568 412fc09a

3f60: 80707cc0 8008b934 04da0191 a0000093 8c008568 00000043 00000000 8008b954

3f80: 04da0191 80098010 8070ae7c 412fc09a 04da0191 00000043 00000000 806f2000

3fa0: 8074e244 80707a6c 80507b10 8070ae7c 00000000 8003dce4 80707b3c 8074e1a0

3fc0: 8002c7f0 8c005100 1000406a 80008868 800082f8 00000000 00000000 8002c7f0

3fe0: 00000000 10c53c7d 80707a8c 8002c7ec 8070ae74 10008040 00000000 00000000

[<8022de7c>] (rb_erase+0x40/0x36c) from [<8022f2d4>] (timerqueue_del+0x34/0x88)

[<8022f2d4>] (timerqueue_del+0x34/0x88) from [<8008b5d4>] (__remove_hrtimer+0x38/0xd0)

[<8008b5d4>] (__remove_hrtimer+0x38/0xd0) from [<8008b934>] (hrtimer_try_to_cancel+0x8c/0x98)

[<8008b934>] (hrtimer_try_to_cancel+0x8c/0x98) from [<8008b954>] (hrtimer_cancel+0x14/0x20)

[<8008b954>] (hrtimer_cancel+0x14/0x20) from [<80098010>] (tick_nohz_restart_sched_tick+0x128/0x1ec)

[<80098010>] (tick_nohz_restart_sched_tick+0x128/0x1ec) from [<8003dce4>] (cpu_idle+0xa4/0x124)

[<8003dce4>] (cpu_idle+0xa4/0x124) from [<80008868>] (start_kernel+0x248/0x288)

[<80008868>] (start_kernel+0x248/0x288) from [<10008040>] (0x10008040)

Code: 1afffffb e5902000 e3d22003 05853000 (1a000049)

X11 version:

root@localhost:/gpu_sdk_v1.00/Samples/GLES1.1/bin/GLES11_x11# ./01_SimpleTriangle

Lesson 02

chooseconfig,

createwindow,

creatcontext,

makecurrent,

exiting init,

Unable to handle kernel paging request at virtual address a8689105

pgd = ba0f8000

[a8689105] *pgd=00000000

Internal error: Oops: 805 [#1] PREEMPT SMP

Modules linked in: mxc_v4l2_capture ipu_fg_overlay_sdc ipu_csi_enc ipu_prp_enc ipu_still ipu_bg_overlay_sdc vivante drm g_ncm pn544_i2c pn544 tw9912_tvin

CPU: 0    Not tainted  (3.0.35-2666-gbdde708 #1)

PC is at timerqueue_add+0x54/0xc4

LR is at 0xffffffff

pc : [<8022f37c>]    lr : [<ffffffff>]    psr: 600f0093

sp : 806f3ef8  ip : 00000000  fp : 00000000

r10: 8c0084b8  r9 : 80035480  r8 : 8c008568

r7 : 00000038  r6 : 8c0084c4  r5 : 8c008568  r4 : 8074ec10

r3 : 8074ec08  r2 : bcac8e00  r1 : 0000000d  r0 : a8689100

Flags: nZCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment kernel

Control: 10c53c7d  Table: 4a0f804a  DAC: 00000015

Process swapper (pid: 0, stack limit = 0x806f22f0)

Stack: (0x806f3ef8 to 0x806f4000)

3ee0:                                                       0000000d 8c008568

3f00: 8c0084b8 8c0084b8 00000038 8008b2fc 0000000d a8689100 00000000 8008bd1c

3f20: a8689100 0000000d 806f2000 80707cc0 80035480 00000000 a999be00 00000000

3f40: 00000000 a00f0093 8c008568 a8689100 0000000d 00000000 00000000 8c008568

3f60: 412fc09a 80755638 00000000 8008c01c 00000000 00000002 00000001 80755638

3f80: 00000000 800980a4 00000000 00000002 a7e22485 0000000d 00000000 806f2000

3fa0: 8074e244 80707a6c 80507b10 8070ae7c 00000000 8003dce4 80707b3c 8074e1a0

3fc0: 8002c7f0 8c005100 1000406a 80008868 800082f8 00000000 00000000 8002c7f0

3fe0: 00000000 10c53c7d 80707a8c 8002c7ec 8070ae74 10008040 00000000 00000000

[<8022f37c>] (timerqueue_add+0x54/0xc4) from [<8008b2fc>] (enqueue_hrtimer+0x18/0x50)

[<8008b2fc>] (enqueue_hrtimer+0x18/0x50) from [<8008bd1c>] (__hrtimer_start_range_ns+0x134/0x3e4)

[<8008bd1c>] (__hrtimer_start_range_ns+0x134/0x3e4) from [<8008c01c>] (hrtimer_start_range_ns+0x24/0x2c)

[<8008c01c>] (hrtimer_start_range_ns+0x24/0x2c) from [<800980a4>] (tick_nohz_restart_sched_tick+0x1bc/0x1ec)

[<800980a4>] (tick_nohz_restart_sched_tick+0x1bc/0x1ec) from [<8003dce4>] (cpu_idle+0xa4/0x124)

[<8003dce4>] (cpu_idle+0xa4/0x124) from [<80008868>] (start_kernel+0x248/0x288)

[<80008868>] (start_kernel+0x248/0x288) from [<10008040>] (0x10008040)

Code: e594c000 e35c0000 1afffff5 e5853000 (e1a00005)

---[ end trace d5ce71d1d3963135 ]---

Kernel panic - not syncing: Attempted to kill the idle task!

[<80043854>] (unwind_backtrace+0x0/0xf8) from [<804ff734>] (panic+0x74/0x18c)

[<804ff734>] (panic+0x74/0x18c) from [<80071b58>] (do_exit+0x684/0x6e8)

[<80071b58>] (do_exit+0x684/0x6e8) from [<80040740>] (die+0x228/0x284)

[<80040740>] (die+0x228/0x284) from [<804ff52c>] (__do_kernel_fault.part.4+0x54/0x74)

[<804ff52c>] (__do_kernel_fault.part.4+0x54/0x74) from [<80047570>] (do_translation_fault+0x0/0xa0)

[<80047570>] (do_translation_fault+0x0/0xa0) from [<00000000>] (  (null))

CPU3: stopping

[<80043854>] (unwind_backtrace+0x0/0xf8) from [<80037324>] (do_IPI+0x150/0x17c)

[<80037324>] (do_IPI+0x150/0x17c) from [<8003ca0c>] (__irq_svc+0x4c/0xe8)

Exception stack(0xbff01ef0 to 0xbff01f38)

1ee0:                                     bff01f38 0000000a 00000000 00000003

1f00: 00000082 bff00000 bff00000 00000000 80753cc0 00000003 806f4040 00000000

1f20: 80043154 bff01f38 80073f34 80073998 20000113 ffffffff

[<8003ca0c>] (__irq_svc+0x4c/0xe8) from [<80073998>] (__do_softirq+0x4c/0x140)

[<80073998>] (__do_softirq+0x4c/0x140) from [<80073f34>] (irq_exit+0x94/0x9c)

[<80073f34>] (irq_exit+0x94/0x9c) from [<800372e0>] (do_IPI+0x10c/0x17c)

[<800372e0>] (do_IPI+0x10c/0x17c) from [<8003ca0c>] (__irq_svc+0x4c/0xe8)

Exception stack(0xbff01f90 to 0xbff01fd8)

1f80:                                     80755620 80000093 00000001 00000000

1fa0: bff00000 8074e244 80707a6c 80507b10 8070ae7c 412fc09a 00000000 00000000

1fc0: 00000000 bff01fd8 8004b76c 8003db04 40000013 ffffffff

[<8003ca0c>] (__irq_svc+0x4c/0xe8) from [<8003db04>] (default_idle+0x24/0x28)

[<8003db04>] (default_idle+0x24/0x28) from [<8003dd20>] (cpu_idle+0xe0/0x124)

[<8003dd20>] (cpu_idle+0xe0/0x124) from [<104fc574>] (0x104fc574)

CPU1: stopping

[<80043854>] (unwind_backtrace+0x0/0xf8) from [<80037324>] (do_IPI+0x150/0x17c)

[<80037324>] (do_IPI+0x150/0x17c) from [<8003ca0c>] (__irq_svc+0x4c/0xe8)

Exception stack(0xbffadf90 to 0xbffadfd8)

df80:                                     80755620 80070093 00000001 00000000

dfa0: bffac000 8074e244 80707a6c 80507b10 8070ae7c 412fc09a 00000000 00000000

dfc0: 00000000 bffadfd8 8004b76c 8003db04 40070013 ffffffff

[<8003ca0c>] (__irq_svc+0x4c/0xe8) from [<8003db04>] (default_idle+0x24/0x28)

[<8003db04>] (default_idle+0x24/0x28) from [<8003dd20>] (cpu_idle+0xe0/0x124)

[<8003dd20>] (cpu_idle+0xe0/0x124) from [<104fc574>] (0x104fc574)

CPU2: stopping

[<80043854>] (unwind_backtrace+0x0/0xf8) from [<80037324>] (do_IPI+0x150/0x17c)

[<80037324>] (do_IPI+0x150/0x17c) from [<8003ca0c>] (__irq_svc+0x4c/0xe8)

Exception stack(0xbffb5f90 to 0xbffb5fd8)

5f80:                                     80755620 60070093 00000001 00000000

5fa0: bffb4000 8074e244 80707a6c 80507b10 8070ae7c 412fc09a 00000000 00000000

5fc0: 00000000 bffb5fd8 8004b76c 8003db04 40070013 ffffffff

[<8003ca0c>] (__irq_svc+0x4c/0xe8) from [<8003db04>] (default_idle+0x24/0x28)

[<8003db04>] (default_idle+0x24/0x28) from [<8003dd20>] (cpu_idle+0xe0/0x124)

[<8003dd20>] (cpu_idle+0xe0/0x124) from [<104fc574>] (0x104fc574)

Is there any hint from the debug output above, or any suggestion to debug the problem on our board?  Please advise.

0 Kudos
5 Replies

829 Views
andre_silva
NXP Employee
NXP Employee

I just got the GPU SDK package from FSL website and tested on the latest BSP release, also got from the FSL website, everything worked fine with no issues nor crashes.

0 Kudos

829 Views
Rita_Wang
NXP TechSupport
NXP TechSupport

Hi Tony,

Did yo get the GPU libraries you used on ubuntu from Ltib package ?

Best Regards

Dan

0 Kudos

829 Views
mcyeung
Contributor I

GPU libraries from LTIB, L3.0.35_4.1.0_DEMO_IMAGE_BSP as well as from L3.0.35_4.1.0_MM_CODECS (Ubuntu binary or compiled versions from source) have also been tried, but kernel panic still exists.

0 Kudos

829 Views
mcyeung
Contributor I

GPU libraries from LTIB, L3.0.35_4.1.0_DEMO_IMAGE_BSP as well as from L3.0.35_4.1.0_MM_CODECS (Ubuntu binary or compiled versions from source) have also been tried, but kernel panic still exists.

0 Kudos