Jump to content

[DEV][ROM][7.2.] LineageOS 13 (Android 6.0.1) for Huawei Y5


Guest KonstaT

Recommended Posts

Guest KonstaT
10 minutes ago, Mirk43v said:

well, the chinesse one should appear if you type this while phone is in fastboot mode : fastboot boot recovery.img (like Konstat said), the normal one appears when you enter recovery via adb or via buttons

http://www.sorexblog.altervista.org/recovery.php

here is a translation of a huawei with that chinesse whatever, it may be different though... 

Device most definitely shouldn't boot to diagnostics with 'fastboot boot recovery.img'. It certainly doesn't with unlocked bootloader.

That translations is not accurate and it's not even about the same things. See this instead:

 

Edited by KonstaT
Link to comment
Share on other sites

Guest Mirk43v

@KonstaT my bootloader was locked (well not with a code, but it wasn't really unlocked either) when i typed that command (i remember that i typed that command before the oemunlock one, and it worked) so he should be able to do that aswell, that translation looks pretty accurate too, so @otc try those and see what you can do, also be careful not to break anything , because with a locked bootloader and b046 firmware , i don't think you can recover your phone if something goes wrong

 

Edited by Mirk43v
Link to comment
Share on other sites

Guest otc
29 minutes ago, Mirk43v said:

@KonstaT yeah, you're right ( i forgot to specify that) my bootloader was locked when i typed that command , so he should be able to do that aswell, that translation looks pretty accurate too, so @otc try those and see what you can do, also be careful not to break anything , because with a locked bootloader and b046 firmware , i don't think you can recover your phone if something goes wrong

 

I know damn i think nothing will work huawei have to do update or rollback package

Link to comment
Share on other sites

Guest Mirk43v
On 12.05.2017 at 0:23 PM, otc said:

I dont have time to do some if that but i tryed dc unlocker but there is no y560 here only 550 or y5 II

Ohhh... Well then you got only one option left, try what konstat was telling you and see what happens.

Link to comment
Share on other sites

Im messaging to huawei support and they said there is no option to rollback/downgrade but they asked why i need to. Then i said i cant get product id reply was about factory restart which i tryed on both of phones my and brother. Nothing works i said them that i did factory reset few times lets wait for next reply before i do some crazy stuff.

Edited by otc
Link to comment
Share on other sites

  • 2 weeks later...
Guest AbyssD
On 5/4/2017 at 4:40 PM, KonstaT said:

I tried to fastboot boot recovery.img and it says to unlock bootloader first.. So no hope!

 

 

 

Link to comment
Share on other sites

Guest KonstaT
59 minutes ago, Mr_Ige41 said:

Moroo, mul on toi Huawei Y5 II CUN-L21, toimiiks tolla romilla?? :D :)

No. Asked and answered several times already.

Link to comment
Share on other sites

  • 4 weeks later...
Guest macio525

Hi. I try to build LinOS by myself.

1. How to change "ro.product.locale=" before build?

2. After build I got system.new.dat instead of system folder, why?

Link to comment
Share on other sites

Guest KonstaT
12 hours ago, bummer500 said:

Hello! I have a question. I am rooted my HUAWEI CUN-L21 and i want to know that is this rom is working on my phone.

On 5/29/2017 at 5:50 PM, KonstaT said:

No. Asked and answered several times already.

 

12 hours ago, macio525 said:

Hi. I try to build LinOS by myself.

1. How to change "ro.product.locale=" before build?

2. After build I got system.new.dat instead of system folder, why?

1. See https://github.com/LineageOS/android_build/blob/cm-14.1/core/Makefile#L200 & https://github.com/LineageOS/android_build/blob/cm-14.1/target/product/languages_full.mk#L24.

2. That's exactly what you should get. Block-based OTAs has been the default since Android 5.0. See https://source.android.com/devices/tech/ota/block & https://github.com/LineageOS/android_build/commit/517daa6dcd9000110c817128ec56fff6dc45d537.

 

Link to comment
Share on other sites

Guest macio525
5 hours ago, KonstaT said:

Oh, thanks :3

I disable block based ota by this "export BLOCK_BASED_OTA=false"

EDIT:

I flashed my own build and got one problem, LinOS doesn't detect sim card... Why?

Edited by macio525
Link to comment
Share on other sites

Guest KonstaT
7 hours ago, macio525 said:

Oh, thanks :3

I disable block based ota by this "export BLOCK_BASED_OTA=false"

EDIT:

I flashed my own build and got one problem, LinOS doesn't detect sim card... Why?

Because of how Huawei butchered the telephony stack. It was discussed here or CM12.1 thread not that long ago.

