Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blank screen when flashing to SGS2 #273

Open
jammink opened this issue Apr 16, 2012 · 22 comments
Open

Blank screen when flashing to SGS2 #273

jammink opened this issue Apr 16, 2012 · 22 comments

Comments

@jammink
Copy link

jammink commented Apr 16, 2012

May be related to #265

This appears with
B2G commit 08de3ea
Gecko commit 3ba41aed39d6307ab016535a1e30c758de69ebdd
Gaia commit 544ea8917f9ba459d49635c735e3e9b8acbfd0d4

After a $make gonk && $ make flash && cd gaia && git pull origin master && make install-gaia and reboot, I am looking at a blank screen on my device.

adb logcat output: pastebin.mozilla.org/1573802

@joneschrisg
Copy link
Collaborator

Some bad things in logcat

E/HAL ( 2611): load: module=/system/lib/hw/gralloc.GT-I9100.so
E/HAL ( 2611): Cannot load library: link_image[1963]: 2611 could not load needed library 'libMali.so' for 'gralloc.GT-I9100.so' (link_image[1963]: 2611 could not load needed library 'libandroid_runtime.so' for 'libMali.so' (reloc_library[1312]: 2611 cannot locate 'dhcp_do_request_renew'...
E/HAL ( 2611): ))
E/FramebufferNativeWindow( 2611): Couldn't get gralloc module
I/Gecko ( 2611): Logging GL tracing output to (null)/firefox.trace
I/Gecko ( 2611): Attempting load of /data/local/egltrace.so
I/Gecko ( 2611): Attempting load of libEGL.so
E/libEGL ( 2611): load_driver(/system/lib/egl/libEGL_mali.so): Cannot load library: link_image[1963]: 2611 could not load needed library 'libandroid_runtime.so' for 'libEGL_mali.so' (find_library[1220]: 2611 'libandroid_runtime.so' failed to load previously)
E/libEGL ( 2611): eglGetDisplay:642 error 300c (EGL_BAD_PARAMETER)
E/libEGL ( 2611): eglInitialize:656 error 3008 (EGL_BAD_DISPLAY)
I/Gonk ( 2611): Failed to create GL context for fb, trying /dev/graphics/fb0

I/DEBUG ( 9124): debuggerd committing suicide to free the zombie!
I/DEBUG ( 9172): debuggerd: Apr 16 2012 15:09:21

Looks like we're failing to create a GL context, then (maybe) succeeding in using CPU fallback, but then apparently crashing.

Are you using ICS sgs2, by chance?

CC @michaelwu

@jammink
Copy link
Author

jammink commented Apr 17, 2012

I am using Gingerbread on this particular device:

mozilla@mozillab2g:~/dev/nexus-sgs2/B2G/gecko$ adb shell cat /system/build.prop | grep ro.build.display.id | sed -e 's/ro.build.display.id=//' | tr -d '\r'
full_galaxys2-eng 2.3.5 GINGERBREAD eng.mozilla.20120416.150632 test-keys

@joneschrisg
Copy link
Collaborator

When was the last time you re-configured and flashed your kernel? There are some new files we need to pull off device for latest gecko.

@joneschrisg
Copy link
Collaborator

(i.e., make config-galaxy-s2 && make kernel, then flash)

@jammink
Copy link
Author

jammink commented Apr 17, 2012

I did that today, actually.

@shianyow
Copy link
Collaborator

The issue is related to "libnetutils.so" pulled from device with newer stock FW, same as issue #261.
Before this issue been fixed, a temp solution is to pull "libnetutils.so" from older stock FW.

If should be ok if sdk version < 15.

$ adb shell cat /system/build.prop | grep ro.build.version.sdk
ro.build.version.sdk=10

@jammink
Copy link
Author

jammink commented Apr 17, 2012

I'm getting ro.build.version.sdk=10, so presumably this fix would work for me.

@jammink
Copy link
Author

jammink commented Apr 18, 2012

mozilla@mozillab2g:~$ adb shell cat /system/build.prop | grep ro.build.version.sdk
ro.build.version.sdk=10

mozilla@mozillab2g:~$ adb shell cat /system/build.prop | grep ro.build.display.id
ro.build.display.id=GINGERBREAD.XWKI4

@jammink
Copy link
Author

jammink commented Apr 18, 2012

tried on a newer phone and I'm still seeing the same issues:

ro.build.version.sdk=10
ro.build.display.id=GINGERBREAD.XWKE7

