secd extension - Sony Xperia XZ1 Compact Guides, News, & Discussion

Hi,
here is a new secd extension to get Camera working on unlocked phones:
https://www.androidfilehost.com/?fid=962187416754457602
This needs the following selinux policy rule:
Code:
# Allow to preload libta_drm_ext for secd
allow init secd:process { noatsecure };
If the library gets successfully loaded, you should see the following line in logcat:
Code:
Added TA DRM extension to secd
This is all based on Tobias Waldvogel his previous work.

What is it for?

I do not know how to flush the file.
How do I flush it?

[email protected] said:
What is it for?
Click to expand...
Click to collapse
In short, this is basically a "DRM fix" for unlocked bootloader.
PEACH-PIT said:
I do not know how to flush the file.
How do I flush it?
Click to expand...
Click to collapse
This is not a file to flash, rather the files required for building a ROM or to create a flashable zip.
@modpunk: Thanks a lot for this. I saw some time ago that you have included these files in your LOS trees. I was considering to ask to to post these somewhere, but then just decided to wait for your first release. I used these files to build LOS 15.1 from your repo's and (not surprisingly ) camera is working great now. Great job

Make zip for recovery. You are still need to patch your selinux.

Sorry perhaps a silly question, but how can I patch the SeLinux on stock Rom? I m running latest firmware ...12.72 and custom kernel : https://forum.xda-developers.com/xp...nel-sony-xz1-compact-16-january-2018-t3736068
Also magisk 15.3 is installed here on my phone

aikon96 said:
Sorry perhaps a silly question, but how can I patch the SeLinux on stock Rom? I m running latest firmware ...12.72 and custom kernel : https://forum.xda-developers.com/xp...nel-sony-xz1-compact-16-january-2018-t3736068
Also magisk 15.3 is installed here on my phone
Click to expand...
Click to collapse
I am going to upload a fix soon. I tried twice and it seems working fine. No issue with camera and no greenish picture.

@janjan: In your kernel thread, you said that the 'old DRM fix' is still required. Id like to use only this DRM FIX from modpunk.
Any chance of info how to set the policy without compiling a new kernel?

Man, you're insane... Thanks a lot!
And ofc working like a charm on my old X Performance too (latest stock oreo fw)! I'll try it on my XZ2 as soon as I dare to unlock it :good:

I'm think that on XZ2 you will need to patch your secd file, if Sony not rework DRM protect
Sent from my Sony Xperia XZ1 Compact using XDA Labs

russel5 said:
I'm think that on XZ2 you will need to patch your secd file, if Sony not rework DRM protect
Sent from my Sony Xperia XZ1 Compact using XDA Labs
Click to expand...
Click to collapse
Exactly! I've already written a new script based tool for all 2018 devices, not yet released (still under testing) - not rootkernel based!
It'll work on 2016/2017 devices, too!

serajr said:
Exactly! I've already written a new script based tool for all 2018 devices, not yet released (still under testing) - not rootkernel based!
It'll work on 2016/2017 devices, too!
Click to expand...
Click to collapse
Sounds good. Did you tried the old secd on XZ2? Working to find away to include secd and other libs files into a ramdisk.

janjan said:
Sounds good. Did you tried the old secd on XZ2? Working to find away to include secd and other libs files into a ramdisk.
Click to expand...
Click to collapse
The tool is now ready to push patched secd and drmfix libs (tested and working - no bootloop at all), and also patches init.secd.rc at install time (no recovery required).
The tool also performs the patch in the boot.img to inject the new selinux rule to allow LD_PRELOAD-ing!
New OP libs in my X Performance:
Code:
F8131:/ $ pidof /vendor/bin/secd
1034
F8131:/ $ su
F8131:/ # strings /proc/1034/environ | sort
ANDROID_ASSETS=/system/app
ANDROID_BOOTLOGO=1
ANDROID_DATA=/data
ANDROID_ROOT=/system
ANDROID_SOCKET_secd_credmgr_sock=12
ANDROID_SOCKET_secd_devsec_sock=9
ANDROID_STORAGE=/storage
ASEC_MOUNTPOINT=/mnt/asec
BOOTCLASSPATH=/system/framework/QPerformance.jar:/system/framework/core-oj.jar:/system/framework/core-libart.jar:/system/framework/conscrypt.jar:/system/framework/okhttp.jar:/system/framework/legacy-test.jar:/system/framework/bouncycastle.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/telephony-common.jar:/system/framework/voip-common.jar:/system/framework/ims-common.jar:/system/framework/apache-xml.jar:/system/framework/org.apache.http.legacy.boot.jar:/system/framework/android.hidl.base-V1.0-java.jar:/system/framework/android.hidl.manager-V1.0-java.jar:/system/framework/tcmiface.jar:/system/framework/telephony-ext.jar:/system/framework/WfdCommon.jar:/system/framework/oem-services.jar
DOWNLOAD_CACHE=/data/cache
EXTERNAL_STORAGE=/sdcard
[B][COLOR="Blue"]LD_PRELOAD=libta_drm_ext.so[/COLOR][/B] << HERE I AM ;)
PATH=/sbin:/system/sbin:/system/bin:/system/xbin:/vendor/bin:/vendor/xbin
SYSTEMSERVERCLASSPATH=/system/framework/services.jar:/system/framework/ethernet-service.jar:/system/framework/wifi-service.jar
In 2016/2017 devices everything works as a charm (sepolicy in ramdisk), but in the 2018 devices (which have treble init, as you know), the last thing that still needs to be tested out, is if the new rule injected into the ramdisk's sepolicy will successfully transition to /sys/fs/selinux/policy at boot time (which seems to be required from now on)!
@nasko_spasko (thanks for all your support!! ) - the only guy helping me out by performing the necessary tests on his unlocked XZ2!

serajr said:
The tool is now ready to push pacted secd and drmfix libs (tested and working - no bootloop at all), and also patches init.secd.rc at install time (no recovery required).
The tool also performs the patch in the boot.img to inject the new selinux rule to allow LD_PRELOAD-ing!
New OP libs in my X Performance:
Code:
F8131:/ $ pidof /vendor/bin/secd
1034
F8131:/ $ su
F8131:/ # strings /proc/1034/environ | sort
ANDROID_ASSETS=/system/app
ANDROID_BOOTLOGO=1
ANDROID_DATA=/data
ANDROID_ROOT=/system
ANDROID_SOCKET_secd_credmgr_sock=12
ANDROID_SOCKET_secd_devsec_sock=9
ANDROID_STORAGE=/storage
ASEC_MOUNTPOINT=/mnt/asec
BOOTCLASSPATH=/system/framework/QPerformance.jar:/system/framework/core-oj.jar:/system/framework/core-libart.jar:/system/framework/conscrypt.jar:/system/framework/okhttp.jar:/system/framework/legacy-test.jar:/system/framework/bouncycastle.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/telephony-common.jar:/system/framework/voip-common.jar:/system/framework/ims-common.jar:/system/framework/apache-xml.jar:/system/framework/org.apache.http.legacy.boot.jar:/system/framework/android.hidl.base-V1.0-java.jar:/system/framework/android.hidl.manager-V1.0-java.jar:/system/framework/tcmiface.jar:/system/framework/telephony-ext.jar:/system/framework/WfdCommon.jar:/system/framework/oem-services.jar
DOWNLOAD_CACHE=/data/cache
EXTERNAL_STORAGE=/sdcard
[B][COLOR="Blue"]LD_PRELOAD=libta_drm_ext.so[/COLOR][/B] << HERE I AM ;)
PATH=/sbin:/system/sbin:/system/bin:/system/xbin:/vendor/bin:/vendor/xbin
SYSTEMSERVERCLASSPATH=/system/framework/services.jar:/system/framework/ethernet-service.jar:/system/framework/wifi-service.jar
In 2016/2017 devices everything works as a charm (sepolicy in ramdisk), but in the 2018 devices (that have init treble, as you know), the last thing that still needs to be tested out, is if the new rule injected into the ramdisk's sepolicy will successfully transition to /sys/fs/selinux/policy at boot time (which seems to be required from now on)!
@nasko_spasko (thanks for all your support!! ) - the only guy helping me out by performing the necessary tests on his unlocked XZ2!
Click to expand...
Click to collapse
This sounds promising and it doesn't open security holes! Well done