Link to comment
Share on other sites

Guest macio525

Then maybe can you update CM14.1 for y560, I can let you 8core, 20gb ram, 1Gbps VPS for this if you want. Because u have that patch ;vv


 

Edited by macio525
Link to comment
Share on other sites

Guest KonstaT
On 6/22/2017 at 7:14 PM, macio525 said:

Then maybe can you update CM14.1 for y560, I can let you 8core, 20gb ram, 1Gbps VPS for this if you want. Because u have that patch ;vv

Thanks for offering. My build machine is certainly struggling with compiling recent Android versions.

I'll see if I get around making a new build this or next week. There's a shtload of CVEs that I should patch in kernel and test for stability, etc.

Link to comment
Share on other sites

Guest kamelot24

es tan dificil encontrar rom para huawei y5 II cun-l03 :(   si alguien tiene conocimiento porfavor decirmelo gracias . y gracias por este rom tambien.

 

Link to comment
Share on other sites

  • 2 weeks later...
Guest MartyDreamy

Hi @KonstaT, I have successfully installed your custom rom. Everyting works fine. But, I found a little issue for the Mobile operator provider name. I'm from Italy, and we have different provider names. I don't know why but instead of showing the correct name (ITim) it shows me 22201 (you can see it on the screenshot)

So...Can you fix it? Ifyou need it, these are all the codes for the italian mobile provider

22210: Vodafone IT

22201: Tim

22288: I Wind

22299:3 ITA

Thank you :D

 

 

Screenshot_20170712-123631.png

Link to comment
Share on other sites

Guest KonstaT
On 7/12/2017 at 2:22 PM, MartyDreamy said:

Hi @KonstaT, I have successfully installed your custom rom. Everyting works fine. But, I found a little issue for the Mobile operator provider name. I'm from Italy, and we have different provider names. I don't know why but instead of showing the correct name (ITim) it shows me 22201 (you can see it on the screenshot)

So...Can you fix it? Ifyou need it, these are all the codes for the italian mobile provider

22210: Vodafone IT

22201: Tim

22288: I Wind

22299:3 ITA

Thank you :D

Already discussed. I can't reproduce this issue with Finnish SIM cards.

Link to comment
Share on other sites

Guest Jookia

Hey! I hate to make a post but it's my last ditch effort - I compiled LineageOS 14.1 with the cm-14.1 branch and the legacymod (I think that's the name) manifest - I get a ROM that boots on the device (I had to tweak it to use the u23 defconfig). However, it has broken sensor rotation, no GPS and no SIM card detection. I spent a while trying to debug this to no avail.

