This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Segmentation fault (SIGSEGV) on eglCreateWindowSurface on Firefly RK3288 running Android 4.4.2

Hi!

I'm trying to run opengl-gl2_basic.cpp, a native C++ Android OpenGL ES 2 test. Source here: https://android.googlesource.com/platform/frameworks/native/+/android-4.4.2_r1/opengl/tests/gl2_basic/

My platform is the Firefly RK3288 running Android 4.4.2 - 2015-04-18 build. It successfully displays the EGLConfigs and choosing one, however when attempting to call:

eglCreateWindowSurface

the app terminates with a Segmenation Fault (SIGSEGV).


pid: 1229, tid: 1229, name: test-opengl-gl2  >>> ./test-opengl-gl2_basic-debug <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 00001000
Stack frame #00  pc 00001000  <unknown>
Stack frame #01  pc 0000e8ed  /system/lib/libEGL.so (eglCreateWindowSurface+408)
Stack frame #02  pc 000014d9  /data/local/tmp/test-opengl-gl2_basic-debug
Stack frame #03  pc 0000e403  /system/lib/libc.so (__libc_init+50)
Stack frame #04  pc 00000dc4  /data/local/tmp/test-opengl-gl2_basic-debug

I have sanity tested this binary on a Nexus 7 (2013), it runs successfully as the 'shell' user, however the screen does not seem to update as the device is not rooted.


Based on this, I ran the application as the 'shell' user in adb on Firefly, which causes it to fail earlier when attempting to choose a config:


EGLUtils::selectConfigForNativeWindow() returned -22

I'm unsure of how to proceed or what the issue might be, its either accessing a restricted memory address or a pointer to the wrong type. Any help would be appreciated.