Development boot.img for SM-A127F and SM-A125F with the touch and MTP fixed - Samsung Galaxy A12

Here is a few boot.img files (tarred for Odin and zipped) intended to be used together with GSI systems (e.g. LineageOS) which suffer from the non-functional touchscreen after the wake-up and the non-functional MTP (USB file transfer). The boot.img files contain the recompiled stock kernel taken from Samsung Open Source with only a couple of the most necessary fixes. 99.9% unaltered, 100% open-source
All credits for the touchscreen fix go to manteiga25, he's done an amazing job on figuring this all out, still from his solution which includes additional performance tweaks I've taken the absolute bare minimum so that the problem is no longer present. Also huge thanks to Osvaldo Costa for the wonderful bootimgtool.
NOTE: If you did not yet flash any non-stock boot.img or recovery.img you may get the bootloop after flashing of any of these files (except for the orig's). That bootloop is caused by bootloader refusing to boot the VB-unsigned kernel together with the rest of the VB-signed components. The only solution (unfortunately) is the full factory reset, so you'll have to lose your user data; everything else, including the GSI will remain intact, but you'll have to set it up from scratch.
UPDATE 01/09/23: added the version based on A127FXXU7CVL2 (Android 13) version of the kernel.
UPDATE 01/11/23: added the fixed kernels for SM-A125F.
UPDATE 03/16/23: added the version based on A127FXXU5BVF3 (Android 12) version of the kernel.
Files for SM-A127F:
boot_sm-a127f-u4_fixed.zip: A127FXXU4AUK1-based kernel, Ilitek ili9881x fix, MTP fix
boot_sm-a127f-u5_fixed.zip: A127FXXU5BVF3-based (Android 12) kernel, Ilitek ili9881x fix, MTP fix
boot_sm-a127f-u7_fixed.zip: A127FXXU7CVL2-based (Android 13) kernel, Ilitek ili9881x fix, MTP fix
orig_boot_sm-a127-u4.zip: the original unaltered A127FXXU4AUK1 boot.img for undo
orig_boot_sm-a127-u5.zip: the original unaltered A127FXXU5BVF3 boot.img for undo
orig_boot_sm-a127-u7.zip: the original unaltered A127FXXU7CVL2 boot.img for undo
src_sm-a127f_fix.zip: all the altered source files
Files for SM-A125F:
boot_sm-a125f-u2_fixed_v1.zip: A125FXXU2BVB4-based kernel, Ilitek ili9881x fix, MTP fix
boot_sm-a125f-u2_fixed_v2.zip: A125FXXU2BVB4-based kernel, Ilitek ili9881x fix, Novatek nt36525 fix, MTP fix
orig_boot_sm-a125-u2.zip: the original unaltered A125FXXU2BVB3 boot.img for undo
src_sm-a127f-fix_v2.zip: all the altered source files
v1 should be easy on battery, but v2 will probably eat more because it basically disables the power saving features of the touchscreen chip (unfortunately that's the only solution at the kernel side).
If you don't trust me or if you're in desperate need of a more recent kernel, here are the steps how to rebuild it all yourself (for SM-A127F on Debian 11):
Download the kernel source from Samsung Open Source (A127FXXU3AUJ5)
Unpack SM-A127F_RR_Opensource.zip and Kernel.tar.gz inside
Unpack SM-A127F_RR_Opensource_A127FXXU4AUK1.zip into the same dir (overwriting the files)
Unpack the attached source.tar.gz, it contains only the changed files and build.sh facilitating compilation
From root: apt install clang-9 gcc-9-aarch64-linux-gnu
Remove any other versions of clang. Then cd /usr/bin; ln -s clang clang-9; ln -s clang++ clang++-9; ln -s clang-cpp clang-cpp-9
Back in the Kernel dir, run build.sh and wait for the kernel to compile
Download bootimgtool and compile it (just "make")
Download the stock firmware
Extract boot.img from AP_A127FXX[...].tar.md5 (unpack using tar, ignore the .md5) to the root dir of your Kernel
bootimgtool disassemble boot.img
cp Kernel/arch/arm64/boot/Image kernel
bootimgtool create -o boot.img
Flash boot.img as is using Heimdall or pack into .tar and flash using Odin
For SM-A125F you'll need to use the Google's patched Clang and GCC instead, and there is no way around that except for lots and lots of additional include paths for the Mediatek drivers (and even that does not guarentee that it will be compiled successfully).

uluruman said:
Here is the boot.img (tarred for Odin) intended to be used together with GSI systems (e.g. LineageOS). It contains the recompiled stock U4 kernel taken from Samsung Open Source with only a couple of the most necessary fixes, namely the freezing touchscreen and the non-functional MTP. 99.9% unaltered, 100% open-source.
All credits for the touchscreen fix go to manteiga25, he's done an amazing job on figuring this all out, still from his solution which includes additional performance tweaks I've taken the absolute bare minimum so that the problem is no longer present. Also huge thanks to Osvaldo Costa for the wonderful bootimgtool.
If you don't trust me here are the steps how to rebuild it all yourself (on Debian 11):
Download the kernel source from Samsung Open Source (A127FXXU3AUJ5)
Unpack SM-A127F_RR_Opensource.zip and Kernel.tar.gz inside
Unpack SM-A127F_RR_Opensource_A127FXXU4AUK1.zip into the same dir (overwriting the files)
Unpack the attached source.tar.gz, it contains only the changed files and build.sh facilitating compilation
From root: apt install clang-9 gcc-9-aarch64-linux-gnu
Remove any other versions of clang. Then cd /usr/bin; ln -s clang clang-9; ln -s clang++ clang++-9; ln -s clang-cpp clang-cpp-9
Back in the Kernel dir, run build.sh and wait for the kernel to compile
Download bootimgtool and compile it (just "make")
Download the stock firmware
Extract boot.img from AP_A127FXX[...].tar.md5 (unpack using tar, ignore the .md5) to the root dir of your Kernel
bootimgtool disassemble boot.img
cp Kernel/arch/arm64/boot/Image kernel
bootimgtool create -o boot.img
Flash boot.img as is using Heimdall or pack into .tar and flash using Odin
Click to expand...
Click to collapse
Amazing work. Love to see developers still working on this device. Does it work with SM-A125F?

Allehandro said:
Amazing work. Love to see developers still working on this device. Does it work with SM-A125F?
Click to expand...
Click to collapse
You can try, it may work, but most likely will bootloop. SM-A125F is based on a Mediatek SoC, SM-A127F is based on Exynos, which has a different kernel config.

uluruman said:
You can try, it may work, but most likely will bootloop. SM-A125F is based on a Mediatek SoC, SM-A127F is based on Exynos, which has a different kernel config.
Click to expand...
Click to collapse
I don't want to risk it as it is my main device and don't want to have to restore the device later on. Thanks though.

I've finally managed to compile the SM-A125F kernel (A125FXXU2BVB4 - SM-A125F_EUR_RR): somehow it turned out to be MUCH harder than that for SM-A127F, as nearly everything there is designed for only one specific toolchain, plus the non-Samsung s_mtp driver did not compile, so I had to take it from A127F's source. Anyway, I've ported the same fixes and here is the experimental boot.img. As I don't have SM-A125F I cannot test it, so I need someone to test it. Also attached is the original U2 boot.img: in case it does not work you just flash the original.

Amazing bro! Mad respect!!!!
I will soon put this baby to the test and see what's made of!!!
I can flash this using ODIN (PDA) directly over the current LOS GSI right?
Also, do you plan to include this kernel in your gsi building script so that the boot img of the gsi will be this one?
One other issue that I seemed to also have in my phone was the proximity sensor was not working e.g. when I was in call the screen would remain on....

axy_david said:
Amazing bro! Mad respect!!!!
I will soon put this baby to the test and see what's made of!!!
I can flash this using ODIN (PDA) directly over the current LOS GSI right?
Also, do you plan to include this kernel in your gsi building script so that the boot img of the gsi will be this one?
One other issue that I seemed to also have in my phone was the proximity sensor was not working e.g. when I was in call the screen would remain on....
Click to expand...
Click to collapse
Yes, flash using Odin. GSI should not be affected in any way. If anything does wrong I've also attached the original A127FXXU4AUK1 boot.img, so that you could revert the changes.
Currently I'm struggling to make the same fixed boot.img for my second phone, which is SM-A325F, and I cannot: even if I just unpack and repack back the same boot.img using any tool, including the Google's official mkbootimg, it causes the bootloop. So all of this is currently experimental.

uluruman said:
Currently I'm struggling to make the same fixed boot.img for my second phone, which is SM-A325F, and I cannot: even if I just unpack and repack back the same boot.img using any tool, including the Google's official mkbootimg, it causes the bootloop. So all of this is currently experimental.
Click to expand...
Click to collapse
This issue is sorted out: one cannot flash a custom boot.img over the signed stock one and don't do the full factory reset afterwards. Only after the factory reset the system boots with the unsigned boot partition. Interestingly enough, Download allows flashing such an image without any warnings (in contrast to flashing up_param.bin) but the system just refuses to boot.

uluruman said:
This issue is sorted out: one cannot flash a custom boot.img over the signed stock one and don't do the full factory reset afterwards. Only after the factory reset the system boots with the unsigned boot partition. Interestingly enough, Download allows flashing such an image without any warnings (in contrast to flashing up_param.bin) but the system just refuses to boot.
Click to expand...
Click to collapse
is it possible to fix the proximity sensor?

axy_david said:
is it possible to fix the proximity sensor?
Click to expand...
Click to collapse
There is no physical proximity sensor in this phone, but with the latest firmware you can normally use the Phone app. Now it normally reacts on touching the top part of the screen with your ear and blanks the screen. The screen does not blank on approaching the screen but only on touching it.

uluruman said:
Here is the boot.img (tarred for Odin) intended to be used together with GSI systems (e.g. LineageOS). It contains the recompiled stock U4 kernel taken from Samsung Open Source with only a couple of the most necessary fixes, namely the freezing touchscreen and the non-functional MTP. 99.9% unaltered, 100% open-source.
If the fixed boot.img does not work for you for some reason, I've also attached the original U4 boot (taken from the SM-A127F_NPB_A127FXXU4AUK1 firmware) so you could revert the changes.
All credits for the touchscreen fix go to manteiga25, he's done an amazing job on figuring this all out, still from his solution which includes additional performance tweaks I've taken the absolute bare minimum so that the problem is no longer present. Also huge thanks to Osvaldo Costa for the wonderful bootimgtool.
If you don't trust me or if you're in desperate need of a more recent kernel, here are the steps how to rebuild it all yourself (on Debian 11):
Download the kernel source from Samsung Open Source (A127FXXU3AUJ5)
Unpack SM-A127F_RR_Opensource.zip and Kernel.tar.gz inside
Unpack SM-A127F_RR_Opensource_A127FXXU4AUK1.zip into the same dir (overwriting the files)
Unpack the attached source.tar.gz, it contains only the changed files and build.sh facilitating compilation
From root: apt install clang-9 gcc-9-aarch64-linux-gnu
Remove any other versions of clang. Then cd /usr/bin; ln -s clang clang-9; ln -s clang++ clang++-9; ln -s clang-cpp clang-cpp-9
Back in the Kernel dir, run build.sh and wait for the kernel to compile
Download bootimgtool and compile it (just "make")
Download the stock firmware
Extract boot.img from AP_A127FXX[...].tar.md5 (unpack using tar, ignore the .md5) to the root dir of your Kernel
bootimgtool disassemble boot.img
cp Kernel/arch/arm64/boot/Image kernel
bootimgtool create -o boot.img
Flash boot.img as is using Heimdall or pack into .tar and flash using Odin
P.S.: the U5 kernel sources are suspicously segregated between RR (rest of the world), EUR, CIS and CIS-SER (Russia). It's quite interesting what are the differences?
Click to expand...
Click to collapse
Can you make one for A127F/DSN U7? (I don't have linux)

just tested on my phone latest U7 or s7???? nevertheless it bootloops

axy_david said:
just tested on my phone latest U7 or s7???? nevertheless it bootloops
Click to expand...
Click to collapse
it only works for u4 currently.

TheWorldYT said:
Can you make one for A127F/DSN U7? (I don't have linux)
Click to expand...
Click to collapse
I will, hold on.

just tested on my phone latest U7 or s7???? nevertheless it bootloops
TheWorldYT said:
it only works for u4 currently.
Click to expand...
Click to collapse
damn, and I can't downgrade, im using A127FXXS7BVK1 the latest update for europe really

axy_david said:
just tested on my phone latest U7 or s7???? nevertheless it bootloops
damn, and I can't downgrade, im using A127FXXS7BVK1
Click to expand...
Click to collapse
same thing.
also:
uluruman said:
I will, hold on.
Click to expand...
Click to collapse
axy_david said:
just tested on my phone latest U7 or s7???? nevertheless it bootloops
damn, and I can't downgrade, im using A127FXXS7BVK1 the latest update for europe really
Click to expand...
Click to collapse
uluruman said he will create one.

axy_david said:
just tested on my phone latest U7 or s7???? nevertheless it bootloops
damn, and I can't downgrade, im using A127FXXS7BVK1 the latest update for europe really
Click to expand...
Click to collapse
Done! ) See the update in the first post.
I've used the A127FXXU7CVL2 version source but it should work anyway because it's also U7-based (anyway there is no alternative - Samsung provides only that U7-based kernel). The only thing that theoretically can be needed is the factory reset: at least with my SM-A325F that was the case of the weird boot loop - the Verified Boot protection being voided (the warranty void bit being set) caused the bootloader to refuse loading the kernel.

uluruman said:
Done! ) See the update in the first post.
I've used the A127FXXU7CVL2 version source but it should work anyway because it's also U7-based (anyway there is no alternative - Samsung provides only that U7-based kernel). The only thing that theoretically can be needed is the factory reset: at least with my SM-A325F that was the case of the weird boot loop - the Verified Boot protection being voided (the warranty void bit being set) caused the bootloader to refuse loading the kernel.
Click to expand...
Click to collapse
Thank you!

uluruman said:
I've finally managed to compile the SM-A125F kernel (A125FXXU2BVB4 - SM-A125F_EUR_RR): somehow it turned out to be MUCH harder than that for SM-A127F, as nearly everything there is designed for only one specific toolchain, plus the non-Samsung s_mtp driver did not compile, so I had to take it from A127F's source. Anyway, I've ported the same fixes and here is the experimental boot.img. As I don't have SM-A125F I cannot test it, so I need someone to test it. Also attached is the original U2 boot.img: in case it does not work you just flash the original.
Click to expand...
Click to collapse
Can u make flashable zip for fix touch and mtp for a125f cause i think it dndt work after flashing only boot.img in twrp,still i found out that the baseband version is still bv5 instead of bv4 i hope you fix that bro because i want to install gsi

uluruman said:
Here is the boot.img (tarred for Odin) intended to be used together with GSI systems (e.g. LineageOS). It contains the recompiled stock U4 kernel taken from Samsung Open Source with only a couple of the most necessary fixes, namely the freezing touchscreen and the non-functional MTP. 99.9% unaltered, 100% open-source.
If the fixed boot.img does not work for you for some reason, I've also attached the original U4 boot (taken from the SM-A127F_NPB_A127FXXU4AUK1 firmware) so you could revert the changes.
All credits for the touchscreen fix go to manteiga25, he's done an amazing job on figuring this all out, still from his solution which includes additional performance tweaks I've taken the absolute bare minimum so that the problem is no longer present. Also huge thanks to Osvaldo Costa for the wonderful bootimgtool.
UPDATE 01/09/23: added the version based on A127FXXU7CVL2 (Android 13) version of the kernel.
If you don't trust me or if you're in desperate need of a more recent kernel, here are the steps how to rebuild it all yourself (on Debian 11):
Download the kernel source from Samsung Open Source (A127FXXU3AUJ5)
Unpack SM-A127F_RR_Opensource.zip and Kernel.tar.gz inside
Unpack SM-A127F_RR_Opensource_A127FXXU4AUK1.zip into the same dir (overwriting the files)
Unpack the attached source.tar.gz, it contains only the changed files and build.sh facilitating compilation
From root: apt install clang-9 gcc-9-aarch64-linux-gnu
Remove any other versions of clang. Then cd /usr/bin; ln -s clang clang-9; ln -s clang++ clang++-9; ln -s clang-cpp clang-cpp-9
Back in the Kernel dir, run build.sh and wait for the kernel to compile
Download bootimgtool and compile it (just "make")
Download the stock firmware
Extract boot.img from AP_A127FXX[...].tar.md5 (unpack using tar, ignore the .md5) to the root dir of your Kernel
bootimgtool disassemble boot.img
cp Kernel/arch/arm64/boot/Image kernel
bootimgtool create -o boot.img
Flash boot.img as is using Heimdall or pack into .tar and flash using Odin
P.S.: the U5 kernel sources are suspicously segregated between RR (rest of the world), EUR, CIS and CIS-SER (Russia). It's quite interesting what are the differences?
Click to expand...
Click to collapse
Please create working flashable zip file for twrp for a125f cause i dont have pc i cant use odin,thank you

Related

[REF][DEV]How to unpack / repack normalboot.img

Hi all, like you know our phone is different from other cause - to flash the kernel - you need to pack it with the ramdisk files and flash it to the phone as normalboot.img.
Some people want try to build a custom kernel but after they obtain the zImage file they are not able to flash it to the phone.
So here is the "HOWTO" to explain what you have to do for unpack/repack normalboot.img.
You need Linux to do this (also a visrtualized distro).
1- download and unzip the attached file;
2- place the normalboot.img file into the tools folder;
3- go in the root folder and do:
Code:
./unpack-all.sh
4- now you have succesfull unpacked your file. You can find the zImage file in the "kernel" folder and the ramdisk files in the "ramdisk" folder.
Basically now you can do all that you want. If you have a custom kernel overwrite the zImage file with your. If you want edit the ramdisk go in the folder called "ramdisk" and mod what you want.
When you finished do:
Code:
./create_boot.img.sh
Now you will find the .tar file ready to be flashed on your phone with odin.
If you are asking yourself "where can i find normalboot.img file?" the answers are:
1- into the PDA.tar of your Firmware;
2- dump it from the phone with:
Code:
dd if=/dev/block/bml7 of=/sdcard/normalboot.img
Bye
Thanks Buddy..
BTW your posts are always very crisp and enlightening. I appreciate.
regards
I tried the script, and it seems to work. Seems, because it unpacked and repacked fine, and I replaced the kernel with a self compiled one. But, to make it short, the phone didn't boot. It was stuck on the "Galaxy S"-screen.
Any ideas, why a kernel which compiled without errors does not boot? Skin, did you change specific settings for compiling your OC-kernel, besides the overclocking adjustments?
XDA_Bam said:
I tried the script, and it seems to work. Seems, because it unpacked and repacked fine, and I replaced the kernel with a self compiled one. But, to make it short, the phone didn't boot. It was stuck on the "Galaxy S"-screen.
Any ideas, why a kernel which compiled without errors does not boot? Skin, did you change specific settings for compiling your OC-kernel, besides the overclocking adjustments?
Click to expand...
Click to collapse
I think that your kernel version doesn't match with the modules... so in your Makefile change the version name to match it with the stock.... so you have to change the version from 2.6.35.7 to 2.6.35.7-CL..... (don't remember if the number are correct)
Thanks, Skin! That did the trick. Now running self compiled vanilla kernel. Interestingly, it is about 200kb bigger than the stock kernel.
EDIT: Obviously, the repack-script is running fine.
other way to do dis is by using kitchen ..
js rename ur normalboot.img to boot.img den replace the boot.img in ur working directory ..
in the kitchen advanced options , unpack/repack boot.img ...
u ll get the same output
this one is easier as we dont need to remember the commands
XDA_Bam said:
Thanks, Skin! That did the trick. Now running self compiled vanilla kernel. Interestingly, it is about 200kb bigger than the stock kernel.
EDIT: Obviously, the repack-script is running fine.
Click to expand...
Click to collapse
To make it smaller you can use the Buildscript used in the froyo version of kernel source... Amit told me it this morning... and it worked greatly
bajju123 said:
other way to do dis is by using kitchen ..
js rename ur normalboot.img to boot.img den replace the boot.img in ur working directory ..
in the kitchen advanced options , unpack/repack boot.img ...
u ll get the same output
this one is easier as we dont need to remember the commands
Click to expand...
Click to collapse
Commands? You can do it with two mouse click!
Skin1980 said:
To make it smaller you can use the Buildscript used in the froyo version of kernel source... Amit told me it this morning... and it worked greatly
Click to expand...
Click to collapse
Yes, works. But my kernel stays at 3.3MB... still 0.2 larger than the stock one.
By the way: Had a SOD with the self-compiled kernel. Screen didn't wake up from standby, but soft buttons were lid. Guess the info from Samsung that closed source software is missing from the package is correct
i still have sod also with the new compilation mod.... by me sammy is missing something or simply the source are not updated like i supposed....
thanks....this rescued me
---------- Post added at 07:50 AM ---------- Previous post was at 07:20 AM ----------
i have a silly doubt
cud i download the linux kernel v3 from korg and compile it for i9003?or do i have to stick with 2.6.35?
Maybe it would be possible. The main problem are the drivers - they would most likely require major changes. But even CyanogenMod is running 2.6.37 and nothing more recent.
If you want to use a newer kernel, you could try that one, or - to minimize problems - use the 2.6.35.14 bugfix release. This seems most reasonable to me.
XDA_Bam said:
Maybe it would be possible. The main problem are the drivers - they would most likely require major changes. But even CyanogenMod is running 2.6.37 and nothing more recent.
If you want to use a newer kernel, you could try that one, or - to minimize problems - use the 2.6.35.14 bugfix release. This seems most reasonable to me.
Click to expand...
Click to collapse
shoot........404 not found
Those hackers...................
you are our phone's God!
Sent from my GT-I9003 using xda premium
i need help, i try to make stock normalboot.img tar with ur files.
but there is a big bug
phono booting but stay at "samsung" screen.
someone have this bug like me and u says that "chance ur kernel version in make boot file" but i cant find how chance kernel version in make boot file. how can i?
ROM: 2.3.6 JVKPB TUR ROM (galaxy sl i9003)
please help...
Skin1980 said:
Hi all, like you know our phone is different from other cause - to flash the kernel - you need to pack it with the ramdisk files and flash it to the phone as normalboot.img.
Some people want try to build a custom kernel but after they obtain the zImage file they are not able to flash it to the phone.
So here is the "HOWTO" to explain what you have to do for unpack/repack normalboot.img.
You need Linux to do this (also a visrtualized distro).
1- download and unzip the attached file;
2- place the normalboot.img file into the tools folder;
3- go in the root folder and do:
Code:
./unpack-all.sh
4- now you have succesfull unpacked your file. You can find the zImage file in the "kernel" folder and the ramdisk files in the "ramdisk" folder.
Basically now you can do all that you want. If you have a custom kernel overwrite the zImage file with your. If you want edit the ramdisk go in the folder called "ramdisk" and mod what you want.
When you finished do:
Code:
./create_boot.img.sh
Now you will find the .tar file ready to be flashed on your phone with odin.
If you are asking yourself "where can i find normalboot.img file?" the answers are:
1- into the PDA.tar of your Firmware;
2- dump it from the phone with:
Code:
dd if=/dev/block/bml7 of=/sdcard/normalboot.img
Bye
Click to expand...
Click to collapse
Wow you are great !!! Loved it .. so easy .... made my dead phone alive .. you are the best \m/

[Q] Unpacking boot.img from Aorths CM10

I wanted to modify one of the kernel init.rc's to switch from nl80211 to wext and help debug the wireless instabilities (can't connect to all of the networks that i frequent).
I found out that these files are inside the ramdisk stored somewhere in the boot.img that is flashed to the boot partition.
So I downloaded the lastest Nov 6th CM10 from aorth (Thanks for all your efforts there!) and tried to unpack the boot.img.
However, the unpack-bootimg.pl/split-bootimg perl scripts that can be found around here fail me.
Taking the file to a hex editor reveals that that is probably expected (no "ANDROID!" header), and i can't find any padded 00000 1F8B myself.
What am I doing wrong? Is it in another format and clockwordmod does something to it before flashing?
Found out it's a zimage. All done. Don't know if my new image works though yet.
If anyone's listening: Turns out that -Dwext does not work. wpa_supplicant says "unknown driver". Might be that wpa_supplicant can't handle it or that the interface just isn't built into the kernel anymore.
As to the zimage:
This tool http://forum.xda-developers.com/showthread.php?t=1294436 works.
Repacked the kernel on an Ubuntu box with the gcc-4.6-arm-linux-gnueabi package as the cross compiler.
Flashed with dd onto mmcblk0p5, which contains the normal boot kernel. (P6200, don't know about any other variants).
i am listening dude, and waiting for your updates. The new driver is not happy with one of my routers, and i would like to use the older one.
Enviado de meu MB525 usando o Tapatalk 2
I re-built the smdk4210 kernel with the cyanogenmod_p6800_defconfig and found WEXT support to be in it.
wpa_supplicant -h reveals that it itself does not support wext. So i figure I should take the wpa_supplicant from an older release (supposedly before Oct 2nd) and see if that helps.
At least on the p6210 the 10/02 release has the old driver.
Enviado de meu MB525 usando o Tapatalk 2
It's done.
So in this archive http://www.quadrant-epsilon.de/cm10-11-06-with-wext.zip you can find the result.
SHA256 eb4dccfe59c141a253c128c8e9f4989573e937c480e6c2f9d5a06186836d10b2 cm10-with-wext.zip
Included is a new boot.img for P6200 and P6210 variants. Kernel is unmodified taken from aorths CM10 Nov 6th archive.
The only change in the boot.img concerns init.smdk4210.rc to have the wpa_supplicant take -Dwext instead of -Dnl80211 as a parameter.
This necessitates an older version of the wpa_supplicant, which I took from aorths CM10 October 2nd archive.
So to install this: Make sure you have some other boot.img ready in case anything goes wrong, in case it wont boot and/or you won't have wireless connectivity anymore.
Transfer the files in the zip to your tab and flash the correct boot.img via console:
dd if=cm10-11-06-p62X0-new.boot.img of=/dev/block/mmcblk0p5
(terrible things might happen if you get that last number wrong, I hope it's correct also for the P6210?)
Save your old /system/bin/wpa_supplicant in case you need to revert to it.
Then overwrite /system/bin/wpa_supplicant with the included wpa_supplicant_new
Reboot.
Note: This is only a nasty workaround for a problem in the wireless driver, the wext driver is deprecated and shouldn't be used anymore. You shouldn't use this if don't have problems with nl80211. For me, this workaround enables me to connect to an older, probably not very standard-conform router that the nl80211 interface can't cope with (yet).
Only tested on the P6200 variant!
Thanks buddy, it worked great. I have flashed the 11/06 cm, flashed the boot.img with mobile odin and replaced the wpa bin. Now my tab and old router are talking.
By the way, do you think it's possible to mount and access the boot partition directly on the tab? I think it would be easier to change that very script.
The boot partition does not contain a normal filesystem, instead it is a kernel image with a built-in initramfs. I don't think there is any filesystem-handler for that even on normal linux boxes, and putting it back together needs an ARM compiler in any case. So it's not easily done on the phone/tablet itself.
nightflier2 said:
Found out it's a zimage. All done. Don't know if my new image works though yet.
Click to expand...
Click to collapse
\o/ I do undestand that bit now. the boot.img IS the the direct file(zImage) to be used with the tool you recommended.
nightflier2 said:
The boot partition does not contain a normal filesystem, instead it is a kernel image with a built-in initramfs. I don't think there is any filesystem-handler for that even on normal linux boxes, and putting it back together needs an ARM compiler in any case. So it's not easily done on the phone/tablet itself.
Click to expand...
Click to collapse
Got it, did all the steps editing the files and recompiling the boot.img and now i am enjoying the new CM version.
Thanks again
For those who can't do it themselves:
Updated boot images for both variants, based on Aorth's Nov 26th build: http://quadrant-epsilon.de/cm10-11-26-with-wext.zip

Is there a Stock Kernel with Safetynet Patch?

I'm looking for a stock kernel that only patches Safetynet checking. Does this exist? If not, is it easy for me to "make it" myself?
I'm not sure if there's a prebuilt one, but building one yourself isn't too hard. The patch is at https://github.com/sultanxda/androi...bc05b16bbd33521c2fffaf491c5657a94bfcfc5.patch. You just follow the steps at http://source.android.com/source/building-kernels.html as usual with the following notes:
Use "kernel/msm" as the source location
Use "marlin_defconfig" as the build configuration
Apply the patch after running the git checkout command
Use the aarch64 prebuilts, not the arm ones
Cares said:
I'm looking for a stock kernel that only patches Safetynet checking. Does this exist? If not, is it easy for me to "make it" myself?
Click to expand...
Click to collapse
Depending on your motivation for a "stock kernel" you might try franco kernel. He doesn't seem to do anything that MIGHT introduce instability or strays very far from stock.
I can vouch for franco. He does minimal performance-only tweaks by default.
josephcsible said:
I'm not sure if there's a prebuilt one, but building one yourself isn't too hard. The patch is at https://github.com/sultanxda/androi...bc05b16bbd33521c2fffaf491c5657a94bfcfc5.patch. You just follow the steps at http://source.android.com/source/building-kernels.html as usual with the following notes:
Use "kernel/msm" as the source location
Use "marlin_defconfig" as the build configuration
Apply the patch after running the git checkout command
Use the aarch64 prebuilts, not the arm ones
Click to expand...
Click to collapse
Hey thanks for the tip. I went ahead and patched the no safetynet patch to the android-msm-marlin-3.18-nougat-mr1 kernel source and compiled it. I now have a Image.gz-dtb file which I zipped (I also just have a binary file named "Image"). What should I with those now, just flash those like I would one of the other kernels? And which file exactly? The gz file? or the just binary file named "Image"?
So essentially "fastboot flash kernel <file_name>"?
When I was compiling I got two warnings by the way:
drivers/soc/qcom/Kconfig:371:warning choice value used outside its choice group
drivers/soc/qcom/Kconfig:376:warning choice value used outside its choice group
Anything I should be concerned about? I've never done this before, but did a lot of reading before I went ahead and used to do some C coding back in the day, so it's not completely unknown to me.
Essentially, these are the steps I followed, after quickly installing Linux Mint:
Code:
Create a working directory in /home/$USER/ (I created /home/sakete/android)
Enter working directory
Download android kernal source
git clone https://android.googlesource.com/kernel/msm
Download prebuilt toolchain
git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9
cd aarch64-linux-android-4.9
export PATH=$(pwd)/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9
export CROSS_COMPILE=$(pwd)/bin/aarch64-linux-android-
export ARCH=arm64
export SUBARCH=arm64
Checkout specific kernel branch for Pixel/PixelXL (be in 'msm' folder)
git checkout android-msm-marlin-3.18-nougat-mr1
Get Safetynet Patch (still be in 'msm' folder)
git fetch https://github.com/sultanxda/android_kernel_oneplus_msm8996 cm-13.0-sultan
git cherry-pick abc05b16bbd33521c2fffaf491c5657a94bfcfc5
Build kernel (still be in 'msm' folder)
make clean
make mrproper
make marlin_defconfig
make -j$(grep -c ^processor /proc/cpuinfo)
I initially got some build errors, but running this command solved it: sudo apt-get install build-essential
This is a useful link for those of you who are interested in doing this as well: http://forum.xda-developers.com/showpost.php?p=69627576&postcount=7108
Hey if you can build it and post it here, that would be awesome. This is exactly what I'm looking for.
It will let me preemptively unlock my Verizon bootloader before flashing the latest OTA, while keeping Android Pay.
Has Google already posted the source for the 7.1.1 update kernel?
The source I pulled (android-msm-marlin-3.18-nougat-mr1) should be what's in the December update. It should be 7.1.1
Sakete said:
Hey thanks for the tip. I went ahead and patched the no safetynet patch to the android-msm-marlin-3.18-nougat-mr1 kernel source and compiled it. I now have a Image.gz-dtb file which I zipped (I also just have a binary file named "Image"). What should I with those now, just flash those like I would one of the other kernels? And which file exactly? The gz file? or the just binary file named "Image"?
Click to expand...
Click to collapse
The Image.gz-dtb file is the one you want.
Sakete said:
So essentially "fastboot flash kernel <file_name>"?
Click to expand...
Click to collapse
I've never done it like that, but that's apparently how Franco's kernel installs, so it's worth a shot I guess. Another way of doing it is to unpack the stock boot image with either pbatard's unmkbootimg or osm0sis's Android Image Kitchen, replace its kernel with your Image.gz-dtb, then repack and flash the new boot.img to the boot partitions.
Sakete said:
When I was compiling I got two warnings by the way:
drivers/soc/qcom/Kconfig:371:warning choice value used outside its choice group
drivers/soc/qcom/Kconfig:376:warning choice value used outside its choice group
Anything I should be concerned about? I've never done this before, but did a lot of reading before I went ahead and used to do some C coding back in the day, so it's not completely unknown to me.
Click to expand...
Click to collapse
Nothing you need to worry about.
josephcsible said:
The Image.gz-dtb file is the one you want.
I've never done it like that, but that's apparently how Franco's kernel installs, so it's worth a shot I guess. Another way of doing it is to unpack the stock boot image with either pbatard's unmkbootimg or osm0sis's Android Image Kitchen, replace its kernel with your Image.gz-dtb, then repack and flash the new boot.img to the boot partitions.
Nothing you need to worry about.
Click to expand...
Click to collapse
Great, thanks, I'll try flashing the kernel tomorrow night and will post it if successful.
Interestingly it seems that Pixel (sailfish) and Pixel XL (marlin) use the same kernel / kernel source? There at least doesn't seem to be a sailfish specific source. Will be interesting to see how it pans out tomorrow.
Sakete said:
Interestingly it seems that Pixel (sailfish) and Pixel XL (marlin) use the same kernel / kernel source? There at least doesn't seem to be a sailfish specific source. Will be interesting to see how it pans out tomorrow.
Click to expand...
Click to collapse
Indeed. The same kernel binary can run on both devices. (The ElementalX and Franco kernels don't even have separate builds for the two.)
Would you mind posting the image you built?
iPwn_ said:
Would you mind posting the image you built?
Click to expand...
Click to collapse
I'm at work now, will post it tonight.
Sent from my Pixel using Tapatalk
Stock Kernel + SafetyNet Patch applied
Well holy crap, it actually worked! Just flashed the kernel, set up android pay no problem! And everything else works just fine too.
Attached is a zip.
Steps to install (make sure you have adb and fastboot set up):
- Download file and unzip
- Reboot into bootloader (power down, hold Power + Volume Down)
- Attach device to computer
- Enter command: fastboot flash kernel <kernel_image>
- Enter command: fastboot reboot
- Disconnect device and wait for it to finish booting. That's it!
You're my hero.
Might be a lot to ask, but it would be dope if you maintained where you update the build every month for Google's latest release.
iPwn_ said:
You're my hero.
Might be a lot to ask, but it would be dope if you maintained where you update the build every month for Google's latest release.
Click to expand...
Click to collapse
I'm creating a thread in the dev section.
Edit: thread is up.
Cares said:
I'm looking for a stock kernel that only patches Safetynet checking. Does this exist? If not, is it easy for me to "make it" myself?
Click to expand...
Click to collapse
A bit late, but just for the record, ElementalX is just like stock with added features. If you don't use those features, you are essentially using the stock kernel.
I am thinking about going this route.. but I am not sure the process to flash a custom kernel on my Pixel.. would anyone be able to walk me through it? thanks!

[ROM+KERNEL]HUAWEI WATCH 2[LTE-Sawshark]+[BT-Sawfish]-[OWDE.180926.001.A1][22-Jan-20]

[HUAWEI WATCH 2 (LTE/4G-Sawshark) & (Bluetooth/BT-Sawfish)-OWDE.180926.001.A1]​INTERNATIONAL VERSION
Please read the instructions and notes before flashing anything. Don't ask me if you don't read the instructions.
Code:
###Disclaimer###
[COLOR="Red"][B]WARNING:
IMPROPER FLASHING MAY POTENTIALLY BRICK YOUR DEVICE. SO PLEASE PROCEED AT YOUR OWN RISK. ME OR ANY OTHER DEVELOPER MENTIONED IN THIS POST WILL ASSUME NO RESPONSIBILITY FOR THIS.[/B][/COLOR]
​
DONATE ME HERE
DONATE-ME
##############################
REQUIREMENT
##############################
- An Unlock bootloader
- Working adb/fastboot and driver - Download from Here
- A custom recovery (twrp) See my twrp thread for custom twrp recovery
TWRP-RECOVERY
##############################
HOW TO FLASH KERNEL/BOOT IMAGE
##############################
- Steps via adb/fastboot
- Unzip the folder and move the boot image into your adb/fastboot folder and apply the following commands
Code:
- adb devices
- adb reboot bootloader
- fastboot flash boot boot.img
- fastboot reboot
##############################
HOW TO FLASH THE ROM AND ROOT
##############################
1- Move the build/ROM and Busybox and Magisk to your watch
2- Make a backup - there's always 1% chance something goes wrong.
3- Full wipe is recommended....Wipe data/Factory reset
4- Flash the ROM, then flash Busybox and Magisk (Please flash in this order, ROM, then Busybox and Magisk)
5- Reboot and complete your initial setting
6- Open Magisk Manager and go to settings and set Automatic Response to Grant
7- Done. Don't forget to donate if you like my work, Thanks.
##############################
ROM AND KERNEL FEATURES [22-Jan-2020]
##############################
[Changelog]-Huawei Watch 2 LTE(Sawshark)+Huawei Watch 2 BT(Sawfish)-[22/Jan/2019]
- Based on latest kernel source (-Source 3.18.24) android-wear with latest security patch
- Linux version 3.18.24 (gcc version 4.9.3 20141215 (prerelease) (UBER-SaberMod-4.9.3_arm-graphite)) #1 SMP PREEMPT Wed Jan 22 9:45:39 CET 2020
- Forced-encryption disabled
- dm-verity removed/disabled
- Auto memory killer set to default
- Sepolicy is patched
- Fix the CPU idle latency unvote timeout. It should reduce the wasting power and CPU go to deep idle states immediately after a request
- Add and use a timer frequency of 100 Hz. It should improve power consumption.
- Add and update/Hide verifiedbootstate from /proc/cmdline in order to fix the failed SafetyNet CTS check(It can still fail through other means)-GOOGLE PAY SHOULD WORK. USE MAGISK TO HIDE ROOT. U may need Gpay enabler
- Remove verifiedbootstate flag from /proc/cmdline - Disable CRC check
- Scheduler optimize/support for heterogeneous multi-core
- Scheduler support for heterogeneous multi-processor systems
- Enable all core with scaling_available_frequencies (200000 400000 533333 800000 1094400 1267200 MHz)- scaling down the frequency of the CPUs to 200 MHz during idl mode and rise the freq. to 1.26Ghz during high pressure.
- Set swappiness to 60
- Change zswap max pool % to 20%. It will reduce CPU usage a lot
- Enable zram & zswap and add 256MB virtual memory default. It will speed up the device a lot
- Removed nolog usage, remove rtb logging from the kernel
- Remove selinux auditing from kernel for lower overhead
- Remove IPC logging from the kernel
- Disabled some kernel parameter to speed up the performance- at the cost of battery/ power consumption
- Remove some logging from several drivers
- Improve memory allocations -Should improve the device a lot
- Add some tweaks to improve the overall speed, apps startup are too faster
- Set zswap compressor to lz4 by default
- APM driver updated again to reduce battery usage during sleeping
- Several other patches to reduce battery usage
- Multi-core scheduler enable/optimized
- APM driver updated reduce battery usage during sleeping
- Fix the wake up time. The screen should wake up more quickly when pressing the button.
- Tweaked the scheduler to reduce/save power by scaling down the frequency of the CPUs or idling them,
- A lot subsystems converted to use power efficient workqueue
- The watch goes to sleep during no action in order to save battery
- Remove debug event logging-Kill the useless logging to reduce overhead
- Remove sync debug entirely to cut down CPU waste in the frame render hot path
- Remove 10 ms CPU idle latency unvote timeout- Doesn't force the CPU to stay out of deep idle states for far longer than necessary, which wastes power
- Disable audit support, usually comes with a measurably significant amount of overhead
- Remove audit dependency
NOTE: THERE IS NO NEED TO FLASH THE LATEST KERNEL IF YOU FLASH THE LATEST ROM.
##############################
DOWNLOAD
##############################
[Huawei Watch 2 4G/LTE]+[Huawei Watch BT][22-Jan]
[DECRYPTION KEY]
WO0FVexxQnrtcODYdmNvnQ
##############################
MAGISK/BUSYBOX/APP-KERNEL-CONTROL
##############################
DOWNLOAD LATEST MAGISK FROM HERE
DOWNLOAD LATEST BUSYBOX FROM HERE
KERNEL CONTROL APP WEAR OS
##############################
How to get the Gpay back...
##############################
1-https://pastebin.com/HKV7cj7H
2-https://forum.xda-developers.com/smartwatch/other-smartwatches/rom-kernel-t3821013/page172
3-https://www.youtube.com/watch?v=UKxGfNxRjo4&t=320s
4-https://forum.xda-developers.com/showpost.php?p=79637148&postcount=1720
##############################
HOW TO FLASH THE STOCK IMAGES-(BACK TO STOCK)
##############################
1- Download and unzip the system image below
2- Attach the watch charger to the watch and plug the USB cord (from the charger) into your computer
3- Use the following adb command to start the watch in fastboot mode: adb reboot bootloader
4- On your computer, navigate to the directory where you unzipped the system image in Step 1. At the top level of that directory, execute the flash-all script:
- On Linux or MacOS, type ./flash-all.sh
- On Windows, type flash-all.bat
5 -DONE. Don't forget to donate if you like my work, Thanks.
STOCK-IMAGES-HUAWEI-WATCH-2-LTE-LEO-DLXX-OWDE.180215.017-SAWSHARK-(13/Oct/2018)
STOCK-IMAGES-HUAWEI-WATCH-2-BT-LEO-BX9-OWDD.180215.018-SAWFISH-(22/7/2018)
##############################
Source/GitHub
##############################
-Source
IF YOU LIKE MY WORK AND WANT ME TO CONTINUE, THEN BUY ME A SHOT OF WHISKY
DONATE ME HERE
DONATE-HERE
Special thanks to:
If you can, donate and respect all the devs and enjoy
@Chainfire for great work in android
@Maxr1998 Big thanks for giving me knowledge and your great work for Asus Zenwatch_3 and your great github guide. Please thank and donate him for all his efforts
@topjohnwu for his great effort (Magisk)Thank you so much
@SuperR.R for the great kitchen
@Xmaster24 for system-less root-
@moneytoo for his great app. Please appreciate and donate him
Pay Enabler
@SuperThomasLab for great tools
Please always support devs and others (soon).​
ROM download asking for decryption key?Can fix the link?
Hello All,
Is it possible to install this latest ROM on model without LTE?
Thank you for reply :good:
arthos7 said:
ROM download asking for decryption key?Can fix the link?
Click to expand...
Click to collapse
Hoffmanns said:
Hello All,
Is it possible to install this latest ROM on model without LTE?
Thank you for reply :good:
Click to expand...
Click to collapse
Link are fixed now. It will properly not gonna work on non-lte. I can build a new for non-lte version if some one send me the latest system image and boot image. (I can extract from your watch via teamviewer, in case you can't) But you need to flash the latest firmware without root.
IF YOU LIKE MY WORK AND WANT ME TO CONTINUE, THEN BUY ME A SHOT OF WHISKY
DONATE ME HERE​
I will upload a complete latest stock images N7176C (lte) incase anyone wanna go back to latest stock again.
The only thing you have to do is boot into bootloader mod and then run the script by double click on it. After some reboots you will be back on latest stock.
I will combine both Linux and Windows together, use one you prefer.
IF YOU LIKE MY WORK AND WANT ME TO CONTINUE, THEN BUY ME A SHOT OF WHISKY
DONATE ME HERE​
Just received my Huawei SW 4G this weekend and after installing Huawei wear I got the alert message that the watch was rooted.
How can I confirm is it's rooted or not.
Thanks
Sent from my ONEPLUS A3003 using Tapatalk
Can anyone who's used this verify that it's notably faster or has improved battery life compared to stock? Or is the difference negligible?
How to build boot.img
Hi Janjan,
I am trying to build a custom kernel for my Huawei Watch 2 (non LTE) and I was wondering if you could share a little of your development work.
How do you actually put the boot image together? I am able to compile the kernel from android-msm-sawshark-3.18-nougat-mr1-wear-release,
which gives me a zImage. I also have the original images. So I tried to unmkbootimg the original boot image and replace the kernel. However, this doesn't seem to work. when I compare the sizes of the supposedly original zImage and the one created from the repository above, their size differs by roughly a factor of 100. So there must be something seriously wrong
What steps do you use to create the kernel and the boot image?
I also checked your github code and tried to use it but it seems to depend on other stuff that is not in your repos. Where did you find the code you have in your repos?
Best regards,
Mogli
janjan said:
I can build a new for non-lte version if some one send me the latest system image and boot image. (I can extract from your watch via teamviewer, in case you can't) But you need to flash the latest firmware without root.
Click to expand...
Click to collapse
Does that offer still stand? If yes I am willing to let my watch be used as a test subject.
mogli19 said:
Hi Janjan,
I am trying to build a custom kernel for my Huawei Watch 2 (non LTE) and I was wondering if you could share a little of your development work.
How do you actually put the boot image together? I am able to compile the kernel from android-msm-sawshark-3.18-nougat-mr1-wear-release,
which gives me a zImage. I also have the original images. So I tried to unmkbootimg the original boot image and replace the kernel. However, this doesn't seem to work. when I compare the sizes of the supposedly original zImage and the one created from the repository above, their size differs by roughly a factor of 100. So there must be something seriously wrong
What steps do you use to create the kernel and the boot image?
I also checked your github code and tried to use it but it seems to depend on other stuff that is not in your repos. Where did you find the code you have in your repos?
Best regards,
Mogli
Click to expand...
Click to collapse
Sure, tell me what you did and your steps for building zImage + modul. I am away from my office for a while.
janjan, have you had success with making a non-lte version?
cdkg said:
janjan, have you had success with making a non-lte version?
Click to expand...
Click to collapse
If you send me the latest boot.img, system.img and vendor.img then I will definitely make.
janjan said:
If you send me the latest boot.img, system.img and vendor.img then I will definitely make.
Click to expand...
Click to collapse
I have the boot.img and system.img. Is there a tutorial or any instructions you could give on how to get the vendor.img?
janjan said:
Sure, tell me what you did and your steps for building zImage + modul. I am away from my office for a while.
Click to expand...
Click to collapse
Hi Janjan,
(Apparently I am not allowed to post links yet, so I am trying my best to explain without them)
1. I got the source code for the Sawshark watch from github (mr1-wear-release). I guess there is no dedicated Seafish kernel source. Short question: There is a choice of 3 different kernel codes. Which one shall I take?
2. I tried to compile this source code without changes (to rule out errors before I make modifications). This works and I get as zImage. What do you mean by modul though? I thought zImage was the only product.
3. Using unmkbootimg, I un-packed an stock boot.img. The unmkbootimg tool says that the boot.img has been compiled with a non-standard mkbootimg program. However the offsets and other values (I am supposed to tune when I use mkbootimg) are contradicting. Eventually, the "non-custom" values recommended by unmkbootimg caused errors in mkbootimg and I ended up using the default values. This worked.
4. When I flash the resulting boot.img my watch gets stuck during boot with the Huawei logo on all the time.
To verify my tools, I tried step 3. in two more ways:
3.1. re-pack the un-packed boot.img, flash it (no errors and boot works)
3.2 pack a boot.img using a zImage obtained from a sawshark boot.img (instead of the seafish). This also worked and boot was successful
I have also looked at the boot.img and zImage files in a hex editor. I can locate the beginning of the kernel but not the end. Also if I did, I wouldn't know how to replace the kernel in hex mode But from what I have understood about mkbootimg, this script does not much more than concatenate zImage and ramdisk and add a header. Is this somewhat correct?
Eventually, I need to turn on some currently disabled kernel features (which is why I am doing all of this ). So I am still trying to figure out the right tools and components. And therefore the question: How do you usually build the kernel and how do you pack it into the boot.img. Do you modify the ramdisk when you replace the kernel?
Best,
Mogli
Instructions to modify ramdisk
Hi Janjan,
How do you disassemble and re-assemble the ramdisk?
Wanted to make a few modifications to the ramdisk.cpio.gz. Again, I wanted to try the tools first. So I unpacked and re-packaged the ramdisk without modifications. After flashing the regenerated boot image, my watch goes into recovery mode...
I found these instructions in a tutorial (again, I can't post links yet... sorry):
For disassembly:
Code:
$ mkdir ramdisk_dir
$ cd ramdisk_dir
$ gunzip -c ../ramdisk.cpio.gz | cpio -i
for re-assembly
Code:
$ find . | cpio -o -H newc | gzip > ../newramdisk.cpio.gz
Update to my previous post:
I found my mistake in building the kernel:
Instead of using
Code:
make ARCH=arm CROSS_COMPILE=arm-linux-androidkernel-
I was using
Code:
make ARCH=arm CROSS_COMPILE=arm-linux-androideabi-
mogli19 said:
Hi Janjan,
How do you disassemble and re-assemble the ramdisk?
Wanted to make a few modifications to the ramdisk.cpio.gz. Again, I wanted to try the tools first. So I unpacked and re-packaged the ramdisk without modifications. After flashing the regenerated boot image, my watch goes into recovery mode...
I found these instructions in a tutorial (again, I can't post links yet... sorry):
For disassembly:
for re-assembly
Update to my previous post:
I found my mistake in building the kernel:
Instead of using
I was using
Click to expand...
Click to collapse
It seems much better now. Are you in Windows or Linux? I will post my script and tools once I reach my PC. I am away from my PC right now. It means you destroy something during generating or packaging the boot image. Does you kernel /boot.img work without or before editing the ramdisk?
Update:- seems you are in Linux.
janjan said:
It seems much better now. Are you in Windows or Linux? I will post my script and tools once I reach my PC. I am away from my PC right now. It means you destroy something during generating or packaging the boot image. Does you kernel /boot.img work without or before editing the ramdisk?
Update:- seems you are in Linux.
Click to expand...
Click to collapse
Yes, I am on linux. I found a different approach that works for me now:
Code:
Extract the ramdisk.
$ mkdir ramdisk
$ cd ramdisk
$ gzip -dc ../ramdisk.cpio.gz | cpio -i
# Make any changes necessary (e.g., set ro.secure=0 in default.prop).
# Recreate the cpio archive using the mkbootfs binary produced from building the Android source code
$ cd ..
$ mkbootfs ./ramdisk | gzip > ramdisk-new.gz
You said you were able to turn on all the cores. Can this be done by modifying the ramdisk or how do you do this?
mogli19 said:
Yes, I am on linux. I found a different approach that works for me now:
You said you were able to turn on all the cores. Can this be done by modifying the ramdisk or how do you do this?
Click to expand...
Click to collapse
Did I said? But It can't be done by editing the ramdisk only. You need to add and edit alot (add driver edit cores etc) in kernel sources.
Okay, before anyone flames, I did look everywhere in this thread and cannot find it. Does anyone have the link to the flashing instructions for this rom?
janjan said:
Did I said? But It can't be done by editing the ramdisk only. You need to add and edit alot (add driver edit cores etc) in kernel sources.
Click to expand...
Click to collapse
Oh sorry, I thought I had read this on your feature list I actually looked at this and asked myself if there was a way to make the cpu settings permanent:
https://stackoverflow.com/questions/20221680/android-how-to-force-cpu-core-offlineshut-down-cores

[stock Rom] Blu G-90 G0310WW

Blu G90 device shipped from factory with Android 10
as with other devices from blu they do not have a public download of there roms. So here is the stock rom pulled from the device with SP-Flash tool.
Both the shipped rom build fingerprint
Code:
ro.bootimage.build.fingerprint=BLU/G90/G0310WW:10/QP1A.190711.020/1585383273:user/release-keys
And the ota update from June fingerprint
Code:
ro.system.build.fingerprint=BLU/G90/G0310WW:10/QP1A.190711.020/1592848714:user/release-keys
are in android file host flash-able with spflash tool, if needed.
I know the first thing to have before modifying android is the method to recover from bad edits. So here they are.
Other works will be stored in this same folder.
https://www.androidfilehost.com/?w=files&flid=315927
First stock rom is Dumped to github, If you need or want specific files, without needing to download whole rom.
https://github.com/mrmazakblu/blu_g0310ww_dump
Stock kernel source:
https://github.com/mrmazakblu/Blu_G90_G0310WW_stock_kernal
Device INFO
*******Above links are pulled firmware. Below is an official firmware file, w/ verified images.********
https://www.mediafire.com/folder/ocmvgrcd73bqy/G90
**
.
Bootloader unlock is same as past devices.
1. enable develper options
2. enable OEM unlock , from inside developer options
3. Reboot to bootloader (adb reboot bootloader, or button combo)
4. fastboot flashing unlock
5. Select confirm on device
6. fastboot reboot (causes factory reset)
Flashing GSI
few more steps than Pie devices, but not too complicated.
You will need recent fastboot tools as tested these steps were done with V30.0.4
https://developer.android.com/studio/releases/platform-tools
Verified boot is enabled on device. The verity key is stored into 3 section.
vbmeta.img
vbmeta_system.img
vbmeta_vendor.img
All found in stock rom. Shared in first post.
1. Unlock bootloader. (see last post)
2. Reboot to bootloader to disable verity
Code:
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot --disable-verity --disable-verification flash vbmeta_system vbmeta_system.img
fastboot --disable-verity --disable-verification flash vbmeta_vendor vbmeta_vendor.img
3. Reboot from bootloader to fastboot(new interface for android 10)
Code:
fastboot reboot fastboot
4. flash sysem from "fastbootd"
Code:
fastboot flash system **gsi-system.img**
Use 64 bit AB GSI
5. Wipe data so the new system will work
Code:
fastboot -w
ROOT::
Not yet confirmed yet. Magisk patched_boot has not provided root as of yet.
Currently looking into pre-rooting the system.img, but not success yet.
TWRP;;
https://forum.xda-developers.com/android/development/twrp-twrp-3-4-0-0-blu-g90-g0310ww-t4163497
.
I have been able to edit the stock /system and flash it back to phone.
--I have added adaway host file
--Removed the SIMO app
-- Removed the IGNITE adware app (dti.blu)
--Removed The Verizon Remote SIM lock app
--Removed Blu-Privacy app
--Removed Opera browser app
--Deodexed Rom (rom would not boot past splash screen without this)
Uploaded edited sysem.img to device folder listed in OP.
Flash with same instructions as How to flash GSI
--Attempting to add SU binary makes rom fail to boot. So still no stock rooted.
Maybe soon.
/
Blu released kernel source today. 8-27. The tar.hz is dated April, eh, whatever.
I added the source files to the wip twrp tree, it compiles without error. (Not my normal experience , on first time out with Blu kernel).
But as mentioned before, the twrp will not pack the image correctly. Because of the need for new dtb commands that twrp 9.0 build environment does not accept.
And when building in the twrp 10.0-wip tree, the results have not booted for me yet. (I'm on build attempt 12, or so)
I'm rambling, sorry.
When I repack the twrp using the built kernel, twrp has only blank screen, and adb is active. So kernel is slightly off.
Build did not output separate dtb or dtbo.
Well I confirmed it, the screen on this phone is not the one the kernel is building for.
I compared the defconfig from source, the one that matches the name in build prop, to the one I pulled from /proc. And they are different, and the kernel errors out during build when using right defconfig. So, waiting again for Blu to provide the files.
There does not appear to be any interest in this phone, other than my own.
Well maybe it will catch on
It's been advertised on many mm ore locations than the average BLU phone.
Amazon
Ebay
Walmart
Newegg
Best buy
B&H photo
Time will tell.
mrmazak said:
Well I confirmed it, the screen on this phone is not the one the kernel is building for.
I compared the defconfig from source, the one that matches the name in build prop, to the one I pulled from /proc. And they are different, and the kernel errors out during build when using right defconfig. So, waiting again for Blu to provide the files.
Click to expand...
Click to collapse
Any luck with Blu providing the correct kernel files?
Ivisibl3 said:
Any luck with Blu providing the correct kernel files?
Click to expand...
Click to collapse
Not yet. They acknowledged my email, but as yet have not updated there posted source.
Root is half way achieved.
Factory rom was found. It included a boot-debug.img
When this image is used in boot partition, adb root is allowed.
It is only limited root. Example: blockdev command , used to allow remount / to rw, is not permitted. Bit is start.
Factory flashtool rom shared on Blu developers mediafire page.
Will add link to debug-boot.img soon
added to device folder listed in OP
google information on debug-boot.img
https://source.android.com/compatibility/vts/vts-on-gsi
if you have the stock boot.img, and magisk manager, why cant you patch the boot.img and then disable dm-verity by flashing vbmeta.img/vbmeta_system.img/vbmeta_vendor.img and then flash the boot.img via sp flash tool to give you root access?
aryanhington said:
if you have the stock boot.img, and magisk manager, why cant you patch the boot.img and then disable dm-verity by flashing vbmeta.img/vbmeta_system.img/vbmeta_vendor.img and then flash the boot.img via sp flash tool to give you root access?
Click to expand...
Click to collapse
because magisk init is not starting on a patched image. have no sign on magisk in the any of the logs.
the issue is posted on magisk github issue tracker. no solution as of yet.
mrmazak said:
because magisk init is not starting on a patched image. have no sign on magisk in the any of the logs.
the issue is posted on magisk github issue tracker. no solution as of yet.
Click to expand...
Click to collapse
why this that occurring, because for umidigi devices on android 10 work fine https://community.umidigi.com/forum.php?mod=viewthread&tid=19114 and they also use a mediatek chipset?
aryanhington said:
why this that occurring, because for umidigi devices on android 10 work fine https://community.umidigi.com/forum.php?mod=viewthread&tid=19114 and they also use a mediatek chipset?
Click to expand...
Click to collapse
different brand, so built differant. just like ther are redmi (xiamoi) devices with mtk, but fastboot unlock doe not work, it needs redmi app to unlock. and flash tool not work on all devices with MTK, like amazon fire device , they have mtk and do not work with fastboot unlock, or spflash.
mrmazak said:
I have been able to edit the stock /system and flash it back to phone.
--I have added adaway host file
--Removed the SIMO app
-- Removed the IGNITE adware app (dti.blu)
--Removed The Verizon Remote SIM lock app
--Removed Blu-Privacy app
--Removed Opera browser app
--Deodexed Rom (rom would not boot past splash screen without this)
Uploaded edited sysem.img to device folder listed in OP.
Flash with same instructions as How to flash GSI
--Attempting to add SU binary makes rom fail to boot. So still no stock rooted.
Maybe soon.
/
Click to expand...
Click to collapse
which steps did you take to modify the stock /system?
aryanhington said:
which steps did you take to modify the stock /system?
Click to expand...
Click to collapse
used superr script to unpack stock super.img and continued to extract system.img
manually went through the extracted system/system/app folder and deleated the aps I did not want (adware// bloate)
used the rom tools option / deodex
then repacked the system.img
aryanhington said:
why this that occurring, because for umidigi devices on android 10 work fine https://community.umidigi.com/forum.php?mod=viewthread&tid=19114 and they also use a mediatek chipset?
Click to expand...
Click to collapse
This is not entirely true.
Many Umidigi phones have been upgraded from 9 to 10. So the partitions would be very similar and considerably easy to root.
But for new phones coming with 10 the story changes. Read the last pages of your link's article. In addition, I know why and effect on Umidigi Power 3 still has limitations on root.
So this BLU G90 is not very different and depends on a lot of experimentation and tests. I believe that the OP is doing a great job mainly taking everything to github and trying to compile the kernel and firmware.
DragonPitbull said:
This is not entirely true.
Many Umidigi phones have been upgraded from 9 to 10. So the partitions would be very similar and considerably easy to root.
But for new phones coming with 10 the story changes. Read the last pages of your link's article. In addition, I know why and effect on Umidigi Power 3 still has limitations on root.
So this BLU G90 is not very different and depends on a lot of experimentation and tests. I believe that the OP is doing a great job mainly taking everything to github and trying to compile the kernel and firmware.
Click to expand...
Click to collapse
can you elaborate what you mean by this?

Categories

Resources