Eventually I decided to flash your ROM + the u23 patch + my boot.img, which gives the same error.
Flashing your ROM + my system.img + the u23 patch (your boot.img included) gives no SIM detection (I didn't check GPS or rotation.)

I think this is the red flag in the log: ?

12-31 15:07:09.137 301 301 E PerMgrLib: modem get service fail
12-31 15:07:09.137 301 301 E PerMgrLib: QCRIL failed to register for modem
12-31 15:07:09.417 402 402 E PerMgrLib: modem get service fail
12-31 15:07:09.417 402 402 E PerMgrLib: QCRIL failed to register for modem

Before I spend a few more days digging in to this, is there something obvious I may be missing? Thanks.

Link to comment
Share on other sites

Guest Jookia

Ok, so after bisecting the system.img since my boot.img seemed to work after I changed a lot of things (I have to fix that) - I managed to get my ROM working by copying telephony-common.jar from yours to mine. GPS doesn't work in either ROM, but sensors works in yours. It seems this is in your kernel. So maybe I'm missing some sources?

As a side note, I decided to run with just the vendor blobs on my phone. Adreno didn't want to work because BoringSSL doesn't have some RSA function, but I solved this by running patchelf on the libEGL/LibGLES libraries that used libcrypto.so and setting the rpath to '/system/vendor/lib/egl/', then copying the stock ROM's libcrypto.so to /system/vendor/lib/egl/ - then I set LD_PRELOAD to load libboringssl-crypto.so . Also had to build stlport. Not much is gained by this, but I figured it'd give me some way to trace where the blobs came from in the first place rather than just github.

Edited by Jookia
Link to comment
Share on other sites

Guest KonstaT
5 hours ago, Jookia said:

Ok, so after bisecting the system.img since my boot.img seemed to work after I changed a lot of things (I have to fix that) - I managed to get my ROM working by copying telephony-common.jar from yours to mine. GPS doesn't work in either ROM, but sensors works in yours. It seems this is in your kernel. So maybe I'm missing some sources?

As a side note, I decided to run with just the vendor blobs on my phone. Adreno didn't want to work because BoringSSL doesn't have some RSA function, but I solved this by running patchelf on the libEGL/LibGLES libraries that used libcrypto.so and setting the rpath to '/system/vendor/lib/egl/', then copying the stock ROM's libcrypto.so to /system/vendor/lib/egl/ - then I set LD_PRELOAD to load libboringssl-crypto.so . Also had to build stlport. Not much is gained by this, but I figured it'd give me some way to trace where the blobs came from in the first place rather than just github.

There's shouldn't be anything broken besides RIL and that's already been discussed here and CM12.1 thread. You probably broke rest yourself messing with the binary blobs!

If you're building directly for U23 there's few things to do. Change this line to use msm8909-y560-u23_defconfig (it's actually dt.img that end up being different between L01/L02/L03 and U23). Add two dual-SIM properties from U23 patch to system.prop. Replace camera blobs in vendor/huawei with the ones in the U23 patch. Don't touch anything else there! Also set SELinux permissive (revert this).

Git history in vendor/huawei tells you where every blob is extracted from. You simply can't run Android 7.1 with 5.1 drivers.

Edited by KonstaT
Link to comment
Share on other sites

Guest Jookia

My bad on the RIL- I didn't search for telephony-common.jar, I figured since LineageOS built it we had the source code and it wasn't pulled from a ROM. That sucks. Is it from a particular device (since it's not noted in the vendor Git history)

Oh I see the Git history now. That's pretty neat! I don't know what to say about not being able to run Android 7.1 with 5.1 drivers. Perhaps this phone I had was Android 6 or 7 already? Because with some patching the Adreno blobs and removing another it works 'fine'. I'll probably update anyway.

Regarding the sensors, doing a fresh install of your ROM with the u23 patch has them work. I flashed my boot.img that I built from the sources using the defconfig and the sensors are now broken. I'm really not sure what's up with that. I seem to need your kernel to have working sensors.

On another note, I do have the device running fine aside from the sensor issue that seems to be a boot.img issue with SELinux enabled. Phone calls and everything work, so I'm a little confused as to why it's disabled, unless it's a userspace thing. If I see breakage I'll just disable it I suppose.

Thanks for your time!

Edited by Jookia
Asking about RIL history
Link to comment
Share on other sites

Guest KonstaT
56 minutes ago, Jookia said:

My bad on the RIL- I didn't search for telephony-common.jar, I figured since LineageOS built it we had the source code and it wasn't pulled from a ROM. That sucks. Is it from a particular device (since it's not noted in the vendor Git history)

Oh I see the Git history now. That's pretty neat! I don't know what to say about not being able to run Android 7.1 with 5.1 drivers. Perhaps this phone I had was Android 6 or 7 already? Because with some patching the Adreno blobs and removing another it works 'fine'. I'll probably update anyway.

Regarding the sensors, doing a fresh install of your ROM with the u23 patch has them work. I flashed my boot.img that I built from the sources using the defconfig and the sensors are now broken. I'm really not sure what's up with that. I seem to need your kernel to have working sensors.

On another note, I do have the device running fine aside from the sensor issue that seems to be a boot.img issue with SELinux enabled. Phone calls and everything work, so I'm a little confused as to why it's disabled, unless it's a userspace thing. If I see breakage I'll just disable it I suppose.

Thanks for your time!

I've reverse engineered Huawei/YEP telephony stack and I'm building telephony-common.jar from source.

I've updated kernel display drivers, display HALs are updated, so display binary drivers should be updated to reflect that as well. GPS not working is because your blobs don't match the updated GPS HAL. Widevine will also be dead with 5.1 blobs. No, there's no update beyond Android 5.1 for this device!

About sensors, check that you've rebuilt the dt.img after changing the defconfig.

SELinux is set permissive because there's still few strange denials that shouldn't be there. Everything should work with enforcing but there also could be some random issues because of it. SELinux has three modes (disabled, permissive, enforcing).

Link to comment
Share on other sites

Guest Jookia

Well, I had fun getting the system to work with 5.1 blobs but I'll switch over to github binaries. I'm okay with having random issues with SELinux since I can always disable it and debug it. :) Also, the device tree not being rebuilt was the reason! Thanks for that. (For anyone reading, make sure to remove the existing l01 device tree in the objects- it notes the filename when building boot.img)

I'm finding the telephony-common.jar not being the source tree a bit of an issue for building from source. I've added it to my vendor tree, so perhaps that'd be a good compromise for now? I understand reverse engineering is messy legal territory, so you probably can't release the source publicly. Might be worth throwing it up encrypted somewhere and giving out the password when you're done maintaining it though.

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.