Jump to content

[Development][ROM] Stock FROYO + 2.6.32 kernel


Guest pier11

Recommended Posts

Experiment #1.

Loaded into u8220 cm7 rom (from u8150 cm7) :

/system/app

/system/framework

Result:

- no notification bar (same as in u8150 cm7);

- radio works fine. (Checked my balance).Mobile data connection works fine too;

- nice screen off animation (like when old CRT tv turns off), but sluggish.

Experiment #1.1

Transferred in addition:

/system/fonts

/system/media

/system/usr

Results: same as #1

Experiment #1.2

Transferred in addition:

/system/xbin

Results: same as #1

Experiment #1.3

Transferred in addition:

/system/bin/* (but qmuxd - ril related)

Results:

- same as #1

- NO sound, silence.

- no vibrator

- screen rotation stopped working

Experiment #1.4

Transferred in addition:

/system/build.prop (AS IS)

Results:

- same as #1.3 (radio still works fine)

- screen density changed;

- dimmer screen (Brightness does not work)

- no keypad lights

Experiment #1.5

Transferred in addition:

/system/etc/

Results:

- same as #1.4

- no wifi (predictable - drivers were in etc/firmware)

remains to merge:

/system/lib

Notes:

- Notification bar FC can be fixed by replacing SystemUI.apk file from u8220 rom;

- replacing bin/qmuxd from u8150 100% breaks radio and in logs is presented as rild crash (!) - this is likely were you failed when replaced just radio LIBs.

Edited by pier11
Link to comment
Share on other sites

...

Notes:

- Notification bar FC can be fixed by replacing SystemUI.apk file from u8220 rom;

- replacing bin/qmuxd from u8150 100% breaks radio and in logs is presented as rild crash (!) - this is likely were you failed when replaced just radio LIBs.

Great experiments, thanks for documenting all these results.

So we have identified qmuxd as one critical component outside system/lib. All remaining critical components are to be inside system/lib.

by-product: build.prop influencing keypad lights might explain the ascend vs u8150 keypad lights working with native kernel .32 thing.

I also did some experiments - cm6-clean on the phone, and inserting libs from u8150-froyo into that. Result: From all files listed in RIL section of your overview, every single file is enough to break RIL on cm6. Exception: libdiag.so and libdsm.so of u8150 can be put into cm6 and it will still have working radio.

But, since on cm6 vs u8150-froyo system libs like libc and so on differ, it might just be a binary incompatibility for a single lib that breaks things.

Edited by dr.flo
Link to comment
Share on other sites

some more experiments.

Now with knowledge that /lib + qmuxd do the magic, loading into opposite direction: parts of cm7-u8220 -> cm7-u8150

Note: I run cm7-u8150 on .32 kernel + 7.2 ramdisk from u8220.

Experiment #2 (brave):

- loaded qemuxd + 15 ril-related libs only from my list of dependencies above.

Result: rild crash.

Experiment #2.1 (cautions)

- replaced all /system/lib

Result: rild crach.

Experiment #2.2 (highlighting)

- replaced zImage (only) in boot image to pulse's original 2.6.29. (ramdisk is from u8220 cm7.2)

Result: radio works!!

It's not to blame new .32 kernel right away, But it does definitely expose slightly different API, otter libs are basing on, like libc.so & Co.

On the other hand ril works just fine with .32 kernel on cm6/7...

I quess you should have compiled u8220 against .32 kernel

(Same should be true for your cm6-clean experiments. If compiled against .29 kernel, it's doomed to incompatibility with u8150 libs compiled against .32 kernel)

EDIT:

Experiment #3

- our .32 kernel + 7.2 u8220 ramdisk go into cm7-u8220

Result: no radio (though no rild crashes)

Which proves that cm7-8220 should have been compiled against .32 kernel to make lib interchanges possible.

Experiment #3.1

- original pulse's 2.6.29 kernel + 7.2 u8220 ramdisk go into cm7-u8220

Result: radio works fine

Edited by pier11
Link to comment
Share on other sites

Experiment #2 (brave):

- loaded qemuxd + 15 ril-related libs only from my list of dependencies above.

Result: rild crash.

Experiment #2.1 (cautions)

- replaced all /system/lib

Result: rild crach.

Experiment #2.2 (highlighting)

- replaced zImage (only) in boot image to pulse's original 2.6.29. (ramdisk is from u8220 cm7.2)

Result: radio works!!

...

Experiment #3

- our .32 kernel + 7.2 u8220 ramdisk go into cm7-u8220

Result: no radio (though no rild crashes)

Which proves that cm7-8220 should have been compiled against .32 kernel to make lib interchanges possible.

Experiment #3.1

- original pulse's 2.6.29 kernel + 7.2 u8220 ramdisk go into cm7-u8220

Result: radio works fine

ok now you managed to make me confused :blink:

Doesn't experiment sum(#2 #2.1 #2.2) turn cm7-u8150 into cm7-u8220? Radio is expected to work then.

I don't understand #3 - that's what I did several times when playing with camera stuff - i.e. just exchanging zImage (kernels TomG#41 vs pier11 in boot.img, while keeping the same ramdisk). Never experienced no-ril situation with that...

For example the cm7 of the cam wrapper thread was built with .29 kernel. I could simply insert you zimage there without issues (apart from wifi/sensors etc needing replacement too)

How do you compile CMx against a certain kernel? From my understanding, we just have a prebuilt kernel zimage in the device tree. Exchanging that should not influence the build process at all. It should just be used for the final step where boot image gets assembled. Maybe I'm wrong but.... Please tell me how the kernel version influences the build.

Link to comment
Share on other sites

ok, I quess Experment #3 series should be disregarded. Looks like I composed .32 boot image in a wrong fashion.

Now I redid it as ramdisk from cm7.2 + .32 kernel from normal branch.

Your cm7-u8220 works fine with radio now. Sorry for confusion.

EDIT:

Experiment #2.1a (how it supposed to be):

cm7-u8150 (kernel - .32 normal branch + u8220 cm7.2 randisk)

- qmuxd from cm7-u8220

- /system/lib from cm7-u8220

Result: radio works

Experiment #2a (15 ril libs + qmuxd):

cm7-u8150 (kernel - .32 normal branch + u8220 cm7.2 randisk)

- qmuxd from cm7-u8220

- /system/lib reverted to original cm7-u8150

- replaced only 15 RIL-related libs from cm7-u8220.

Results:

- radio works

- Settings menu hesitated to show Baseband version, but shows prone#, IMEA just fine. I surf provider's web site via mobile data connection fine, can request my balance.

Edited by pier11
Link to comment
Share on other sites

GOT RIL WORKING ON UM840 !! WOOHOOO :)

GREAT news! Congratulations!!!

Um840 is a good base because it supports front camera. I'm just wondering - would the trick also work on u8150 or did you have to switch to um840 because u8150 refuses to work?

I'm currently downloading... slow.... either my ISP or mediafire has too much load. I guess it is mediafire.

Link to comment
Share on other sites

works for me too.

Doesn't work on u8150-froyo (and on ascend).

I get

E/dalvikvm-gc( 1277): Could not create 700416-byte ashmem mark stack: Permission denied

E/dalvikvm-heap( 1277): dvmHeapBeginMarkStep failed; aborting

E/dalvikvm( 1277): VM aborting

when patching u8150-froyo in the same way that works with um840 (15 libs + qmuxd + init.qcom.rc in ramdisk - did I miss s.th.?)

I also tried to leave init.huawei.rc in place and just added the ril permissions...

Link to comment
Share on other sites

when patching u8150-froyo in the same way that works with um840 (15 libs + qmuxd + init.qcom.rc in ramdisk - did I miss s.th.?)

Yes, this is it.

I never tried with u8150 nor Ascend.

Try the whole boot.img from um840.

Try 15 libs + qmuxd from your cm7-u8220 (or from the um840 which is the same) as I did...

Link to comment
Share on other sites

Bluetooth also works. Tested on the radio-enabled um840 rom.

- paired to PC;

- transferred text file to phone fine.

Bluetooth is a part of msm7200a radio unit, so it's rather expected. Contrary wifi is a separate chip on board.

Link to comment
Share on other sites

Bluetooth also works. Tested on the radio-enabled um840 rom.

Also noticed that! Nice side effect of enabling RIL :)

Try the whole boot.img from um840.

Try 15 libs + qmuxd from your cm7-u8220 (or from the um840 which is the same) as I did...

just 15 libs + qmuxd results in familiar rild crash

adding ril permissions in ramdisk (u8150 version) leads to E/dalvikvm-gc errors. Rild not crashing anymore, though

did not yet try exchanging whole boot.img

pier, can you build a special compat-kernel: everything as is now in um840-radio, except camera related stuff?

Then, if you add files like mentioned here, you'll have a bluetooth+ril+tether+both-cams rom...

video playback (and, likely as consequence thereof, video recording) is still broken with current roms. Maybe some *omx* need to be borrowed from cm6 (preferably cm6-clean, to avoid any elcair dependency).

Edited by dr.flo
Link to comment
Share on other sites

Guest dtox125

How do you compile CMx against a certain kernel? From my understanding, we just have a prebuilt kernel zimage in the device tree. Exchanging that should not influence the build process at all. It should just be used for the final step where boot image gets assembled. Maybe I'm wrong but.... Please tell me how the kernel version influences the build.

if you wont to compile the rom with the .32 kernel all you need to do is replace the kernel file in the device tree with zimage of .32 and rename that zimage to kernel.and you will compile the rom with .32

and you need to change the line in device_u8220.mk related to modules

Edited by dtox125
Link to comment
Share on other sites

video playback (and, likely as consequence thereof, video recording) is still broken with current roms. Maybe some *omx* need to be borrowed from cm6 (preferably cm6-clean, to avoid any elcair dependency).

Video issue is strange.

As exactly copying all libomx* (case insensitive, i.e both libomx* and libOmx*) from u8150 into our popular cm7.2 rom helped HQ video on YouTube. Same codecs from msm7225 rom, same kernel worked fine there, but not on native environment.

I'd want wifi to be resolved before making combined builds. The last real show stopper.

Our wifi driver and its firmware are there (um840) right out of box - in /system/wifi folder. Same as for Ascend.

The driver insmods just fine.

If replace libhardware_legacy.so from CM6, android starts loading the module just fine. But no scanning results.

Changing wpa_suplicant from CM6 does not help.

Even though init.qcom.rc is from CM7, it's pretty much the same as in CM6, so should layout filesystem for wifi just right, including permissions. Don't know what else to think...

Edited by pier11
Link to comment
Share on other sites

Video issue is strange.

As exactly copying all libomx* (case insensitive, i.e both libomx* and libOmx*) from u8150 into our popular cm7.2 rom helped HQ video on YouTube. Same codecs from msm7225 rom, same kernel worked fine there, but not on native environment.

ok then some other lib... video does not play on any of um840, u8150, ascend

I'd want wifi to be resolved before making combined builds. The last real show stopper.

agree on that. have you tried awext instead of wext when chaning supplicant?

Maybe we need to play with cm7-u8150 vs cm7-u8220 for wifi once again?

side note:

GPS can be made somewhat working with libloc_api* from eclair (or cm6 which is the same). Then it has the same well known GPS icon bug. When using libloc_api* from cm6 source (no rom contains them by default, I could upload them if needed), GPS icon functions perfectly, but toggeling GPS off and back on reboots the phone. This is exactly the same behavior as on cm6. I already tried several libloc_api* of different roms, but none of them did the trick for me on cm6, I assue the same will be the case for um840...

Link to comment
Share on other sites

I see this in logs on first rom load:

E/M4vH263Decoder( 1205): failed to decode video frame.

E/MetadataRetrieverClient( 1205): failed to capture a video frame

E/MediaMetadataRetrieverJNI( 1572): captureFrame: videoFrame is a NULL pointer

W/MediaThumbRequest( 1572): Can't create mini thumbnail for /mnt/sdcard/DCIM/Camera/VID_20120123_081611.3gp

W/ThumbnailUtils( 1572): can not get thumb for /mnt/sdcard/DCIM/Camera/VID_20120123_083604.3gp nativeCreateDrmContent() returned JNI_DRM_FAILURE

It fails to create thumbnails for videos. And they are indeed blank in Gallery.

JNI_DRM_FAILURE - which DRM - it's my own test videos I recorded with on-board camera.

EDIT:

From u8500 spec (=um840 w/o front camera):

SOFTWARE

Operating System: Android 2.1

MultiMedia:

Video format MPEG4, H.263 (3GPP), H.264

DRM: OMA 1.0 full support

With re to wifi, tried with init.qcom.rc from CM6.1, even fresh rom installation - no luck.

Edited by pier11
Link to comment
Share on other sites

merged between cm7-u8220 and cm7-u8150 in attempt to figure how to run wifi. Made it working, but nothing that we did not know already.

Ramdisk was from cm7.2 u8220 in both cases, same .32 kernel.

wifi-fix-for-cm7-u8150.zip

Attached are necessary changes for cm7-u8150 to make wifi work:

- wifi driver kernel module ar6000.ko (system/lib/modules)

- its firmware (system/etc/firmware)

- libhardware_legacy.so making the driver load

- wpa_supplicant

All sourced from cm7.2 u8220 rom.

cm6 and stock froyo roms have different locations for driver and its firmware (system/wifi), but with that in mind it should not matter much.

Link to comment
Share on other sites

merged between cm7-u8220 and cm7-u8150 in attempt to figure how to run wifi. Made it working, but nothing that we did not know already.

I noticed that cm7 for the u8150 uses a wpa_supplicant v5, whereas usually, stock froyo roms use wpa_supplicant v6. There may be additional files depending on wpa_supplicant version. (-> might be not allowed to just exchange wpa_supplicant binary if major versions do not match).

(afaik) Our ar6000.ko supports awext driver interface, not wext. So we need a wpa_supplicant which does the same. Do we?

Maybe zte blade official froyo has useful combination of ar6000.ko and wpa_supplicant?

Link to comment
Share on other sites

u8150 uses broadcom driver, not relevant to us. Same for um840 and Ascent.

Made another experiment:

Base: your cm6-clean (froyo-stable), +kernel 32-compat, ramdisk from cm6.1

whole system/wifi folder were borrowed from um840.

Result: wifi works.

So cm6 in theory holds right tools to fire up wifi.

May be take a closer look at ramdisk differences. (But I run already init.qcom.sh from cm6 in um840 ramdisk, as I reported...)

Edited by pier11
Link to comment
Share on other sites

Guest desalesouche

Did that. Can take pictures on um840 roms with BOTH CAMERAS, camera switching works there!

Unmodified build.prop

Video recording doesn't work but that's another issue (video playback wouldn't work either, as on u8150 rom).

hi, from which rom did you take the libs to put in um840 rom and make both camera work?tried libs from cm6 clean to um840-radio fix rom on huawei u8230...didn't managed

thx

Edited by desalesouche
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.