I'm see new file secd from xz2 compact it's more difficult that file from xz1 compact, but I'm find what need to patch
Sent from my Sony Xperia XZ1 Compact using XDA Labs

So drm fix is ready for xz2 brothers ?

Pandemic said:
So drm fix is ready for xz2 brothers ?
Click to expand...
Click to collapse
NO!

serajr said:
NO!
Click to expand...
Click to collapse
:crying: how much is the progress then bro @serajr ?!!

Pandemic said:
:crying: how much is the progress then bro @serajr ?!!
Click to expand...
Click to collapse
Let's stop spamming over here (forgive me OP). There are specific XZ2 threads in which you could ask the same question!
But here's your answer: I have no idea!!

russel5 said:
I'm think that on XZ2 you will need to patch your secd file, if Sony not rework DRM protect
Sent from my Sony Xperia XZ1 Compact using XDA Labs
Click to expand...
Click to collapse
Yes sure, I found it diferent and much secured on xa2 , here I done one patch at 01.Apr.2018 http://munjeni.myiphost.com/secd_xa2/ for secd binary but I don't know if I done it right. By comparing secd from tobias and our one from xa2 its much more secured!

Related

[honami][CWM Advanced Edition] PhilZ Touch

Main thread + features + install instructions + dev support
http://forum.xda-developers.com/showthread.php?t=2201860
PhilZ Touch is a CWM Advanced Edition that adds all the features you could ever miss in CWM
It is a well proven recovery for many phones
It also adds a full touch interface a completely configurable GUI
Please give your feedback, what works, and any bug you could encounter
Read the features, and check if you are missing something
Also, do not forget to read about the powerful aroma file manager integration and double tap shortcut
Download links
Last version can be found here:
Sony Xperia Z1 (honami)
http://goo.im/devs/philz_touch/CWM_Advanced_Edition
Click to expand...
Click to collapse
Big credits to @DooMLoRD for his help to rebase on stock kernel
XDA:DevDB Information
[honami][CWM Advanced Edition] PhilZ Touch, a Tool/Utility for the Sony Xperia Z1
Contributors
Phil3759, DooMLoRD, [NUT]
Version Information
Status: Testing
Created 2014-03-29
Last Updated 2014-03-29
hello and thank you.
I have found the file. img I can not find my method for installing or flashed to the files on my Z1.
sorry i use google translation I'm French
Français
bonjour et merci . j'ai bien trouvé le fichier .img mes je ne trouve pas la méthode pour l installer ni pour flashé le fichiers sur mon Z1
Bien cordialement
Xque_31
Envoyé de mon C6903 en utilisant Tapatalk
Phil3759 said:
Main thread + features + install instructions + dev support
http://forum.xda-developers.com/showthread.php?t=2201860
PhilZ Touch is a CWM Advanced Edition that adds all the features you could ever miss in CWM
It is a well proven recovery for many phones
It also adds a full touch interface a completely configurable GUI
Please give your feedback, what works, and any bug you could encounter
Read the features, and check if you are missing something
Also, do not forget to read about the powerful aroma file manager integration and double tap shortcut
Download links
Last version can be found here:
Click to expand...
Click to collapse
hi @Phil3759,
firstly welcome to the Z1 forums!
the kernel image you posted will not boot on any device as it misses the crucial device tree files... here are detailed instructions on how to build bootable kernels for many Xperia device since 2011:
http://forum.xda-developers.com/showthread.php?t=2447310
I have fixed this by integrating the ramdisk with stock FW 290 (android 4.3) so that people can test out this recovery..
download link for fixed image is:
http://d-h.st/Iz2
BTW me and my colleague @Napstar have worked on similar "Advanced recovery" before (it was released some time in late 2011/early 2012):
our sources have also been released quite some time back:
http://forum.xda-developers.com/showthread.php?t=1485829
but i discontinued work on it as i got busy with personal work
I would recommend getting in touch with @Napstar, may be we can collaborate for some bigger things
also another thing... since I have worked on multi-recoveries in my kernels, i had 4 recoveries in my X10 kernel way back in septmber 2011!!, and since you are actively developing this advanced recovery, do i have your permission to integrate this recovery in my DooMKernel? (I have made my DooMKernel for close to 21 devices from various vendors Sony, HTC, Samsung, Huawei, Kindle, etc; currently I actively support only 4 devices though: Xperia Z1, Z, SP & T)
note to users:
if you want to test out this recovery then you need to HOTBOOT this kernel:
Code:
fastboot boot kernel.img
regards,
DooMLoRD
DooMLoRD said:
hi @Phil3759,
firstly welcome to the Z1 forums!
the kernel image you posted will not boot on any device as it misses the crucial device tree files... here are detailed instructions on how to build bootable kernels for many Xperia device since 2011:
http://forum.xda-developers.com/showthread.php?t=2447310
I have fixed this by integrating the ramdisk with stock FW 290 (android 4.3) so that people can test out this recovery..
download link for fixed image is:
http://d-h.st/Iz2
BTW me and my colleague @Napstar have worked on similar "Advanced recovery" before (it was released some time in late 2011/early 2012):
our sources have also been released quite some time back:
http://forum.xda-developers.com/showthread.php?t=1485829
but i discontinued work on it as i got busy with personal work
I would recommend getting in touch with @Napstar, may be we can collaborate for some bigger things
also another thing... since I have worked on multi-recoveries in my kernels, i had 4 recoveries in my X10 kernel way back in septmber 2011!!, and since you are actively developing this advanced recovery, do i have your permission to integrate this recovery in my DooMKernel?
note to users:
if you want to test out this recovery then you need to HOTBOOT this kernel:
Code:
fastboot boot kernel.img
regards,
DooMLoRD
Click to expand...
Click to collapse
Many thanks for your support
Yes, I looked at your amazing work. TWRP-ifying CWM is just amazing
However, the codes we use diverge too much, but yes, why not, collaboration can be always welcome. It just take a big effort to start so that each one familiarizes with other's code
Obviously you can use and repack any of my files to your wish
I also should added a note that this is a sample for devs to use it at their wish, like I do for Xperia Z. I knew well that it won't boot any stock ROM. Thought it would boot cm-11.0 roms though...
Anything I have to do when compiling to make it at least boot cm-11.0?
If you agree, I will add your recovery.img to goo.im instead of actual one + add full credits in OP
Phil3759 said:
Many thanks for your support
Yes, I looked at your amazing work. TWRP-ifying CWM is just amazing
However, the codes we use diverge too much, but yes, why not, collaboration can be always welcome. It just take a big effort to start so that each one familiarizes with other's code
Obviously you can use and repack any of my files to your wish
I also should added a note that this is a sample for devs to use it at their wish, like I do for Xperia Z. I knew well that it won't boot any stock ROM. Thought it would boot cm-11.0 roms though...
Anything I have to do when compiling to make it at least boot cm-11.0?
If you agree, I will add your recovery.img to goo.im instead of actual one + add full credits in OP
Click to expand...
Click to collapse
well @Napstar is currently working on something new please get in touch with him, he is busy with his PhD work but I am sure he can find out some time
it wont even boot on any Z1 irrespective of ROM... actually the kernel formats for Sony devices vary A LOT! they are not using standard boot.img format... and anyways especially for the msm8974 board (and beyond) the new device tree format will be used... its a bit tricky to explain but Krab has a good tutorial here:
http://forum.xda-developers.com/showthread.php?t=2469421
sure go ahead... u can link the recovery.img where ever u want i just repacked ur ramdisk with the correct zImage & dt.img
Phil3759 said:
Many thanks for your support
Yes, I looked at your amazing work. TWRP-ifying CWM is just amazing
However, the codes we use diverge too much, but yes, why not, collaboration can be always welcome. It just take a big effort to start so that each one familiarizes with other's code
Obviously you can use and repack any of my files to your wish
I also should added a note that this is a sample for devs to use it at their wish, like I do for Xperia Z. I knew well that it won't boot any stock ROM. Thought it would boot cm-11.0 roms though...
Anything I have to do when compiling to make it at least boot cm-11.0?
If you agree, I will add your recovery.img to goo.im instead of actual one + add full credits in OP
Click to expand...
Click to collapse
here is a bonus for you...
build tools for honami...
http://d-h.st/Vk3
just extract the archive, replace the ramdisk.cpio.gz with new compressed ramdisk and run makeit.sh
that should build a bootable boot.img for Z1 (honami)
DooMLoRD said:
here is a bonus for you...
build tools for honami...
http://d-h.st/Vk3
just extract the archive, replace the ramdisk.cpio.gz with new compressed ramdisk and run makeit.sh
that should build a bootable boot.img for Z1 (honami)
Click to expand...
Click to collapse
That's a lot
I will take a look at it or maybe just provide recovery.zip installer so that interested devs can repack, or even the ramdisk
Huge thanks
I will get in touch with Napster :good:
DooMLoRD said:
here is a bonus for you...
build tools for honami...
http://d-h.st/Vk3
just extract the archive, replace the ramdisk.cpio.gz with new compressed ramdisk and run makeit.sh
that should build a bootable boot.img for Z1 (honami)
Click to expand...
Click to collapse
I took a look at your script
I was aware of the dt.img and already use it for Note 3 and Note 10.1 2014 from Samsung and on many of the new LG devices
Actually, cm-11.0 build tree is fixed to use a custom bootimg make file:
https://github.com/CyanogenMod/android_device_sony_rhine-common/blob/cm-11.0/custombootimg.mk#L56
The dt.img is kernel specific and is built along the zImage as you surely know. When compiling cm-11.0 boot.img, the zImage and matching dt.img are compiled and repacked using custombootimg.mk
Unpacking your fixed recovery.img I see the only changes are the dt.img and zImage to be able to use with stock ROMs. That's great and most people would prefer it that way
However, I am still unsure why you say that my original release won't boot a cm-11.0 ROM? Is it mandatory to have the kernel built along the ROM ? I do not think else your repack with zImage would work only on one specific ROM
Hope you can enlighten me on that
Phil3759 said:
I took a look at your script
I was aware of the dt.img and already use it for Note 3 and Note 10.1 2014 from Samsung and on many of the new LG devices
Actually, cm-11.0 build tree is fixed to use a custom bootimg make file:
https://github.com/CyanogenMod/android_device_sony_rhine-common/blob/cm-11.0/custombootimg.mk#L56
The dt.img is kernel specific and is built along the zImage as you surely know. When compiling cm-11.0 boot.img, the zImage and matching dt.img are compiled and repacked using custombootimg.mk
Unpacking your fixed recovery.img I see the only changes are the dt.img and zImage to be able to use with stock ROMs. That's great and most people would prefer it that way
However, I am still unsure why you say that my original release won't boot a cm-11.0 ROM? Is it mandatory to have the kernel built along the ROM ? I do not think else your repack with zImage would work only on one specific ROM
Hope you can enlighten me on that
Click to expand...
Click to collapse
the original boot.img didnt have a dt.img
DooMLoRD said:
the original boot.img didnt have a dt.img
Click to expand...
Click to collapse
really wired as I used the device tree with custom bootimg make file I linked above
I will look at it and thank you for your repack. I added to main goo.im repo
Afternoon chaps,
Just wanted to give this a whirl as i've used your recoveries before, so out of the two which are on the download section, which one should work on 4.2.2, with a locked bootloader?
Cheers m8 an glad you've made it onto the Z1
@Phil3759
For some reason on locked bootloader devices, while the texfat module has been loaded, I'm unable to get philz touch to mount any exFAT sdcard unless I change the extra.fstab line for it from 'auto' to 'texfat' ... any way to get this working normal again?
[NUT] said:
@Phil3759
For some reason on locked bootloader devices, while the texfat module has been loaded, I'm unable to get philz touch to mount any exFAT sdcard unless I change the extra.fstab line for it from 'auto' to 'texfat' ... any way to get this working normal again?
Click to expand...
Click to collapse
The honami version is compiled without minivold support for exfat modules. It will only work with fuse
https://github.com/PhilZ-cwm6/philz_touch_cwm6/blob/cm-11.0/boardconfig/BoardConfig.mk#L520
You can try to use the yuga minivold binary instead. If it is ok and you want to add support it officially with updates, I will do like yuga and enable the exfat flag
hey I have the Xperia T & SP can you create a touch version for them too?
i can be your guinea pig for testing
SP: https://github.com/CyanogenMod/android_device_sony_huashan
T: https://github.com/CyanogenMod/android_device_sony_mint
DooMLoRD said:
hey I have the Xperia T & SP can you create a touch version for them too?
i can be your guinea pig for testing
SP: https://github.com/CyanogenMod/android_device_sony_huashan
T: https://github.com/CyanogenMod/android_device_sony_mint
Click to expand...
Click to collapse
Compiled and opened dedicated threads
Feel free to put your magic if needed :angel:
@Phil3759: The backlight is really very dim on locked bootloader devices... setting that to the max setting doesn't change it all that much either.
Anything I can do to test if it's philz touch causing this?
[NUT] said:
@Phil3759: The backlight is really very dim on locked bootloader devices... setting that to the max setting doesn't change it all that much either.
Anything I can do to test if it's philz touch causing this?
Click to expand...
Click to collapse
I use this path:
Code:
/sys/class/leds/wled:backlight/brightness
Since the repack was done using a stock kernel, not sure if it still matches!
Phil3759 said:
I use this path:
Code:
/sys/class/leds/wled:backlight/brightness
Since the repack was done using a stock kernel, not sure if it still matches!
Click to expand...
Click to collapse
It does still match. It's like the value to it got cut in half...
[NUT] said:
It does still match. It's like the value to it got cut in half...
Click to expand...
Click to collapse
try to set brightness in recovery gui, then:
Code:
adb shell
cat "/sys/class/leds/wled:backlight/brightness"
Post the value here, maybe you're getting some crap because I did not properly escape those ":"
No idea why Sony have such genius ideas in naming their paths
Phil3759 said:
try to set brightness in recovery gui, then:
Code:
adb shell
cat "/sys/class/leds/wled:backlight/brightness"
Post the value here, maybe you're getting some crap because I did not properly escape those ":"
No idea why Sony have such genius ideas in naming their paths
Click to expand...
Click to collapse
Busy with making a system dump on my Z1 now, will do that soon though.
---------- Post added at 12:55 AM ---------- Previous post was at 12:36 AM ----------
Phil3759 said:
try to set brightness in recovery gui, then:
Code:
adb shell
cat "/sys/class/leds/wled:backlight/brightness"
Post the value here, maybe you're getting some crap because I did not properly escape those ":"
No idea why Sony have such genius ideas in naming their paths
Click to expand...
Click to collapse
[NUT] said:
Busy with making a system dump on my Z1 now, will do that soon though.
Click to expand...
Click to collapse
Done that:
Code:
~ # cat "/sys/class/leds/wled:backlight/brightness"
10
~ # cat "/sys/class/leds/wled:backlight/brightness"
255
First one is from the screen/power save mode, the second is when fully lit... but still the screen is only half as bright or maybe even less then half compared to using the XZ philz ...

Android M Developer Preview for Xperia Z1 [July-04]

Introduction
Hello,
Recently Sony released their source binaries for the Android M Developer Preview, so I decided to build and share it . Keep in mind this is a Developer Preview. It's just to give an idea of how the new Android M looks like. Both the camera and modem aren't included by Sony, so you can't use those.
Click to expand...
Click to collapse
Not included
Modem
Camera
Click to expand...
Click to collapse
Installation instructions
Make a back-up and store it outside of your phone.
Connect the device to your computer in Fastboot mode, by pressing volume up while inserting the USB cable.
In the terminal on your computer type the following commands:
Code:
fastboot flash boot boot.img
Code:
fastboot flash system system.img
Code:
fastboot flash userdata userdata.img
Now when you disconnect your device from the computer and start it, it will be running AOSP.
Click to expand...
Click to collapse
XDA:DevDB Information
AOSP M, ROM for the Sony Xperia Z1
Contributors
aquaboy11
Source Code:
http://developer.sonymobile.com/knowledge-base/open-source/open-devices/list-of-devices-and-resources/
https://android.googlesource.com/platform/manifest/+/android-m-preview
https://github.com/sonyxperiadev/
ROM OS Version: Android M
ROM Firmware Required: C6903
Based On: AOSP
Version Information
Status: Testing
Created 2015-06-26
Last Updated 2015-07-04
good for trying how M looks but hope some one will come with a patch to make modem work... I tried to build it too.. but reposync will take for ever
jos_031 said:
good for trying how M looks but hope some one will come with a patch to make modem work... I tried to build it too.. but reposync will take for ever
Click to expand...
Click to collapse
I don't think anyone wants to port the modem and camera to a Developer Preview. We will have to wait for Sony to do that.
Think the modem is intentionally disabled from the article i read, interesting that its using the 3.4 kernel though, i would have thought 4.x or at least a newer 3.x.. Did not spot a link to the sources(?), i really like the way Sony Ericsson has managed these projects ( the Z series), not only will it benefit us in the future when they eventually deprecate the project, but actually including the community and promoting development rather then hampering it by all means possible, reason enough for me to recommend the series, me like :>
threader said:
Think the modem is intentionally disabled from the article i read, interesting that its using the 3.4 kernel though, i would have thought 4.x or at least a newer 3.x.. Did not spot a link to the sources(?), i really like the way Sony Ericsson has managed these projects ( the Z series), not only will it benefit us in the future when they eventually deprecate the project, but actually including the community and promoting development rather then hampering it by all means possible, reason enough for me to recommend the series, me like :>
Click to expand...
Click to collapse
Oops, I forgot to include the sources . Will add them now .
I tested it, and think it's only more buggy lollipop, which sony/google called "m". Any new features like multiwidow from m preview, API 22 (from 5.1), old lockscreen, lollipop easter egg, and strange android version 5.1.51
Bluetooth sharing gives FC. When Sony give us a full working clear aosp ?
Wysłane z mojego Xperia Z1 przy użyciu Tapatalka
It's not Sony's fault. Google hasn't made the new APIs open source yet. They have just given build instructions for the aosp M preview branch.
I wouldn't recommend using this, as there's absolutely no difference from Lollipop as far as I've seen.
aquaboy11 said:
Oops, I forgot to include the sources . Will add them now .
Click to expand...
Click to collapse
Read trough the build guide.
It's supposed to use the 3.10 kernel. I'm having all sorts of problems with this kernel though, i havent gotten it booting on the device yet.. .Just says missing dtb no matter what i do .. even creating the zImage-dtb trough config or manually results in fastboot saying no dtb...
<project path="kernel/sony/msm" name="kernel" groups="device" remote="sony" revision="aosp/AU_LINUX_ANDROID_LA.BF64.1.2.1_RB1.05.00.02.019.067" />
threader said:
Read trough the build guide.
It's supposed to use the 3.10 kernel. I'm having all sorts of problems with this kernel though, i havent gotten it booting on the device yet.. .Just says missing dtb no matter what i do .. even creating the zImage-dtb trough config or manually results in fastboot saying no dtb...
<project path="kernel/sony/msm" name="kernel" groups="device" remote="sony" revision="aosp/AU_LINUX_ANDROID_LA.BF64.1.2.1_RB1.05.00.02.019.067" />
Click to expand...
Click to collapse
You can try to put the kernel sources into a build environment, i.e., any cm based rom, do build envelope, launch your device, then do mka bootimage and see what happens. But generally, this development has been nothing short of grossly pathetic. Linux now has fully working 4.x kernels. I don't necessarily blame developers primarily, as the main culprits are Sony and Google. However, oems are not more cooperative with linux developers than with android devs, yet linux is ages ahead not only in terms of kernels, os, but also in creating open source firmware...
optimumpro said:
You can try to put the kernel sources into a build environment, i.e., any cm based rom, do build envelope, launch your device, then do mka bootimage and see what happens. But generally, this development has been nothing short of grossly pathetic. Linux now has fully working 4.x kernels. I don't necessarily blame developers primarily, as the main culprits are Sony and Google. However, oems are not more cooperative with linux developers than with android devs, yet linux is ages ahead not only in terms of kernels, os, but also in creating open source firmware...
Click to expand...
Click to collapse
True, replacing the kernel directory and running a script to remake the headers from that kernel used to build android is the way to port android to a new kernel. I'm not building a rom atm though, i'm building the kernel only (bellow). I suspect the 3.10 kernel and newer require an updated bootloader.. However, in what way updating this would affect my ability to boot 4.4.4 i do not know, so im a bit weary.
Code:
ARCH=arm CROSS_COMPILE="$home"/dev/sdk/linaro-gcc-4.9-abe-gnueabihf/bin/arm-none-linux-gnueabihf- make -j8
dtbTool -o dt-0.img -s 2048 -p/scripts/dtc/ arch/arm/boot/ ( changed arch/arm/boot/ to arch/arm/boot/dtb in later kernels)
mkbootimg --cmdline "androidboot.hardware=qcom user_debug=31 maxcpus=2 msm_rtb.filter=0x37 ehci-hcd.park=3 lpj=192598 dwc3.maximum_speed=high dwc3_msm.prop_chg_detect=Y vmalloc=400M" --base 0x00000000 --kernel "$home"/dev/nix/xperia/xperia-c6903-z1-source-final-4.4.4-0/arch/arm/boot/zImage --ramdisk "$home"/nix/xperia/boot-xperia-c6903-z1-sony-kernel-0/157/kernel_S1-SW-LIVE-6732-PID1-0005-MMC.elf.ramdisk --ramdisk_offset 0x02000000 -o boot-0.img --dt dt-0.img --tags_offset 0x01E00000
Also spotted this (Recovery mode now available for a range of unlocked Xperia devices) http://developer.sonymobile.com/201...for-a-range-of-unlocked-xperia-devices-video/ , however, my device (thankfully) runs Customized NCB_1276-9897 ( scandinavia ), so i dont know how well it would take to a UK rom, which has been updated.
As i mentioned before elsewhere, porting to a newer kernel ought be relatively easy, 4.1 would be a natural choice, its LTS and i suspect Android M or so will probably land there..
threader said:
True, replacing the kernel directory and running a script to remake the headers from that kernel used to build android is the way to port android to a new kernel. I'm not building a rom atm though, i'm building the kernel only (bellow).
Click to expand...
Click to collapse
I know you are not building a rom, but my point is it is much better to compile a kernel in a native (to your device) environment with all the tools already there. You also have your native ramdisk, as opposed to some generic one. I have built quite a few kernels using this method and it has yet to fail once...
True, as it stands now, the way im assembling the boot.img it's incompatible with certain installers for Multibot, using the method you described would avoid that entirely.
Spotted the nexus 5 and 7 are on 4.2.2 for android m. I guess 3.10 is just a step.
no links?
OptidroidPlus said:
no links?
Click to expand...
Click to collapse
Downloads tab on XDA Website (not app)...
I see an update...any changes yet? Or is it still lollipop?
drakonizer said:
Downloads tab on XDA Website (not app)...
I see an update...any changes yet? Or is it still lollipop?
Click to expand...
Click to collapse
give me links please? i am new in xda.. thanks
drakonizer said:
Downloads tab on XDA Website (not app)...
I see an update...any changes yet? Or is it still lollipop?
Click to expand...
Click to collapse
No, it's still a buggy Lollipop version. The update just includes the latest commits and changes made to the project.
OptidroidPlus said:
give me links please? i am new in xda.. thanks
Click to expand...
Click to collapse
http://forum.xda-developers.com/devdb/project/?id=10518#downloads
Thanks!!
Android M Preview 2 is coming ? http://www.droid-life.com/2015/07/09/android-m-developer-preview-2-now-available/
Sent from my Xperia Z1 using Tapatalk
danny19901 said:
Android M Preview 2 is coming ? http://www.droid-life.com/2015/07/09/android-m-developer-preview-2-now-available/
Sent from my Xperia Z1 using Tapatalk
Click to expand...
Click to collapse
I doubt Google is going to update AOSP sources...one can only hope. @aquaboy11 Could you post a changelog of any noticeable difference when you update your builds? Thanks...