@joneschrisg
Copy link
Collaborator

@jammink can you paste the logcat from the newest attempts?

@jammink
Copy link
Author

jammink commented Apr 19, 2012

build from mrproper today:

logcat from XWKE7 GB device:
http://pastebin.mozilla.org/1577902

@joneschrisg
Copy link
Collaborator

Can you please list the exact steps you're taking to build and flash.

Phone

@jammink
Copy link
Author

jammink commented Apr 19, 2012

$ make mrproper
$ make sync (presumably not necessary, but run anyway)
$ ANDROIDFS_DIR=/home/mozilla/sgs2_firmware make config-galaxy-s2
$ make kernel
$ adb reboot download
$ heimdall flash --kernel boot/kernel-android-galaxy-s2/arch/arm/boot/zImage
$ make gonk
$ make flash
$ cd gaia
$ git pull origin master
$ make install-gaia
$ adb reboot

@jammink
Copy link
Author

jammink commented Apr 19, 2012

There were two phones.

Both were Samsung Galaxy SGS2, with ro.build.version.sdk=10:

  1. ro.build.display.id=GINGERBREAD.XWKE7
  2. ro.build.display.id=GINGERBREAD.XWKI4

@jammink
Copy link
Author

jammink commented Apr 19, 2012

I got a system.img (from the came commit and submodule sync) from @dhylands - and for some reason, when I'm flashing directly, it's actually flashing and loading ok.

@dhylands
Copy link

Hi John,

On Wed, Apr 18, 2012 at 11:13 PM, John Hammink
[email protected]
wrote:

I got a system img (from the came commit and submodule sync) from @dhylands - and for some reason it's actually flashing and loading ok.

That's a bit weird. It suggests that something in the build
environment is influencing the image being built.

Dave Hylands
Shuswap, BC, Canada
http://www.davehylands.com

@jammink
Copy link
Author

jammink commented Apr 19, 2012

It would have to be something identical in three separate build environments then. One of them, my flash station for mozcamp, has a fresh B2G git clone, from yesterday.

@shianyow seems to believe it has to do with the firmware. But I have only these two phones (mentioned above), the XWKE7 was only bought a month or two ago.

@dhylands
Copy link

Hi John,

On Thu, Apr 19, 2012 at 12:09 AM, John Hammink
[email protected]
wrote:

It would have to be something identical in three separate build environments then.  One of them, my flash station for mozcamp, has a fresh B2G git clone, from yesterday.

Which version of ubuntu are you using? I happen to be using 12.04. If
all 3 of your computers have the same version of ubuntu, then they'll
all have the same version of build tools, which may be related to the
problem.

@shianyow seems to believe it has to do with the firmware.   But I have only these two phones (mentioned above), the XWKE7 was only bought a month or two ago.

And one of your phones has the same firmware version as mine.

It's probably worth collecting a set of md5sums on the files extracted
from my phone and comparing those to the files extracted from your
phone.

It's also possible that you need to make sure that the phone you're
flashing was in fact the identical phone that you also ran make
config-galaxy-s2.

If some of the prebuilt libraries are different, then firmware built
for one phone might not work on the other.

Dave Hylands
Shuswap, BC, Canada
http://www.davehylands.com

@jammink
Copy link
Author

jammink commented Apr 19, 2012

Hi Dave

First off - thanks for your help. It's been a long day here testing busted build configurations - but I have come up with a list of "pitfalls" which are one of the things I have to present at mozcamp. Plane leaves in 3 hours :-/

I'm using ubuntu 11.10 on all three of my envs (a VM, and both a laptop and desktop which are running natively). So the build tools issue is a distinct possibility (although nexus s flashes normally and without incident on all of the above envs - also SGS2 was flashing normally until very recently).

The two S2s are the ones described in an early comment (not the same). We could do the MD5sum comparison at a later time - perhaps once my plane has landed!

@joneschrisg
Copy link
Collaborator

$ make gonk
$ make flash
$ cd gaia

Just building |make gonk| doesn't build gecko, as of recently. Try a |make gonk && make| step. Also, check 'adb shell ls /system/b2g'.

@dhylands
Copy link

It looks like Issue #280 should fix your build problem

@dhylands
Copy link

Hmm. Maybe not. Because the fix for that was ics specific

cervantesyu pushed a commit to cervantesyu/B2G that referenced this issue Dec 22, 2015
Bug 911271 - Fix run-gdb.sh to work with the new tree structure found in JB. r=mwu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants