yashsingh1/xdaforums huggingface dataset:
[Xperia Z3 Compact Android Development] king960:
FizTech kernel

Hi, I modifed stock 23.5.A.1.291 kernel to support f2fs file system etc.

The kernel is EXPERIMENTAL so I need testers.

Features for now:

F2FS support (without encryption)

Disabled sony RIC

SELinux permissive

GPU overclock

Kcal support

IntelliThermal

init.d support

Multirom works using no-kexec workaround (WIP kexec-hardboot)

DIRTY COW exploit patched!

Both f2fs and ext4 partitions support

Custom CPU govenors

Custom ZEN I/O scheduler as requested

Adreno Idler

Intelli-plug

Voltage Control

Features that will be added:

CPU overclock

Optimizations

working kexec-hardboot patch

CPU govenors

I/O schedulers

you tell me?

Features that will not be added:

TWRP - install it with fastboot (custom roms also have them ;) )

Prerequisites:

Official TWRP from https://twrp.me/ (it contains mandatory mkfs.f2fs file)

Xperia Z3 Compact

Fastboot drivers installed and

unlocked bootloader

FizTech kernel - helium

Instructions:

I recommend to do this after fresh install of ROM of choice. I tested my kernel on SLiMM and AOXP.

Kernel must be flashed through recovery. The zip contain wifi module and script that corrects partition layout.

If you want to use f2fs filesystem then follow optional steps which will format your /data and /cache partitions. (Maybe backup? :) )

Think thrice if you are determined to install this!

Install official TWRP

fastboot flash recovery twrp.img

To enter recovery press POWER and VOLUME down buttons simultaneously when phone is switched off. It should boot to recovery. This requires new bootloader, that allows booting to recovery.

Install ROM of your choice

F2FS optional : Wipe->advanced wipe select /cache and change filesystem to F2FS (Repair or Change File System)

F2FS optional : Do the same for /data

Install kernel ZIP

Reboot and wait. Sometimes it takes few minutes, especially after fresh install.

F2FS advice: If device is not booting, please reboot to recovery. Check your if your /data and /cache filesystems are F2FS. If not then repeat F2FS optional steps. Even if your partitions were F2FS, install kernel zip once again.

Optional: install TWRP once again if it was damaged by ROM installation.

If you don't see F2FS format option in "Repair or Change File System" then your recovery doesn't have mkfs.f2fs file in /sbin of your recovery (it needs to have permissions also). Use offical TWRP from [MENTION=4275152]someone755[/MENTION]

Downloads:

Lithium

<latest>

Kernel sources:

[url]https://github.com/adrset/kernel[/URL]

Credits:

[MENTION=4275152]someone755[/MENTION]

[MENTION=3816568]Myself5[/MENTION]

[MENTION=5169444]AndroPlus[/MENTION]

[MENTION=2784807]DooMLoRD[/MENTION]

[MENTION=3332811]faux123[/MENTION]

[MENTION=4431376]frantisek.nesveda[/MENTION]

[MENTION=4898097]arter97[/MENTION]

[MENTION=4675360]tomascus[/MENTION]

SONY

And all other contributors!

Sorry if I forgot you! Tell me and I will add you

About me:

I am currently studing, so the amount of time I can dediacate to XDA is limited. I am begginig my journey with developing - be understanding!
[Xperia Z3 Compact Android Development] king960:
Changelog:

Version 1 - Fiztech Hydrogen

- initial version

- F2FS support

- DM-verity disabled

- sony RIC disabled

Version 2 - FizTech Helium

- added GPU overclock

- added kcal support

- added IntelliThermal

- added init.d support

- initial patch for Kali-Nethunter support

- patched DIRTY COW exploit - in near future more safety patches will be added

- Kernel supports f2fs and ext4 partitions

Version 2.1 - FizTech Helium Revised

- added some CPU govenors

- added ZEN I/O scheduler as requested

- added Adreno Idler as requested

- enabled Intelli-plug

- exfat module enabled

- SElinux enforce

Version 3 Codename Lithium

- Added Voltage Control

- Added sioplus I/O scheduler

- Storage optimizations

Version (double) n (work still in progress)