[ROM][5.1.1][UB][24-aug]HybridRom Concept EditioN V2.0.1 kernel updated

HybridRom Concept EditioN​
New Z1:
I decided to buy a secondhand Z1, so now I can continue developing. As school is starting again soon I will not be able to do a lot. I will do what I can.
Description:
We all got used to the idea that most stable ROM is a Stock one.
This ROM will prove you otherwise.
This ROM was previously only available for the Xperia ZU, but thanks to @Doom Slayer's new development group it will start spreading to other Xperia devices. Some apps might not be the newest, but they are very stable. Our main priority is making the ROM compatible with other Xperia devices before updating every app. Today we have decided to release the first open beta for the Xperia Z1. There is only one problem we know of so far, which is an issue regarding the rear-facing camera. Sometimes the camera saves corrupt photo's. Video recording, front-facing camera, Snapchat, taking WhatsApp photo's etc. work just fine.
Feel free report bugs and help us squatting them .
Main Futures:
Very fast and responsive ROM based on Z3 aosp concept and GPE libs with amazing battery life and memory management.
Perfect combination of Sony and Google apps.
No bloatware, no adds.
Only 400 megabytes.
Optional modifications.
Installation options:
Feel free to install the rom the way you want to:
Are you an advanced user who'd like to experiment with their phone?
Feel free to install our mod for theme support and kernel for advanced futures.
Change log:
Kernel 24-aug
128kHz and 24bit audio
Fixed fauxsound
V2.0.1:
Fixed zip file
V2:
Updated Sony and Google apps
Removed:Browser,Google Now,Gmail,Viper,Video(support implemented in Album) and some other bloatware.
Fixed Sony Sound Enhancements
Fixed Write To SD Card (I hope so)
Added new weather widget
Bugs:
Flashlight (probably camera related)
Autorotation
Some people might have 5ghz wifi connection problem
Wifi may disconnect during screen off no matter the settings. (This is android problem, not my rom)
The rear-facing camera sometimes saves corrupt photo's
Installation Instruction:
Make sure that your Bootloader is Unlocked.
Boot in TWRP.
Wipe system,data,and both caches.
Flash the ROM.
Reboot device.
Prepare to be amazed.
Mods and fixes, but don't install these kernels on your Z1!
Credits:
@Jozinek for Z3 AOSP Concept
@ATMOSF3AR Z Ultra PSD
XDA:DevDB Information
HybridRom Concept EditioN, ROM for the Sony Xperia Z1
Contributors
aquaboy11, Doom Slayer
ROM OS Version: 5.1.x Lollipop
ROM Kernel: Linux 3.4.x
Based On: Z3 AOSP Concept, Stock and GPE
Version Information
Status: Beta
Current Beta Version: 2.0.1
Beta Release Date: 2016-07-26
Created 2016-07-26
Last Updated 2016-08-24
Reserved
This post can be removed as I jus figured out how to reserve posts using DevDB .
Since ZU and Z1 have similar hardware, I can provide some support as well. @aquaboy11, thank for opening a thread, let's make a cabdy out of that ROM.
A person who will find a way to fix camera will become a member of out dev team.
Also, if you have experience with kernels, then you can try to make a defconfig for my own kernel, which will allow me to bring a kernel as well, kernel with fauxsound, dt2w and etc.
I don't have Z1 on my own unfortunately.
Doom Slayer said:
Since ZU and Z1 have similar hardware, I can provide some support as well. @aquaboy11, thank for opening a thread, let's make a cabdy out of that ROM.
A person who will find a way to fix camera will become a member of out dev team.
Also, if you have experience with kernels, then you can try to make a defconfig for my own kernel, which will allow me to bring a kernel as well, kernel with fauxsound, dt2w and etc.
I don't have Z1 on my own unfortunately.
Click to expand...
Click to collapse
Glad to see that new devs are arriving to our device. But for the dt2w feature on kernel, it's not possible for z1 because of a deepsleep's bug.(i don't think it's possible to correct it).
Nice. I hope it comes to our Z1 Compact
FotoMichi said:
Nice. I hope it comes to our Z1 Compact
Click to expand...
Click to collapse
It's a next device in the to-do list
FotoMichi said:
Nice. I hope it comes to our Z1 Compact
Click to expand...
Click to collapse
I might give it a shot , I'll see what I can do!
Hello, this ROM for which the Xperia version is compatible?
For all codename "honami": Xperia Z1 C6902, C6903, C6906, C6943 ??
Thank you
pickmod said:
Hello, this ROM for which the Xperia version is compatible?
For all codename "honami": Xperia Z1 C6902, C6903, C6906, C6943 ??
Thank you
Click to expand...
Click to collapse
C6903 for now, I don't have testers for the others, but I do think I could build it. Send me a pm if you are wanting to test it.
Error while trying to flash the ROM. Error 6 in TWRP.
Also can't fastboot the files inside the zip.
Downloaded this file 3 times already. Am I doing something wrong?
aquaboy11 said:
C6903 for now, I don't have testers for the others, but I do think I could build it. Send me a pm if you are wanting to test it.
Click to expand...
Click to collapse
Count me in as your tester..
Impossible to install for me too. I have E : Error executing updater binary in zip ' /external_sd/hybrid_concept....
nemesisexsp said:
Error while trying to flash the ROM. Error 6 in TWRP.
Also can't fastboot the files inside the zip.
Downloaded this file 3 times already. Am I doing something wrong?
Click to expand...
Click to collapse
benplay said:
Impossible to install for me too. I have E : Error executing updater binary in zip ' /external_sd/hybrid_concept....
Click to expand...
Click to collapse
This should be fixed now.
aquaboy11 said:
This should be fixed now.
Click to expand...
Click to collapse
Nice non it's fixed and aller works smoothly, but how can we change dpi? Can we flash universal path? I don't underground the système ui thing you said on Xperia zu post#2
benplay64 said:
Nice non it's fixed and aller works smoothly, but how can we change dpi? Can we flash universal path? I don't underground the système ui thing you said on Xperia zu post#2
Click to expand...
Click to collapse
To change the doing you need to edit the build.prop. Open it up with any build.prop editing app and look for ro.sf.lcd_density, just typing lcd in search should be enough. Adjust the dpi to your liking, save and reboot.
For the universal path, I think you should be able to just flash it. If it doesn't work, then just reflash the rom and you'll be good to go. Be sure to tell us if it doesn't work.
aquaboy11 said:
To change the doing you need to edit the build.prop. Open it up with any build.prop editing app and look for ro.sf.lcd_density, just typing lcd in search should be enough. Adjust the dpi to your liking, save and reboot.
For the universal path, I think you should be able to just flash it. If it doesn't work, then just reflash the rom and you'll be good to go. Be sure to tell us if it doesn't work.
Click to expand...
Click to collapse
Downloading and will flash on a moment. Will let you know how it goes...
Edit:all is working like a charm! Applied a whole layers theme (prime), no bootloops or any other issues... PexoCam is not working though, will try some more cam mods and report wonderful job guys! Thank you so much!
Okay so I don't think I will try advanced path because inside there is a zu system ui.apk so it will probably not work. But I saw that substratum have just been put to Google play store. Can we use it or it needs to add pluggins in the rom?
benplay64 said:
Okay so I don't think I will try advanced path because inside there is a zu system ui.apk so it will probably not work. But I saw that substratum have just been put to Google play store. Can we use it or it needs to add pluggins in the rom?
Click to expand...
Click to collapse
I tried it a while ago and it does not seem to work. The app FCs when trying to open a theme.
benplay64 said:
Okay so I don't think I will try advanced path because inside there is a zu system ui.apk so it will probably not work. But I saw that substratum have just been put to Google play store. Can we use it or it needs to add pluggins in the rom?
Click to expand...
Click to collapse
It will work.
UI is actually from Z3 and it's working on Ultra.
Why it won't work with on Z1?
Only thing is changed is dpi, which can be done in build.prop.
Btw if u applying themes, apply framework for Android M!

