SurfaceFlinger crash, how to debug it?

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

SurfaceFlinger crash, how to debug it?

3,584 Views
gmmo
Contributor I

Hello, I am working on an embedded system that uses as iMX6Q/D on it main board. The chip runs Android OS Linux version 3.0.35 (JellyBean ), but under certain soak testing conditions it crashes on SurfaceFlinger and gives me the tomstone crash below.

Our device is a medical device and does not use any intense graphics. In fact we even disabled the hardware acceleration, but we sill keep getting these hard crashes.

anyone has seen this and how did you get it resolved?

thank you!

Revision: '405522'
pid: 2239, tid: 2332, name: SurfaceFlinger  >>> /system/bin/surfaceflinger <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 5f776e84
    r0 40926bf0  r1 4018f838  r2 ffffffff  r3 5f776e64
    r4 409c3390  r5 409c33f8  r6 000000ea  r7 000000ea
    r8 409c3460  r9 00000001  sl 40f38b7c  fp 40f39610
    ip 00000004  sp 405caa98  lr 40028531  pc 402e3d66  cpsr 000f0030
    d0  000000ea00000000  d1  00000110000001e0
    d2  000000003f000000  d3  3f00000000000000
    d4  43f04000000001e0  d5  0000000000000026
    d6  421800003f800000  d7  0000000000000000
    d8  0000000000000000  d9  0000000000000000
    d10 0000000000000000  d11 0000000000000000
    d12 0000000000000000  d13 0000000000000000
    d14 0000000000000000  d15 0000000000000000
    d16 0000000008010001  d17 0000000000000000
    d18 00000000005f3ba8  d19 bfdffffffd0c5e81
    d20 3f811110896efbb2  d21 3f693f97a59339e5
    d22 3ef99342e0ee5069  d23 3fa55553e1053a42
    d24 3f266d602e8c24ba  d25 3f5c85edc9466400
    d26 3fa55b4c4fcda895  d27 bf56bad9fb87f217
    d28 3ec96c90a7bb3a74  d29 bfce28c6a22168c0
    d30 3dee41e5ae2af99c  d31 400921fb54442d18
    scr 60000010

backtrace:
    #00  pc 00025d66  /system/lib/libgui.so (android::Surface::hook_queueBuffer(ANativeWindow*, ANativeWindowBuffer*, int)+7)
    #01  pc 0000e52f  /system/lib/egl/libGLES_android.so
    #02  pc 0000d623  /system/lib/egl/libGLES_android.so (eglPostBufferVIV(void*)+70)
    #03  pc 000037dd  /system/lib/hw/hwcomposer_viv.imx6.so
    #04  pc 00001bd9  /system/lib/hw/hwcomposer.imx6.so
    #05  pc 0002af79  /system/lib/libsurfaceflinger.so (android::HWComposer::commit()+112)
    #06  pc 000252f7  /system/lib/libsurfaceflinger.so (android::SurfaceFlinger::postFramebuffer()+90)
    #07  pc 0002549d  /system/lib/libsurfaceflinger.so (android::SurfaceFlinger::doComposition()+156)
    #08  pc 000256bd  /system/lib/libsurfaceflinger.so (android::SurfaceFlinger::handleMessageRefresh()+48)
    #09  pc 0002611d  /system/lib/libsurfaceflinger.so (android::SurfaceFlinger::onMessageReceived(int)+64)
    #10  pc 000150fd  /system/lib/libutils.so (android::Looper::pollInner(int)+384)
    #11  pc 000151fd  /system/lib/libutils.so (android::Looper::pollOnce(int, int*, int*, void**)+92)
    #12  pc 00021c11  /system/lib/libsurfaceflinger.so (android::MessageQueue::waitMessage()+36)
    #13  pc 0002299d  /system/lib/libsurfaceflinger.so (android::SurfaceFlinger::threadLoop()+2)
    #14  pc 00011a8d  /system/lib/libutils.so (android::Thread::_threadLoop(void*)+216)
    #15  pc 00011581  /system/lib/libutils.so
    #16  pc 0000ca78  /system/lib/libc.so (__thread_entry+72)
    #17  pc 0000cbf4  /system/lib/libc.so (pthread_create+208)
    #18  pc 0001aa9c  [heap]

stack:
         405caa58  404af7a0  /system/lib/libGAL.so
         405caa5c  00000000  
         405caa60  0000005b  
         405caa64  40f39904  [heap]
         405caa68  00000002  
         405caa6c  40f39790  [heap]
         405caa70  40eef308  
         405caa74  40cbb8e8  
         405caa78  4018d004  /system/lib/hw/gralloc.imx6.so
         405caa7c  4018f8b8  
         405caa80  ffffffff  
         405caa84  4018f8b8  
         405caa88  409c33f8  
         405caa8c  4018b68b  /system/lib/hw/gralloc.imx6.so (gralloc_unlock(gralloc_module_t const*, native_handle const*)+8)
         405caa90  df0027ad  
         405caa94  00000000  
    #00  405caa98  402e3d5f  /system/lib/libgui.so (android::Surface::hook_queueBuffer(ANativeWindow*, ANativeWindowBuffer*, int))
         405caa9c  40028531  /system/lib/egl/libGLES_android.so
    #01  405caaa0  00000006  

0 Kudos
2 Replies

2,087 Views
igorpadykov
NXP Employee
NXP Employee

Hi Gustavo

from log there are reference to hwcomposer_viv.imx6.so, please check

imx6DL dual display - hwcomposer_viv.imx6.so crash 

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

2,088 Views
gmmo
Contributor I

igorpadykov‌ Where is the source code for the hwcomposer patch?  I can't include just .so; I need to build it.

thank you!

0 Kudos