- I will try to update the kernel to newer versions (AFAIK current one is 3.4.0, will try to update maybe to 3.4.113 if it's possible?)

- CPU overclock (don't prefer this - our device is warm enough :) )

- govenors

- maybe compile using linaro toolchain

- Kali-nethunter support
[Xperia Z3 Compact Android Development] someone755:
If you wanted to reserve this one, though luck :P

Not often I get tagged in new kernel threads. All the best man, and happy holidays
[Xperia Z3 Compact Android Development] fluffi444:
A day were a new kernel project is starting is a good day...

Good work up to now...

Maybe UV would also be nice...
[Xperia Z3 Compact Android Development] LoveTKB:
Good to hear about the new kernel. Awesome works!

I'm having with issue with the touch screen on my Z3 compact. The top and bottom of screen is unresponsive. But it happens on main screen, not in lock screen, not in welcome screen (when installed a fresh rom), and also not in TWRP.

I believe this related to the Sony' kernel. Could you help to investigate and hopefully fix the issue.

I will test the rom if hearing any word from you :)

Many thanks.
[Xperia Z3 Compact Android Development] king960:
Did I understood correctly, that you installed my kernel and such issue appeared? If yes: does the it exist on other kernels? I didn't modify anything in panel/screen/touchscreen. The only possible problem for now is that some kernel modules are not loaded. I must check which one is resonsible for what to decide whether to enable it or not or if it could be responsible for such issue (which I doubt).

What about your charger? In some cases broken chargers caused misbehaviour in touchscreen . For instance they are not properly grounded.

I need more information to help you.

Regards
[Xperia Z3 Compact Android Development] -CRO-Maher:
Can someone please explain to me what are benefits of f2fs, and what does it mean? Are there any bad sides of using it?
[Xperia Z3 Compact Android Development] andry360:
If you search on Google, you will find that f2fs is a filesystem developed by Samsung, faster than the others file systems(if used on emmc, SD card and ufs) so it'good if we could use it. But the kernel must have compatibility for it. Correct me if I'm wrong! And I'm looking forward using this kernel!
[Xperia Z3 Compact Android Development] LoveTKB:
It's not from your kernel. It's issue on Sony's ROM, which causes top and bottom screen area is not touchable. I think it was the kernel issue. Some forks from the thread had the same of my issue: http://xdaforums.com/z3-compact/help/home-button-t3151587

Many appreciates if you can figure out and have some fixes included in the kernel.

Thanks,
[Xperia Z3 Compact Android Development] panzerox123:
Cool! All the best developing this kernel. I will surely try this. BTW, do you see and performance and battery improvements in SliMM or AOXP?
[Xperia Z3 Compact Android Development] king960:
Yes, both have better performance and battery life than stock. :)

PS. Version 2 released - codename Helium
[Xperia Z3 Compact Android Development] panzerox123:
Cool I'm developing AOXP... And 1.3 I will be releasing 1.3 now! ;)

Also, how stable is the kernel?
[Xperia Z3 Compact Android Development] frixed:
This kernel Is awesome! It would be good if you added zen io, Adreno idler and dynamic fsync :D
[Xperia Z3 Compact Android Development] king960:
Thank you, I will try to add these. ;)
[Xperia Z3 Compact Android Development] karol5wwy:
Can you make version for concept?
[Xperia Z3 Compact Android Development] king960:
Maybe I will consider it in the future. Now I would like to focus on stock based kernel and patching it.
[Xperia Z3 Compact Android Development] frixed:
I have a problem with my sd 64GB with this kernel i get a notification that says "corrupted sd card" i touch to format and fix but not work and my sd work with twrp :/ i use SLIMM 3.8
[Xperia Z3 Compact Android Development] zEminho:
noob question could you tell me a good setup for running games without lag? I have problems in games like NFS no limits and RR3 in stock.

I tested another kernel only that always hangs up then I need to reboot.

Game always starts well only after a while drops to 15/20fps I'm almost changing smartphone. I've seen that is some limit that sony puts after a certain temperature thank you for help
[Xperia Z3 Compact Android Development] king960:
Hi, what is the filesystem of your sdcard?

Have you tried to format in TWRP or with help of PC?

Hi, after certain temperature a feature called CPU throttling is enabled. It's implemented by thermal driver to prevent damage to your phone. I haven't tried it in gaming but I read many positive opinions about intelli thermal driver which is included in my kernel.

I'll install that game and tell you how it works for me. :)
[Xperia Z3 Compact Android Development] frixed:
Hi, I use exfat, if I already try to format it in twrp but it does not work with the rom, in the pc it works, in twrp also and with another kernel also it works, it is kind of strange maybe it has something to do with format extfat :rolleyes:
[Xperia Z3 Compact Android Development] zEminho:
Thanks for the answer this happens after some races this does not happen on other devices with the same soc
[Xperia Z3 Compact Android Development] tomascus:
[MENTION=5106670]king960[/MENTION] Hi. With regards to some people's sdcard functionality breaking, it is most likely because the texfat module is broken due to version magic mismatch. You can force it to pass the check though with implementation like this: https://github.com/tunturn/android_...mmit/28833a9ceb1d1dd3201de2e90b6e3fb796b59f3b

Edit: also, what purpose does selinux being in permissive serve besides assisting in solving selinux problems?
[Xperia Z3 Compact Android Development] king960:
Hi, thank you for advice. I will check it.

I set SElinux to permissive because I noticed that many people want it in kernels.

You're right, kernel should be set to enforce. I will re-set it to permissive once I encouter any SElinux errors in dmesg/logcat.

I'm a newbie, still learning about linux/android, so I could make such mistakes, sorry! :)
[Xperia Z3 Compact Android Development] tomascus:
Feel free to ask me anything anytime if you have any issues with the kernel :)

And btw, patching to 3.4.113 is very possible. Either cherry picking all 5000+ commits or applying patches, good luck with the issues that may appear..
[Xperia Z3 Compact Android Development] :
Is there any crucial problems with this kernel which will affect daily use? I am thinking of using this kernel and formatting system and data as F2FS
[Xperia Z3 Compact Android Development] king960:
Hi,

I am using my kernel since some time and I haven't encoutered any difficulties/errors. Of course it's best to try for yourself.

Currently kernel supports only /cache and /data f2fs partitions, so formatting /system to f2fs won't work.

Remember to make backup, just in case. :)

Regards

PS.

I am uploading revised helium version, that includes few new features. :)
[Xperia Z3 Compact Android Development] :
Nice,still there will be performance improvements if data is formatted to F2FS.

Definitely will make a backup and try it out.

Thank you for the very fast reply.
[Xperia Z3 Compact Android Development] tomascus:
Do you have benchmarks to show this?

I have already tried benchmarking on our device and didn't see any improvement besides on random write speeds, which didn't seem to affect overall user experience from my subjective view.

Also, a Google employee who worked on the Pixel said it wasn't worth it: https://twitter.com/t_murray/status/808413328049508353

I believe the reason why System is not usually formatted as F2FS was because that partition was rarely written to and therefore there wouldn't be any real advantages in doing so.
[Xperia Z3 Compact Android Development] :
I dunno I just know that the OnePlus 3T is formatted to F2FS and the claims were that the 3T was faster than the original 3 because of the filesystem change
[Xperia Z3 Compact Android Development] shrazy:
Is it possible to implement DRM fix in this Kernel? So after flashing this we ain't need to worry about flashing this? It would be cool and I think there is like no real effort to implement this.
[Xperia Z3 Compact Android Development] king960:
Hi,

I will add it. I forgot about it. :)

Regards

PS.

If somone installed revised version, please redownload and reinstall it. It will change gpu idle from 200MHz to 27Mhz, so battery consumption will be better.
[Xperia Z3 Compact Android Development] Cirra92:
You do know that /data partition needs to be wiped in order to make DRM fix work? For that single reason I would prefer not to have DRM fix included, as it may break the already applied fix while dirty flashing the kernel. And flashing the kernel does not require wiping the /cache (which will remove DRM fix) and Dalvik, so I wouldn't like to mess my current setup and go from scratch. DRM fix is anyway just one extra zip to flash after CLEAN flash of the rom, not the kernel, so that shouldn't be tied to the kernel itself. My two cents though, maybe it won't cause any issues :)

I was just about to ask if you can lower the GPU idle freq :) And another thing, will you enable Voltage control? I'm using it to UV in my current kernel, which further made my phone cooler in day to day usage, and noticeably improved its battery life :) Oh and sioplus I/O scheduler would be nice if it's not present already :)
[Xperia Z3 Compact Android Development] king960:
Hi,

certainly, I will add voltage control and sioplus scheduler.

Additionally I will add second zip with drm fix included. The normal one will be still available, so there's no reason to worry. :cool:

Regards
[Xperia Z3 Compact Android Development] Cirra92:
Wow, great to hear that :) If you ask me, those two features will make this kernel complete, I'll flash it when it's done :)

Thanks for the effort :D
[Xperia Z3 Compact Android Development] king960:
Hi,

I added features as requested. :)

I also had to change my build server so last versions are not available.

Happy testing!
[Xperia Z3 Compact Android Development] :
Will there soonly be a DRM fix version?

Also great work! Haven't tested it yet but I am going to do everything from scratch today or tomorrow.
[Xperia Z3 Compact Android Development] king960:
Hi,

I will include a version with drm fix this week.

Christmas time, busy time. :)

Cheers
[Xperia Z3 Compact Android Development] Cirra92:
Damn, so quick :D Alright, flashing time, thank you and Happy holidays :D

Edit: I need some help now here. I can't flash MultiROM modified TWRP, neither through TWRP itself, neither through fastboot. Both times flashing is successful, but upon booting to recovery, it's still 3.0.2.0, even if the modified one is older.

Am I flashing to wrong partition somehow? Using: fastboot flash recovery twrp.img, should it be something different?
[Xperia Z3 Compact Android Development] king960:
Hi, that's weird.

fastboot flash recovery recovery.img

should work. How do you access recovery? To access it from you need to press Volume down + Power when phone is disabled. (This is how I do it on my bootloader)

Regards
[Xperia Z3 Compact Android Development] Cirra92:
Yep, that's the command used to flash recovery. And yes again, Volume down + Power when the phone is off, boots to recovery, but same as it was before flashing, in Advanced menu there is no MultiROM option... I'll give it a couple shots more, I hope it will work, there is no reason not to...

Other than that, my impression right away was that your kernel is snappier and smoother than the one I've been using, great work :D
[Xperia Z3 Compact Android Development] king960:
You can try this also (I use it when I have no access to computer)

su
dd if=/sdcard/twrp.img of=/dev/block/platform/msm_sdcc.1/by-name/FOTAKernel

I think recovery is kept there, but I must confirm this.

But please be careful with this command.

Cheers

Edit:

Also about MultiROM , I only managed to boot cm12.1 as a secodnary rom with no kexec-workaround. When you will install MultiROM recovery you'll see an option to enable this in MultiROM settings.

As I said in the first post kexec-hardboot is not working, but I am trying to repair it.

All roms like SLiMM didn't work as secondary for me.
[Xperia Z3 Compact Android Development] panzerox123:
How well does this work with AOXP? I've heard formatting System as F2FS doesnt have much use? Can you format DATA as F2FS ? Will it provide better gaming and use case performance?
[Xperia Z3 Compact Android Development] king960:
Hi,

Formatting /system to F2FS is useless, mainly because F2FS read speed is a little lower than EXT4's. (/system partion is usually mounted as read only)

The other thing is that /system partion is rarely accessed, comparing to /data and /cache so it makes formatting system to F2FS even more pointless. Of course you could do that, but why waste time? :)

F2FS takes advantage over EXT4 in random write/read speeds. Sequential write should be also higher.

You can read about difference between random and sequential write/read here.

I will attach screenshots from benchmarks to show you how it looks in numbers.

Regards
[Xperia Z3 Compact Android Development] panzerox123:
Thanks! It all makes sense now.
[Xperia Z3 Compact Android Development] :
I get an error message in TWRP saying "Cannot change filesystem" and then the phone goes into a bootloop just restarting at the Sony logo,solutions please?
[Xperia Z3 Compact Android Development] king960:
Hi, I assume you used official recovery? (TWRP 3.0.2-1)

It must be recovery problem, if it's bootloping from it.

Provide me with more information and tell me what did you do, step by step.

Regards
[Xperia Z3 Compact Android Development] Cirra92:
Hey I've managed to load MultiROM TWRP, but as always, not a single ROM can be flashed, they all throw Update system image failed, error 7. Even back on LP with kexec-hardboot patch I could only flash Carbon 5.1.1 if i remember, in all others I had to modify updater-script, but even then it wouldn't flash.

I have no clue how to edit updater-script to work, and I'm getting frustrated as I can't find a solution, nor a working updater-script. I'm flashing AOSP/CM, not stock ones.
[Xperia Z3 Compact Android Development] king960:
Hi,

unfortunately that's something i can't fix. It's MultiROM's fault. I've only managed to install cm12.1 as secondary rom. I don't know why the rom is erased alter installation, but maybe I'll try to look into MultiROM source or read how to make

.mrom package out of zip(maybe it'll work?)

Regards
[Xperia Z3 Compact Android Development] :
I got it working after doing like 3 f*cking reformatts lol

To be honest I have no idea what was the issue but I did the following:

1. Flashed the stock firmware through Flashtool

2. Once it was done immediately rebooted to Fastboot and flashed recovery

3. Flashed the ROM of choice(AOXP 1.3.1) and did a factory reset

4. Formatted Data as F2FS

5. Cache decided to be the cool dude which does nothing by not wanting to format to F2FS,so I changed it to EXT4 and then back to F2FS and it finally worked

6. And finally phone booted up no problem

Just also could you give me a recommendation to make the phone faster because it really isn't as good as I have seen before
[Xperia Z3 Compact Android Development] Cirra92:
Yes, that was always weird, why is ROM erased after it was installed (successfully as I can see?). Okay, let me know if you manage to work out something.

Cheers :)
[Xperia Z3 Compact Android Development] king960:
Hi,