[KERNEL][MOD] Sony Stock Patcher for Xperia X Performance

Code:
#include <std_disclaimer.h>
/*
* Your warranty is now void.
*
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at me for messing up your device, I will laugh at you.
*/
About the project
Sony Stock Patcher is a minimal and easy transition from Sony's Stock ROM
(flashed directly from an FTF for example) to a modifiable ROM that can be modded as you like.
Built out of my evolutions of libbootimg for MultiROM to support Sony ELF bootimages,
a custom modified kernel based on Sony's copyleft with a minimal set of needed custom changes,
and an automated installation process to patch completely a Stock ROM,
this will allow you to use the Stock ROMs as you wish to.​
Relevant features of Sony Stock Patcher
Using my Sony ELF 64bits port to libbootimg, Stock boot partition is automatically converted
Modified copyleft Stock kernel to support alterations and remove limitations
Patches the ramdisk to disable automatically Sony RIC security
Patches the fstab automatically for verity
Injects my init_sony project used on Sony custom ROM projects
Supports making the ROM usable as secondary MultiROM
List of changes made to the kernel
Disable Selinux trap security (allows to boot with stock ramdisk sepolicies)
Disable Device-Mapper verity (needed for example to patch system partitions)
Disable kernel modules forced validation (avoids failures on modules signature)
Disable coresight (unneeeded and irrelevant, just to avoid unsupported error logs)
Disable Sony RIC security (needed to use a recovery and alter /system, /data, ...)
Inline kernel modules compilation (to avoid kernel installation fragmentation)
Clearpad touchscreen updates for MultiROM UI
Minor kernel updates
Installation
Needed: Device has to be with an Unlocked Bootloader
Use Stock ROM or flash a clean FTF ROM from Nougat or Marshmallow
Needs a working TWRP flashed into the FOTA partition (fastboot flash recovery...)
> Fully working TWRP builds : https://mega.nz/#F!DtsERIzb!OFINTFpTQ6CF85alkcIpgA
Boot to TWRP (Power and Volume -)
Flash the relevant sony_stock_xperformance_patcher: n for 7.x or m for 6.0
(Optional) Flash SuperSU by Chainfire if you want to have root access
Reboot to Android
Reasons to use this project ?
Unlocked Bootloader customizations allowed on Stock
Converts the bootimage to support systemless tools
Ability to root with tools like SuperSU
Retains the original Sony bootimage files
Minimal needed changes, no additional kernel mods
Downloads (Unlocked Bootloader only)
Xperia X Performance : https://mega.nz/#F!ClMRQZaT!vY2aFhVHlGqnqkgJZyDOrQ​
Source code
Kernel sources - https://github.com/AdrianDC/kernel-sony-copyleft (branch 41.2.A.7.xxx)
libbootimg sources - https://github.com/AdrianDC/multirom_libbootimg (branch master)
init_sony sources - https://github.com/AdrianDC/device-sony-common-init (branch master)
MultiROM sources - https://github.com/AdrianDC/multirom_core (branch master)
TWRP sources - https://github.com/AdrianDC/twrp_development_sony/commits/device_sony_dora (branch device_sony_dora)​
Sony Stock Patcher for Xperia X Performance created also thanks to :
- Sony for their original copyleft kernel sources
- Tasssadar for the original libbootimg / MultiROM sources
- The XperiaMultiROM team for our evolution of MultiROM
- Everyone involved in testing it​
XDA:DevDB Information
Sony Stock Patcher for Xperia X Performance, Kernel for the Sony Xperia X Performance
Contributors
Adrian DC
Source Code: https://github.com/AdrianDC/kernel-sony-copyleft
Kernel Special Features:
Version Information
Status: No Longer Updated
Created 2016-12-29
Last Updated 2020-08-15
Reserved
Changelog
Code:
Sony Stock Patcher for X Performance - 23/10/2019
=================================================
* Update release to resolve 3.18 ramoops (o_v7.2.157)
> See commit 71d1aa14bdae1f38a56be10468556d43f108478a
Sony Stock Patcher for X Performance - 08/09/2018
=================================================
* Upgrade to Oreo 8.0.0 41.3.A.2.149/157 (o_v6.2.157)
Sony Stock Patcher for X Performance - 19/05/2018
=================================================
* Upgrade to Oreo 8.0.0 41.3.A.2.128 (o_v5.2.128)
Sony Stock Patcher for X Performance - 24/03/2018
=================================================
* Upgrade to Oreo 8.0.0 41.3.A.2.99 (o_v4.2.99)
Sony Stock Patcher for X Performance - 12/03/2018
=================================================
* Upgrade to Oreo 8.0.0 41.3.A.2.75 (o_v3.2.75)
Sony Stock Patcher for X Performance - 25/12/2017
=================================================
* Upgrade to Oreo 8.0.0 41.3.A.2.24 (o_v2.2.24)
Sony Stock Patcher for X Performance - 17/12/2017
=================================================
* Upgrade to Oreo 8.0.0 41.3.A.0.401 (o_v1.0.401)
Sony Stock Patcher for X Performance - 26/11/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.7.76 (n_v12.7.76)
Sony Stock Patcher for X Performance - 25/09/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.7.65 (n_v11.7.65)
Sony Stock Patcher for X Performance - 19/08/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.7.53 (n_v10.7.53)
Sony Stock Patcher for X Performance - 16/07/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.7.35 (n_v9.7.35)
Sony Stock Patcher for X Performance - 08/06/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.7.8 (n_v8.7.8)
Sony Stock Patcher for X Performance - 21/05/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.2.223 (n_v7.223)
Sony Stock Patcher for X Performance - 26/04/2017
=================================================
* Upgrade to Nougat 7.1.1 41.2.A.2.199 (n_v6.199)
Sony Stock Patcher for X Performance - 16/03/2017
=================================================
* Upgrade to Nougat 7.0 39.2.A.0.442 (n_v5.442)
Sony Stock Patcher for X Performance - 04/02/2017
=================================================
* Upgrade to Nougat 7.0 39.2.A.0.417 (n_v4.417)
Sony Stock Patcher for X Performance - 13/01/2017
=================================================
* Minor fix for enforcing SELinux (n_v3.361, m_v3.297)
Sony Stock Patcher for X Performance - 08/01/2017
=================================================
* Remove permissive for Stock 7.0 (n_v2.361, 39.2.A.0.361)
* Remove permissive for Stock 6.0, to fix WiFi (m_v2.297, 35.0.A.1.297)
Sony Stock Patcher for X Performance - 29/12/2016
=================================================
* Initial release for Stock 7.0 (n_v1, 39.2.A.0.361)
* Initial release for Stock 6.0 (m_v1, 35.0.A.1.297)
@Adrian DC Congrats buddy!!
This is absolutely amazing. Confirmed that it is working on my XP with stock MM firmware (35.0.A.1.297).
I need to say that I was afraid of losing all my data due "encryptable" flag, but they were preserved.
Recovery working flawlessly on both ways to enter on it (combo-keys with device turned off, or normal boot with volume + key press).
But I have a question regarding whole process, is Permissive mandatory (# Inject the permissive cmdline)?
Edit.: It looks like it is, but Permissive does break device's wifi connectivity (and maybe other things)!! Is there a way to set Permissive only if we choose to boot up into recovery?
Also, I'm creating a script to do the same! Gonna try it out.
Edit 2: Done, script is working like a charm!
serajr said:
@Adrian DC Congrats buddy!!
This is absolutely amazing. Confirmed that it is working on my XP with stock MM firmware (35.0.A.1.297).
Click to expand...
Click to collapse
Thanks, glad it works fine for you too
serajr said:
But I have a question regarding whole process, is Permissive mandatory (# Inject the permissive cmdline)?
Edit.: It looks like it is, but Permissive does break device's wifi connectivity (and maybe other things)!! Is there a way to set Permissive only if we choose to boot up into recovery?
Click to expand...
Click to collapse
Nice catch, I had forgotten I had an issue 2 months ago on M with WiFi not working entirely,
and it's not an issue that can be found on Nougat so left it aside for the time.
It is indeed related to permissive, and with the recent changes I made for the Nougat support,
permissive is actually totally useless, therefore I made a new release for both M / N with updated kernel & no permissive changes.
Tested both situations with Stock M and Stock N, all works fine.
Adrian DC said:
Nice catch, I had forgotten I had an issue 2 months ago on M with WiFi not working entirely,
and it's not an issue that can be found on Nougat so left it aside for the time.
It is indeed related to permissive, and with the recent changes I made for the Nougat support,
permissive is actually totally useless, therefore I made a new release for both M / N with updated kernel & no permissive changes.
Tested both situations with Stock M and Stock N, all works fine.
Click to expand...
Click to collapse
Thank you so much Adrian... everyting are working now. You're the one!
Just one thing, getenforce returns Permissive (yet)! Not a problem for me at all, but is that right?
I'm still on MM due development of my xposed framework modules.
serajr said:
Thank you so much Adrian... everyting are working now. You're the one!
Just one thing, getenforce returns Permissive (yet)! Not a problem for me at all, but is that right?
I'm still on MM due development of my xposed framework modules.
Click to expand...
Click to collapse
Thanks.
You patched the v2 on top of v1 ?
I don't share full boot or ramdisk, I modify them, hence better compatibility & less invasive changes,
and the permissive part is no longer touched, hence if you patched it, the kernel cmdline just stayed as it was.
If you want to, just reflash the boot from ftf (Kernel only listed), then reflash the v2.
You can also edit the bootimage with regular tools now that it's converted away from ELF.
And I could also upload you my N & M bootimages flasher if you need, let me know.
Adrian DC said:
Thanks.
You patched the v2 on top of v1 ?
I don't share full boot or ramdisk, I modify them, hence better compatibility & less invasive changes,
and the permissive part is no longer touched, hence if you patched it, the kernel cmdline just stayed as it was.
If you want to, just reflash the boot from ftf (Kernel only listed), then reflash the v2.
You can also edit the bootimage with regular tools now that it's converted away from ELF.
And I could also upload you my N & M bootimages flasher if you need, let me know.
Click to expand...
Click to collapse
No, I didn't! It is somewhere at v2. Weird!!
And now I did it this way:
- Flashed modified stock kernel (tobias.waldvogel's tool: dm-verity, ric, drmfix, and busybox) - Reboot >> Enforcing
- Flashed latest SuperSU - Reboot >> Enforcing
- Flashed modified Sony Stock Patcher v2 (sony_stock_patcher.sh: removed dm-verity and ric related lines) - Reboot >> Permissive
serajr said:
No, I didn't! It is somewhere at v2. Weird!!
And now I did it this way:
- Flashed modified stock kernel (tobias.waldvogel's tool: dm-verity, ric, drmfix, and busybox) - Reboot >> Enforcing
- Flashed latest SuperSU - Reboot >> Enforcing
- Flashed modified Sony Stock Patcher v2 (sony_stock_patcher.sh: removed dm-verity and ric related lines) - Reboot >> Permissive
Click to expand...
Click to collapse
Nice job.
working well with stock
V2 is working with latest kernel
Thank you
Keep updating
serajr said:
No, I didn't! It is somewhere at v2. Weird!!
And now I did it this way:
- Flashed modified stock kernel (tobias.waldvogel's tool: dm-verity, ric, drmfix, and busybox) - Reboot >> Enforcing
- Flashed latest SuperSU - Reboot >> Enforcing
- Flashed modified Sony Stock Patcher v2 (sony_stock_patcher.sh: removed dm-verity and ric related lines) - Reboot >> Permissive
Click to expand...
Click to collapse
Minor update v3, removed a remaining kernel commit that allowed to override the enforcing/permissive status,
in some situations it can cause the permissive status even if not wished, you might be fine now.
Works fine on mine (Enforcing, running 7.0 from my MicroSD & no issue so far).
v2 removed as it almost identical to v3 with this minor removal.
Thank you working good with xz
karrouma said:
Thank you working good with xz
Click to expand...
Click to collapse
Do you mean you're using this directly on an Xperia XZ ? Or used my zip installer & a modified kernel ?
I could apply my patcher on XZ 39.0.A.1.xxx if you're interested and release it after validated test like this thread.
Adrian DC said:
Minor update v3, removed a remaining kernel commit that allowed to override the enforcing/permissive status,
in some situations it can cause the permissive status even if not wished, you might be fine now.
Works fine on mine (Enforcing, running 7.0 from my MicroSD & no issue so far).
v2 removed as it almost identical to v3 with this minor removal.
Click to expand...
Click to collapse
Thank you so much. Everything working as expected with v3! Great job as always!!
Could you please explain some points of the script?
What does "# Inject the cleared DTB" actually do?
Are there changes made into injected kernel to disable sony ric (or the ones into ramdisk only >> "# Patch the Sony RIC")?
serajr said:
Could you please explain some points of the script?
What does "# Inject the cleared DTB" actually do?
Are there changes made into injected kernel to disable sony ric (or the ones into ramdisk only >> "# Patch the Sony RIC")?
Click to expand...
Click to collapse
During the patch, I unpack the bootimage (Original ELF 64 bits or regular Android if already patched once),
do all the necessary changes & repack to regular Android, that just puts back all parts of the bootimage.
The kernel zImage is replaced, injected, inside the bootimage from the one I provide in the zip.
You can look at the kernel sources on GitHub linked in the OP
that hold the kernel patches including the removal of Sony RIC elements.
Adrian DC said:
Do you mean you're using this directly on an Xperia XZ ? Or used my zip installer & a modified kernel ?
I could apply my patcher on XZ 39.0.A.1.xxx if you're interested and release it after validated test like this thread.
Click to expand...
Click to collapse
Used your zip with androplus kernel
karrouma said:
Used your zip with androplus kernel
Click to expand...
Click to collapse
Ok then I can prepare a clean XZ kernel & let you try.
The init_sony is also different for Kagura, I built one a few days ago for an AOSP test, will be part of that.
Can anyone tell me what will be the sequence installation after TWRP to install modification and bring SU?
1st Flash SU
2nd Flash Mod
3rd Flash Androplus kernel
is that Correct?
This project is standalone, and goes on top of your Stock ROM.
Flash the patcher, then flash SuperSU.
After installing the patch I cant boot into recovery.
R_captivate said:
After installing the patch I cant boot into recovery.
Click to expand...
Click to collapse
What Recovery, what version, from where ?
Both my MultiROM and my regular TWRP recoveries work fine for me,
from Power & Volume- keys & from boot with init_sony (Volume+).
Already work. Thanks

[KERNEL REPOSITORY][PIE][DT2W] [G8141:G8142] [Stock Based]

I will be posting my kernel builds here for convenience.
Pre-requisite
Unlocked bootloader with TWRP Recovery installed.
DRM fix must be in place before rebooting to avoid a soft brick.
This DRM patch which was available in sToRm//'s free Xperifix version still works
Features
- Stock based kernel with DT2W enabled.
- Forced encryption disabled.
- Passes Safetynet out of the box.
- Fully working camera (Pie kernel-no DRM fix needed for camera).
- Flashable zip with no need to extract boot.img
- Compatible with any version of Magisk.
Installation
Flash drmpatch.zip then kernel.zip.
You can then flash Magisk if you require it.
Camera doesn't depend on it though.
Flash zip in recovery (don't just extract boot.img as zip has system files to enable DT2W)
Kernel Sources
https://developer.sony.com/develop/open-devices/downloads/open-source-archives
Note. Kernel is compiled as per stock. DT2W is enabled in the DTB, the same parameters as used by the Loire platform.
Downloads
G8141_DT2W-41-kernel.zip
G8142_DT2W-41-kernel.zip
Kernel Requests.
Post the kernel.sin and I will patch it and add it to the OP.
Kernel Requests: View attachment kernel-G8142-205.zip thx !
oneheart said:
Kernel Requests: View attachment 4522264 thx !
Click to expand...
Click to collapse
Added, thanks. Please test and report back (I only own G8141).
shoey63 said:
Added, thanks. Please test and report back (I only own G8141).
Click to expand...
Click to collapse
if i need flash the drmpatch.zip ?
oneheart said:
if i need flash the drmpatch.zip ?
Click to expand...
Click to collapse
Yes, it's required.
it work on G8412 , thx !
How can I update to 205 without losing my data?
SilverGamer_YT said:
How can I update to 205 without losing my data?
Click to expand...
Click to collapse
Flash only system.sin - nothing else. Then boot to recovery and flash drmpatch.zip, kernel.zip and then Magisk if you need it.
Reboot and you are done.
@shoey63
dual sim kernel have a problem with wifi.
wifi is off didn't turn on
karrouma said:
@shoey63
dual sim kernel have a problem with wifi.
wifi is off didn't turn on
Click to expand...
Click to collapse
Kernel itself is unmodified, and ramdisk changes don't touch wifi settings at all. Seems to be a hardware or software problem with Sony sd835 as per various complaints here https://talk.sonymobile.com/t5/Xperia-XZ1-Compact/Wifi-connection-problem/td-p/1315030
Adding to the confusion is that the issue is sporadic, intermittent and apparently device specific. Some users suffer badly, whereas others have no problems.
At any rate, there is nothing I can do about it.
shoey63 said:
Kernel itself is unmodified, and ramdisk changes don't touch wifi settings at all. Seems to be a hardware or software problem with Sony sd835 as per various complaints here https://talk.sonymobile.com/t5/Xperia-XZ1-Compact/Wifi-connection-problem/td-p/1315030
Adding to the confusion is that the issue is sporadic, intermittent and apparently device specific. Some users suffer badly, whereas others have no problems.
At any rate, there is nothing I can do about it.
Click to expand...
Click to collapse
Thank you for you work.
One guy tell me to flash CE1 firmware
I will trt
Hi, thank you for time to do this kernel @shoey63 nice work
Just a little beginner's question ... what is the best kernel for my rom stock (yours ot androplus kernel),
from what I read your kernel is not changed at all ?
Castiglionais said:
Hi, thank you for time to do this kernel @shoey63 nice work
Just a little beginner's question ... what is the best kernel for my rom stock (yours ot androplus kernel),
from what I read your kernel is not changed at all ?
Click to expand...
Click to collapse
For tweaking and double tap to wake - Androplus. For the stability of stock - mine.
shoey63 said:
I will be posting my kernel repacks here for convenience.
Pre-requisite
DRM fix must be in place before rebooting to avoid a soft brick.
This DRM patch which was available in sToRm//'s free Xperifix version still works.
Features
- Pure stock kernel with only ramdisk changes to enable DRM fix plus solve SafetNet and Magisk issues.
- Passes Safetynet out of the box.
- Fully working camera (No green Pic's).
- Flashable zip with no need to extract boot.img
- Compatible with any version of Magisk.
Installation
Flash drmpatch.zip then kernel.zip.
You can then flash Magisk if you require it.
Camera doesn't depend on it though.
Downloads
drmpatch.zip
G8141-205
G8142-205dual
Click to expand...
Click to collapse
sir what extra this forbidden xperifix does?
i mean if i have maple kernel and those 3 files from system.sin, and using @serajr 's modified script of TOBIAS , I create one boot.img file and flash it and flash the drmpatch.zip (given) here by you via twrp...
WILL it work?
i don't have xzp
if okay, plz reply
YasuHamed said:
sir what extra this forbidden xperifix does?
i mean if i have maple kernel and those 3 files from system.sin, and using @serajr 's modified script of TOBIAS , I create one boot.img file and flash it and flash the drmpatch.zip (given) here by you via twrp...
WILL it work?
i don't have xzp
if okay, plz reply
Click to expand...
Click to collapse
Not quite OK. You also need to patch init.environ.rc as per this post https://forum.xda-developers.com/showpost.php?p=74310718&postcount=43
I tried flashing SuperSU 2.79 and 2.82 onto my G8142 which runs oreo but it always results in the phone getting stuck at the Sony logo right after the bootloader unlock warning.
Does the kernel not need to be patched for SU to work?
jianlin3062 said:
I tried flashing SuperSU 2.79 and 2.82 onto my G8142 which runs oreo but it always results in the phone getting stuck at the Sony logo right after the bootloader unlock warning.
Does the kernel not need to be patched for SU to work?
Click to expand...
Click to collapse
You could try this one. It is from M-ROM v1.5, a Chinese rom.
I would flash the kernel.zip again, then the SuperSU.zip then the drmpatch.zip and wipe cache and dalvik and see how you go.
jianlin3062 said:
I tried flashing SuperSU 2.79 and 2.82 onto my G8142 which runs oreo but it always results in the phone getting stuck at the Sony logo right after the bootloader unlock warning.
Does the kernel not need to be patched for SU to work?
Click to expand...
Click to collapse
You must try this version this is created for xperia phones:https://forum.xda-developers.com/attachment.php?attachmentid=4164510&d=1496008012
help
I can not understand the order in which I have to do things
Should I unlock the bootloader and then?
I must install the recovery by adb or first the kernel
I come from samsung and the difficulty here is greater and there is much less information, if someone could help me I would appreciate it. I have the latest version of oreo the .205

Categories

Resources