I am glad you've managed to make it all work. It is very weird though, that you had to come across such a pain!

When it comes to performance, you could install kernel adiutor and change cpu govenor to performance, enable intelliplug to make phone cooler etc.

I will add CPU overclock soon, it shouldn't make phone feel faster, but maybe it will be quicker in some tasks.

Also after fresh installation Google may download some data etc. so give your phone a day. :)

Regards
[Xperia Z3 Compact Android Development] :
My phone is a tricky one it goes on its own if it wants to work or not.

Also weird issue the damn Kernel Adiutor doesn't work giving a force close for some reason.

And as well Google Chrome doesn't work!

I would want to show you how slow my phone is but you would get eye cancer from that

And TWRP is showing me my CPU is at 100 degrees Celsius!

Of course I don't think it has to do with your kernel just my device and my bad luck.

And also every time I am installing a zip from TWRP I am getting a "fstab error" but doesn't seem to matter much since everything boots up fine.

And how do you get the DRM fix working,it installs but the problem is it changes the cache pattition to EXT4 and then when I format it to F2FS I lose everything.

Thank you for the help! Really appreciate it!
[Xperia Z3 Compact Android Development] king960:
Hi,

Don't install the drm fix, it has an image of cache partition which is ext4 formatted. That's why I haven't added drm fix yet, it only works on ext4. I will have to maybe manually copy files from this image to cache partition and make an image then.

TWRP is giving fstab error to everyone I guess, just TWRP bug.

I think apps are not working because of your rom. I read that people have similar issues of AOXP 1.3.1.

Also about temperature in TWRP, as you said kernels have nothing to do with it. It is possible the temperature to raise up to 85 degrees when recovery is performimg some difficult tasks simultaneously with charging.

100 Celsius degrees is a really big temperature. I wish it was a bug, because such temperature is lethal. I reached 92 degrees in TWRP once and I was worried my screen will break.

Regards
[Xperia Z3 Compact Android Development] :
Oh ok,so AOXP is the cause of the problem,SLiMM doesn't really work out for me so I will find some other ROM

Thank you for the help and I won't go too off-topic because of XDA rules.
[Xperia Z3 Compact Android Development] panzerox123:
Yes. I know about the problem in AOXP and I will be fixing it this weekend. Until then, you can disable and reenable Google play services to fix crashing apps. ;)
[Xperia Z3 Compact Android Development] Cirra92:
[MENTION=5106670]king960[/MENTION] Hi, can you investigate if it's possible to keep GPU freq at 27mhz while using some non intensive tasks, such as scrolling through menus and some apps? On my previous kernel, with the same setup, GPU was kept at 27mhz, while here on every touch input it jumps on 100mhz and stays there.

Also, did you do anything about charging current settings? It's maxing out at 1200mA, whereas up until now it has been at 1450-1500mA. Maybe it's something running in the background on my side here, will investigate more on that, just wanted to check with you. Thanks :)
[Xperia Z3 Compact Android Development] Infy_AsiX:
Just checking if Quadrooter CVE-2016-2059, CVE-2016-2504 patches are included? The OP only lists Dirty Cow.

Could I please request FauxSound? It's the only audio mod I need. I use it for keeping analog gain as low as possible in normal headphones usage for decreasing DAC noise. Then boosting it up for high Ohm headphones and quiet tracks.

Thanks for the good work
[Xperia Z3 Compact Android Development] dddestiny:
I cannot open the download link. Anyone else share it for me?
[Xperia Z3 Compact Android Development] NewBay_STanLey:
The download link was dead, could you upload a new link, please?
[Xperia Z3 Compact Android Development] TamarindoJuice:
Anyone has the download link please?
[OnePlus X Q&A, Help & Troubleshooting] croqueurdos:
Hi all :)

I'm going to try to expose my problem.

I want to download apps from Google play store (my screen was broken, then repaired, so now I need to reinstall all my apps and during this operation by oneplus, I think that my phone has been updated to OOS 3.1.4), but for somes app only I have a transfer rate who is slower than the full rate of my line (France / FAI Free / ADSL 8mb/s=1mo/s), and only with somes apps from play store. A Speedtest is ok (1mo/s), somes apps from play store are ok too oO (1mo/s) but these are someone who are with reduced trnasfer rate (max +/- 620ko/s).

Others devices are ok with speedtest AND play store.

What can I try ?

By advance thanks you.

Fred