[TWEAK][ROOTED] Small tweak for battery, memory handling and performance - Sony Xperia XZ ROMs, Kernels, Recoveries, & Other

It's highly recommended to use together with my kernel in this thread
Today I'm gonna provide a small tweak after days I experienced on XZ. I notice that our XZ has some issues which is come from bad userspace settings. This tweak aims to improve a little battery usage, better memory management and more power (meaning more heat).
What have I done:
Remove cpu-boost parameter. It's too useless to boost cores on input event, specially big ones. Minimun frequency of small cores are powerful enough to handle UI reponsiveness, boosting them is just wasting power consumption and increase heating.
Reduce input boost ms to default 40ms.
Set memory parameters. Run set memory function for msm8996 devices, it will turn on ZRAM and adjust minfree for better multitasking (I noticed that apps got redraw a lot w/o this).
Optional: tune thermal-engine.conf for more performance. Device should be heater but I still keep it in safe zone. This tweak is just for who prefer performance w/ a little hotter device.
Update:
Remove cpu-boost paramenter for small core, tune thermal-engine for more performance
Download:
In attachments.
Install:
Flash via TWRP.
Target firmware:
41.2.A.7.35/53
It should/maybe work on other firmwares, do at your own risk, just remember to take a system backup.

Thank you, it's valid to marshmallow ?
Enviado desde mi F8331 mediante Tapatalk

Tested working on Nougat 41.2.A.2.223
The device feels smooth as f***
Awesome tweak
You have my appreciation:good:

I like the thermal engine changes. These are similar to what I had before I had to remove root yesterday. You can still go a bit higher it's fine even in direct sunlight and hot days. (I stopped at 78°C)
Also something I prefer as advice:
action_info 1593600+1824000+624000000+255+2+0 1478400+1478400+624000000+255+2+0
Is to always have 255 for maximum screen backlight such that the device doesn't turn down backlight in direct sunlight which is super retarded. Doesn't really increase the heat anyways.
Too sad I can't run these tweaks anymore. Now Pokemon Go runs like crap again. T_T

Got my XZ ran a lil bit laggy today, but too lazy to re-flash. Then I found this tweak just right in time, now the laggy has gone away. Many thanks

Hi, can be used together with deeznuts tweaks?

Will there be any updates for Oreo? I love this mod so much

Related

CPU governor on .213 ICS leak

Ever since I flashed the 213 leak, battery life has been a bit disappointing. To help things along, I downloaded SetCPU (haven't used it since my good ole OG Droid) and let it autodetect settings. To my surprise the governor was set to 'interactive' instead of hotplug like it was on stock GB.
My understanding is that hotplug allows the phone to disable unneeded cores during periods of low utilization, while interactive does not (although both cores can be disabled when the phone is sleeping). Do you think switching to hotplug from interactive will improve battery life?
My battery life is much better since switching, but I also disabled 4G (on WiFi most of the time) and added screen off and low battery profiles (600mhz and 800mhz max respectively) which muddy the waters a bit. I thought I would mention it on here for those of you who feel the same, it might be an easy way to improve battery life on the leak.
That's interesting. I've been using the .213 leak and my battery life has been quite good. I haven't noticed any particular drop in battery life, and I keep 4G on all the time. If I don't use my phone much, it's not uncommon for me to have 60% left at the end of the day.
Do you use anything like SetCPU? I am wondering whether I can confirm that the default governor of the leak does not shut off one of the CPUs when it is idle. If nobody can confirm I'll get around to checking it myself this weekend :laugh:
Sorry, I haven't messed with my cpu settings.

[Q] CPU frequency throttling

hi all
im using DooMKernel for a while and when i set the maximum frequency for any speed faster than [email protected], when the cpu is on heavy load or when the phone temperature is rising above some threshold (i think it's around 45 degrees, not sure tho) - there is an automatic down throttling to stock valus (max 1.5ghz) and nothing will recover it back to modified values unless reboot or reapplying the OC via SetCPU or equivalent.
now, i know there is a 'thermal control' sort of mechanism, and i also know it probably resides both on os level and sony framework, but i wish i could disable it somehow.
i know there is a great risk of frying my XZ, but im only intend to overclock for short terms and not for a main daily usage.
a quote from DooMLoRD's post on the subject:
It has been observed that the overclocking sometimes reverts back automatically to stock settings especially after heavy CPU load and if the device heats up.
I think have found why this happens:
Android OS level
there is a binary called: /system/bin/thermald which writes lower CPU freq values to the CPU sysfs interface if the device starts heating
there is also an app "Overheat Control" which i suspect is doing something similar
Kernel level
there seems to be some sort of fail-safe in place "msm_dcvs" which resets the CPU to 918Mhz or 1026Mhz or 1512Mhz
could also be some other things i am still searching
now there are ways to circumvent these issues but given the risk of the damage associated with overclock for long time i think its in our best interest to not screw with these fail-safes...
Click to expand...
Click to collapse
if someone could plz explain how to totaly disable thermal control - it would be much appreciated.
if you totally disable them your Smartphone will shutdown every time you reach....(cant remember! think it was 75°C) SoC Temp! and you will reach that kinda fast!

[Q&A] [KERNEL][D5803&D5833] AndroPlusKernel

Q&A for [KERNEL][D5803&D5833] AndroPlusKernel
Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.
Before posting, please use the forum search and read through the discussion thread for [KERNEL][D5803&D5833] AndroPlusKernel. If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.
Thanks for understanding and for helping to keep XDA neat and tidy!
Thanks
Very nice kernel, fast and smooth - great work and port.
Anyone knows if it's possible to use any third party kernel app to boost the headset volume?
Working
Hi this is my first post, infact I joined so I could report my findings.
I would just like to confirm so far that V5 working on my Z3C using the .93 firmware. I didn't need to wipe cache/dalvik/data partitions either.
For purposes of settings configuration, I'll be using TricksterMod
For stress testing purposes I'll be using Stability Test 2.7
Overclocking
Overclocking seems to work, I'll stress test and report back with the results.
I was wrong, it is unstable when overclocking and stress testing, with the phone force rebooting 1-5 seconds in to the stability test which loaded all 4 cores. Tried 2899Mhz and 2880Mhz (were both unstable and didn't try 2.72, 2.75, 2.57 either - I might try stability testing them.) Was completely stable at 2.47GHz, and it actually stuck there, no throttling in place! I stopped the stress test when the CPU temp was around 77-80C as my hand was getting burnt! The battery temp reached about 46C. It took 10 mins of stress testing for this to be reached. When the stock kernel was in place it would begin throttling after about 1-20 seconds under full load. First 2.2GHz, then 2 then 1.7 then 1.5 and eventually 1.25 after about 2-4mins.
I couldn't do a single core test though. I suspect as most games use single core or dual cores it wouldn't get overly hot.
My opinion is that fast clocked phones should be marketed with 2 speeds. The highest it'll reach under a boost mode (turbo for Intel's i5 and i7 series), and a slower speed that it'll average out at under thermal pressure. The Z3Cs would be turbo: 2.5GHz and normal: 1.5GHz.
Governors
These are quick tests I'm performing here to provide a quick look at responsiveness and potential unnecessary CPU jump ups.
Wheatley - most of the time it's hovering at top speed when approx CPU usage is 9%, it'll occasionally hunt down to 300Mhz but then right back up to 2899MHz. This one is speedy though. Governor tunables available.
Lagfree - idles at 300MHz - 960MHz then hunts up to 2.2-2.9Ghz when needed and turns on the second core. It seems to slow back down to idle. This one seems to have fast scrolling, sliding notifications pane quickly). No governor tunables.
SmartassV2 - idles at 300Mhz, speeds up to 422-960 on core 0, and turns on core 1 at 1.2-1.5GHz for a few seconds under fast scrolling and notification pane opening. Seems quite responsive. Probably good for battery life hopefully with the responsiveness of Interactive. No governor tunables.
Lionheart - Idles at 960 MHz for a few seconds then slows down to 300MHz with the odd increase to 729MHz. Core 0 and Core 1 reaches 1.26GHz under scrolling, notification pane opening. As fast as the others. Governor tunables available.
Hotplugging
Intelliplug appears to work better than MP-Decision - now only one core is on during idle, instead of 2.
MP-Decision was disabled to avoid conflicts.
Undervolting
I've only undervolted 300MHz to 675MHz from 775MHz as of writing this post.
Tried quickly undervolting in trickstermod by setting them all about -75mV, stability tested it, appears stable. I'll tweak the voltages a bit better when I do a scaling stability test.
Issues I've experienced
Sound Control is the only thing so far that causes a reboot. However music still plays over the speakers and headphones. Equaliser works too.
Upon rebooting, the CPU top speed will set itself to 2.2GHz, despite being set higher and saved at a higher speed in Trickstermod. Certainly trivial though.
Strange thing I've noticed: On the undervolt part I've noticed that there is a freq called 3033MHz, but no 2899MHz freq. Just an observation.
Misc
Force Fast Charge confirmed working! Before flashing new kernel charge went up 5% in about half an hour. It's now up another 5% in a matter of 5-10mins. This is when plugged to my PC.
Vibrator strength - set to 20 from 31, much quieter on table and can still feel it.
I'd like to say a huge thank you to DooMLoRD and AndroPlus for developing this stable kernel. Now my Z3C is worth the £28 a month I'm paying for again. Since this silly lad decided to bork the camera, Bravia functionality etc by rooting it on the first day. I'll report back and edit the post with my findings.
Max won't go beyond 2.266 GHz, Min won't change.
Hi All,
Firstly, great job with the kernel. Our Z3C is such a capable piece of kit and this just makes it that much better.
I'm running stock, 23.0.A.2.93, unlocked, rooted.
Problem:
I've tried using both SetCPU and No-Frills and while both show frequencies that are supposedly selectable above 2.266 GHz, neither app would actually respond. Meaning the max frequency will still only be 2.266 GHz even if I tried selecting something like 2.458 GHz (which should be selectable given that stock is 2.458 GHz.) See caps.
In addition, the Min value just won't change at all from 300 MHz. The frequencies scale up and down as the load changes but I can't raise the Min (again using both SetCPU and No-Frills) from 300 MHz.
Tried: I've tried turning off stamina mode and frozen apps that could control CPU activity (e.g. I use DS Battery Saver). I changed up Governors and Schedulers. I've tried re-flashing the kernel and it still doesn't change these behaviors.
Question/Need help: Just wanted to ask if anybody else have any problems setting the max frequency beyond 2.266 GHz and/or changing the minimum frequency from 300 MHz? Would appreciate any help resolving this behavior.
Thanks in advance!
pjmanalo said:
Hi All,
Firstly, great job with the kernel. Our Z3C is such a capable piece of kit and this just makes it that much better.
I'm running stock, 23.0.A.2.93, unlocked, rooted.
Problem:
I've tried using both SetCPU and No-Frills and while both show frequencies that are supposedly selectable above 2.266 GHz, neither app would actually respond. Meaning the max frequency will still only be 2.266 GHz even if I tried selecting something like 2.458 GHz (which should be selectable given that stock is 2.458 GHz.) See caps.
In addition, the Min value just won't change at all from 300 MHz. The frequencies scale up and down as the load changes but I can't raise the Min (again using both SetCPU and No-Frills) from 300 MHz.
Tried: I've tried turning off stamina mode and frozen apps that could control CPU activity (e.g. I use DS Battery Saver). I changed up Governors and Schedulers. I've tried re-flashing the kernel and it still doesn't change these behaviors.
Question/Need help: Just wanted to ask if anybody else have any problems setting the max frequency beyond 2.266 GHz and/or changing the minimum frequency from 300 MHz? Would appreciate any help resolving this behavior.
Thanks in advance!
Click to expand...
Click to collapse
Try installing TricksterMod (from Google Play store, trust me, you'll love it!) Then go to General and set the max speed to 2.46GHz or higher, and try using the Ondemand Governor too. I noticed that it wouldn't stick properly sometimes when using Interactive governor. If it doesn't stick for you then turn Frequency Lock on. Then check in the info tab that it's hitting the higher speed. Personally I'd recommend leaving the min speed on 300MHz. If you need constant high speeds, select the performance governor.
DBCJoey said:
Try installing TricksterMod (from Google Play store, trust me, you'll love it!) Then go to General and set the max speed to 2.46GHz or higher, and try using the Ondemand Governor too. I noticed that it wouldn't stick properly sometimes when using Interactive governor. If it doesn't stick for you then turn Frequency Lock on. Then check in the info tab that it's hitting the higher speed. Personally I'd recommend leaving the min speed on 300MHz. If you need constant high speeds, select the performance governor.
Click to expand...
Click to collapse
Thanks! That did the trick!
Odd that my usual app for the job across 4 other phones - SetCPU - doesn't work on what should essentially be the same job. [emoji55]
Please make sound_control drivers work so its possible to boost headphone volume on the Xperia Z3 Compact... Thanks
Nice work, a lot of updates I like it!
Is it possible to add a change log?
Thanks!
kernel for d5803 with the .93 but not .105
i search a kernel for the d5803 with the last .93 french version of phone
.5.77
Works great! Thanks a lot
Link for Z3C_D5803_AndroPlusKernel_v10.zip is dead
Pls upload in another location.
Yay sound control is working, thank you so much you're the best!
How to make this?
Hi AndroPlus,
I'm trying to figure out how one would go about building this boot.img that you've created.
What platform and compiler are you using?
Where are you getting sources the for the kernel? This file?
c9af6fc647060fb85dd646798453ec8f 23.0.A.2.105.tar.bz2
How do you construct boot.img from zImage + recovery?
Sorry if these are dumb questions.
Edit: never mind, I figured this out.
http://developer.sonymobile.com/kno...evices/how-to-build-and-flash-a-linux-kernel/ contains most of the information I needed.
The arm version of gcc that ships with Ubuntu 14.04 worked fine - arm-none-eabi-gcc (4.8.2-14ubuntu1+6) - no need to track down any mystery binaries. I did have to make several modifications to the kernel source to get it to build. Interestingly, some of the cpufreq stuff contained code that was incorrect. Someone at Samsung needs to go look up what "sequence point" means.
The hardest part was figuring out how to turn the zImage + ramdisk into something I could boot.
This: https://github.com/sonyxperiadev/mkqcdtbootimg was the correct tool to use - again, no need to track down any mystery mkbootimg or dtbTool binaries.
Hope this is helpful to someone. As someone new to Xperia dev, I found most of the information out there worse than useless.

Nexus 4 Fixes: Custom kernel installer mods & more

Intro
Over the past while I've finally decided to fix all minor annoyances on my Nexus 4. Here is a guide where I'll share all my modifications to make Mashmallow on the Mako as good as can be.
Kernel
Kernel Proper
The actual kernel included in this guide is HellSpawn kernel by @spezi77 which is based on hells-Core for Marshmallow, with all up-to-date Linux patches (3.4.112) and Google security patches (June 1). (Although I use, advocate, and absolutely recommend HellSpawn, feel free to use another custom kernel in the installer. You'll have to replace zImage and make your own changes to kernel/sema-boot.sh if your kernel doesn't include the same governors, hotplugs, etc.)
Here are a few highlights of HellSpawn itself:
- Includes the elementalx governor from @flar2 and lightweight mako_hotplug driver from @franciscofranco, which are much better than the stock ondemand governor and mpdecision hotplugs.
- Includes franciscofranco's gamma control, which is a much better default gamma for your screen and can be changed with franco's Nexus Display Control app or other Kernel Tweaker Apps.
- Includes a GPU overclock (400 -> 487 MHz) for when really demanding graphics operations require it.
- Includes BFQ, an optimized version of the default kernel's CFQ i/o scheduler. It helps when Play Store updates occur or when apps perform a lot of disk activity.
- Includes double tap to wake feature, which uses minimal extra battery and is much more convenient than the power key.
- When the screen is off, and not sleeping, only one CPU is active and it's limited to 1 GHz, which helps standby battery life with running background services.
Custom Kernel Installer
(original post with r1 was made on reddit)
I've adjusted many default kernel settings, based on a few years experience of running custom kernels. It uses the optimized elementalx governor from ElementalX kernel and lightweight mako_hotplug from franco kernel, with some of flar2's N5 settings, some of @hellsgod's N6 settings, and some of mine. There are other governors and hotplugs available, but from my experience, these offer the best balance of speed and battery life.
It includes a small, safe, -50 mV undervolt for a bit less heat from the CPU. - a user on reddit reported a reboot with r1, so I've removed voltage settings. It's probably useless to include such a small undervolt anyway. Change voltage settings in an init.d script or Kernel Tweaker app if you wish.
It activates double tap to wake by default, and also turns on power key suspend. If you press the power key with the screen on, double tap to wake will be turned off. Those on custom ROMs or Xposed's GravityBox can activate features to turn the screen off (double tap status bar, lock screen, nav bar, etc.) and keep double tap to wake on. Those without custom ROMs can perhaps use something like Greenify which can remap the home button long-press to turn the screen off.
It includes a patch to sepolicy which allows Viper4Android to work in selinux enforcing mode. You need to have SuperSU installed to have this work.
I've adjusted the io scheduler and page cache for better performance, tuned towards random reads.
It includes stock thermald and a tweaked thermald configuration that scales CPU frequencies up and down a little smoother when your temps get high. It should be noted that most custom kernels disable thermald for their own in-kernel thermal driver. I never liked doing this, as thermald does more than just adjust CPU frequencies - it also throttles GPU, screen brightness, and most importantly, battery charging. When your device gets too hot while charging, the worst thing to do is keep up the current and let the battery go over 45 degrees.
It includes a service to do 'Shared Cpufreq Policy', which lets thermald throttle all cores properly, and also lets the Battery Saver feature work correctly, by limiting all cores. This hasn't worked since KitKat and was one of my biggest annoyances. Many, if not all custom kernels just deleted the Power HAL libraries so battery saver feature doesn't work at all!
Includes Semaphore's 'mpdfake', a service to eat the touch boost spam that the Power HAL generates when not using mpdecision. If a custom kernel does not delete the Power HAL libraries, then your logcat is being spammed and logd process uses a lot of background CPU!
Includes a service to attempt to fix once and for all the location/GPS issues. I'm not going to state it works 100% yet, as I've only had max 24 hr uptime while making changes from the r1 release, but so far so good. Fingers crossed...
Includes a service to give SystemUI and Phone/Dialer higher priority. I haven't had a chance to really test it, as my device is sans-SIM at the moment, but it hopefully will lead to better responsiveness when you receive a call. (Under testing: giving some background processes lower priority, so they don't interrupt app usage.)
Move dalvik-cache to /cache partition and free 300-500 MB:
On each boot, it will check to see if you have a /cache/dalvik-cache folder, and will use it as the dalvik-cache if so.
If you are clean flashing a ROM and want to use /cache for dalvik-cache, create an empty dir in TWRP: /cache/dalvik-cache
If you just want to switch from /data to /cache, copy the /data/dalvik-cache to /cache/dalvik-cache and reboot.
Remember to be careful not to wipe /cache when 'dirty' flashing if you do this!
How to reset the mediaserver process quickly to get videos playing:
While your screen has been on for a few seconds or longer, double press the power key. You'll have to try it a few times to get the timing right, because a quick double press activates the camera in some ROMs. Also you're waiting for the screen to go off, not just dark. Practice a few times in low light, and you'll get the hang of the timing: each press should be followed by about half a second. You'll feel a short vibration when the service resets mediaserver to give some feedback that it's working. If it doesn't run the first time, keep cycling the screen off and on again until you get that vibration.
Remember: you have to start with the screen on, this allows you to quickly check on notifications from screen off without resetting mediaserver.
How to reset the sensors if ambient brightness, auto rotation, GPS, or any other sensors stop working:
Same as above, but this time you do the action twice. That is, screen on - double press power - vibrate once - double press power. You must do the two double presses within a second or two, so a little more practice may be needed. You'll feel two short vibrations when the service resets the sensors.
*** As of mod-r4, the new method to reset both mediaserver and sensors is Hold Volume Up and Power.
How to reset the touch screen if it becomes unresponsive:
If you happen to double tap to wake, the screen comes up, but no touches are being registered, tap on the screen with five fingers. If this doesn't reset it, turn the screen off and on again with the power key, and tap on the screen with both hands, all ten fingers. This will reset the driver and get it going again without a reboot.
Download & Installation
The installer is attached to this post. It's for AOSP ROMs, and uses the UberTC 5.4 toolchain. I'll post up CM versions on request.
Flash the zip with TWRP 3.0.2. If you have made any changes to your Marshmallow ROM (other custom kernels, etc.) you must remember to always flash custom kernels after (dirty) flashing custom ROMs! This is especially important, as if you are missing thermald you're going to have a bad time. FLASH YOUR ROM BEFORE THIS KERNEL INSTALLER UNLESS YOU HAVEN'T MADE ANY CHANGES. You can kill your device without thermal throttling!
Wiping dalvik-cache, and /cache is never necessary when flashing a custom kernel only.
ROM
Graphics Drivers
Audio
SuperSU - System or systemless?
Changelog: r14-mod-r3 - r13-mod4 - r16-mod-r5 - r04-mod-r6 - r05-mod-r7
Sorry, ran out of time for now but I'll continue the post soon...
If I want to customise the features, do I only comment out the features which I don't need in sema-boot.sh? Thx!
Hi @xenyz,
Thank you for your new kernel, I have to say that I missed using your projects.
Until now I'm testing it and the only cons I found is that with mako_hotplug when (temp increases) 1026 frequency makes mako very unresponsive.
Is there a way to change this frequency through a init.t script?
Thanks for keeping mako alive!
jer_ying_fd said:
If I want to customise the features, do I only comment out the features which I don't need in sema-boot.sh? Thx!
Click to expand...
Click to collapse
Sure, or another option is to put your overrides in /system/etc/init.d
jolas said:
Until now I'm testing it and the only cons I found is that with mako_hotplug when (temp increases) 1026 frequency makes mako very unresponsive.
Is there a way to change this frequency through a init.t script?
Click to expand...
Click to collapse
Carefully edit /system/etc/thermald.conf either in the installer before flashing, or on your device after flashing, and make your changes near the end of the file.
Can anyone comment on whether their location services are working better? I'm still undecided.
Sent from my Nexus 4 using Tapatalk
With the introduction of the new features of hellspawn r14, will it still work as it is?
jer_ying_fd said:
With the introduction of the new features of hellspawn r14, will it still work as it is?
Click to expand...
Click to collapse
I'm testing it out to make sure it's stable first. At least one change has to be made, turning off the new msm_hotplug which is enabled by default in r14.
Sent from my Nexus 4 using Tapatalk
xenyz said:
I'm testing it out to make sure it's stable first. At least one change has to be made, turning off the new msm_hotplug which is enabled by default in r14.
Sent from my Nexus 4 using Tapatalk
Click to expand...
Click to collapse
Ahh of course, I forgot to edit that out....
I've gotten strange behavior after installing the kernel on my Chroma ROM Nexus 4.
The touchscreen began to have bouts of unresponsiveness, when it never had it prior to installation
Extremely slow on wakeup after a long time in sleep mode. Once again, never had that issue before
Overall lag and slowdown that wasn't present on the stock kernel
I've enabled only D2TW, the new I/O scheduler, 1 core active on sleep, Schedule workqueues on awake cores, and ThermalId
Just now, it did a random reboot. Any idea on what the issue could be?
ArtOfSnaila said:
I've enabled only D2TW, the new I/O scheduler, 1 core active on sleep, Schedule workqueues on awake cores, and ThermalId
Just now, it did a random reboot. Any idea on what the issue could be?
Click to expand...
Click to collapse
Could you try it without changing any settings? Force stop the kernel app and reboot.
Do you use any Doze modification apps? Greenify aggressive doze?
Was it a reboot or a SystemUI restart? Did you see the Google bootloader logo? If so, send me last_kmsg
Sent from my Nexus 4 using Tapatalk
xenyz said:
Could you try it without changing any settings? Force stop the kernel app and reboot.
Do you use any Doze modification apps? Greenify aggressive doze?
Was it a reboot or a SystemUI restart? Did you see the Google bootloader logo? If so, send me last_kmsg
Sent from my Nexus 4 using Tapatalk
Click to expand...
Click to collapse
Alright, I'll try it without any settings modified.
I do use Aggressive Doze, could that be conflicting with the kernel? It never seemed to affect the stock kernel besides making the wake take a bit longer, but no lag afterwards.
It was a complete reboot, with the Google logo and everything. Here's the last_kmsg.
ArtOfSnaila said:
I do use Aggressive Doze, could that be conflicting with the kernel? It never seemed to affect the stock kernel besides making the wake take a bit longer, but no lag afterwards.
Click to expand...
Click to collapse
I have noticed some erratic behaviour when modifying doze settings. My best guess is that there are certain assumptions made in Marshmallow as to when the device will be in Doze mode, and changing them can have unintended consequences.
ArtOfSnaila said:
It was a complete reboot, with the Google logo and everything. Here's the last_kmsg.
Click to expand...
Click to collapse
That is strange, the reboot was caused by a restart to recovery request. If it happens again, grab another last_kmsg?
Sent from my Nexus 4 using Tapatalk
xenyz said:
I have noticed some erratic behaviour when modifying doze settings. My best guess is that there are certain assumptions made in Marshmallow as to when the device will be in Doze mode, and changing them can have unintended consequences.
That is strange, the reboot was caused by a restart to recovery request. If it happens again, grab another last_kmsg?
Sent from my Nexus 4 using Tapatalk
Click to expand...
Click to collapse
Ah crap, about the last.kmsg, I think I know what happened. To pull the .txt file I had to reboot into recovery and use terminal to mount /system and then pull it. It might've pulled data off of that restart.
Currently using the phone with no kernel app active, and it's doing fine. I'll keep you posted if weird stuff happens.
Another thing I noticed is that when I plugged in the charger, the phone would slow down a lot.
ArtOfSnaila said:
...
Another thing I noticed is that when I plugged in the charger, the phone would slow down a lot.
Click to expand...
Click to collapse
Maybe it had to do with hotplug settings (I used to have similar problems until I modified thermald.conf settings)
Sent from my Nexus 4 using Tapatalk
ArtOfSnaila said:
Another thing I noticed is that when I plugged in the charger, the phone would slow down a lot.
Click to expand...
Click to collapse
That's likely because of the thermal throttle when the battery gets warm. Keep in mind this is actually good for your battery, although annoying when it slows down.
I'm thinking about raising the threshold just a bit in the next release.
Sent from my Nexus 4 using Tapatalk
xenyz said:
That's likely because of the thermal throttle when the battery gets warm. Keep in mind this is actually good for your battery, although annoying when it slows down.
I'm thinking about raising the threshold just a bit in the next release.
Sent from my Nexus 4 using Tapatalk
Click to expand...
Click to collapse
I found the following changes to accomplish best my needs (snappier phone with average temp)
jolas said:
I found the following changes to accomplish best my needs (snappier phone with average temp)
Click to expand...
Click to collapse
Cool. Er, warm. Eh, whatever.
What's your battery temps whilst charging? This is my main concern and where throttle is necessary.
All batteries achieve optimum service life if used at 20°C (68°F) or slightly below. If, for example, a battery operates at 30°C (86°F) instead of a more moderate lower room temperature, the cycle life is reduced by 20 percent. At 40°C (104°F), the loss jumps to a whopping 40 percent, and if charged and discharged at 45°C (113°F), the cycle life is only half of what can be expected if used at 20°C (68°F).
Click to expand...
Click to collapse
source
I know it's likely not that useful for those of us with original batteries on older devices, but I try to treat it as best I can.
Sent from my Nexus 4 using Tapatalk
xenyz said:
Cool. Er, warm. Eh, whatever.
What's your battery temps whilst charging? This is my main concern and where throttle is necessary.
source
I know it's likely not that useful for those of us with original batteries on older devices, but I try to treat it as best I can.
Sent from my Nexus 4 using Tapatalk
Click to expand...
Click to collapse
Charging with screen on, battery temp around 40°C
Sent from my Nexus 4 using Tapatalk
After more than 24 hours of usage without kernel manager, it ran fine, until it started throttling for some reason. Turns out somehow, the max clock speed was locked to 1000 or so Mhz. I don't know if that was the kernel or the app misbehaving, but I ended up having to reactivate the kernel app to set the clock speed back to normal
There was another spontaneous reboot, here's the last.kmsg.
ArtOfSnaila said:
There was another spontaneous reboot, here's the last.kmsg.
Click to expand...
Click to collapse
Thanks for the log. I had a similar reboot but with r14, something in the wakeup_reasons code. I'll have a look through spezi77s commits in kernel/power and see if I can spot something.
I haven't had one reboot in a month or so of using r13, so it's quite strange that you had one so soon, after 24h.
As for the throttle, keep an eye on your battery temperature in Kernel Auditor or whatever and see if it's higher than 40 degrees when you get the 1 GHz max freq.
Edit: I discovered at least one bug in r2 wrt the PowerHal touch boost spam. I'm thinking of posting r14mod3 but I'm not certain r14 is stable yet (see main kernel thread)...
Sent from my Nexus 4 using Tapatalk

Thermal Settings

I have noticed the Xiaomi Mix has some persistent software thermal throttling after a short period of time.
I ran the same test on a OnePlus 3T and noticed this throttling issue is not present.
It's possible the temps to start throttling are too low on the Mix.
Is there any way to modify or increase these throttle limits?
I know this has been done before but I cannot load the Thermal conf file in /system/ etc / thermal-engine.conf
Can we replace the file with something else ?
The OnePlus forum members released several versions of the file with different throttling temps. Can we use these files or make our own.
https://forums.oneplus.net/threads/oneplus2-how-to-fix-thermal-throttling.417108/
Did you ever get any further with this? My phone idles at ~35C. I read a review that said throttling begins at ~40C so I get throttled when I do virtually anything.
I've only had this thing 2 days and the performance has been worse than my old Nexus 6 because the cores keep getting capped very low. I was copying some backed up files over WiFi from my PC. It was lots of small files so it was running for 20 mins or so. When I was trying to do other stuff in the meantime it started to get really sluggish. I used to do exactly the same thing on my N6 and I could never tell that file copying was running in the background. I checked Kernel Auditor and it was showing temps ~50C and the cores were all being capped around 5-600MHz.
I've tried the stock ROM (stable and beta) and EPIC, and Lineage/RR. It seems to be a bit worse on the latter two (Antutu won't go above 100k, but it's like 140k on the MIUI ones) for some reason, but it's an issue on all of them.
gavin19 said:
Did you ever get any further with this? My phone idles at ~35C. I read a review that said throttling begins at ~40C so I get throttled when I do virtually anything.
I've only had this thing 2 days and the performance has been worse than my old Nexus 6 because the cores keep getting capped very low. I was copying some backed up files over WiFi from my PC. It was lots of small files so it was running for 20 mins or so. When I was trying to do other stuff in the meantime it started to get really sluggish. I used to do exactly the same thing on my N6 and I could never tell that file copying was running in the background. I checked Kernel Auditor and it was showing temps ~50C and the cores were all being capped around 5-600MHz.
I've tried the stock ROM (stable and beta) and EPIC, and Lineage/RR. It seems to be a bit worse on the latter two (Antutu won't go above 100k, but it's like 140k on the MIUI ones) for some reason, but it's an issue on all of them.
Click to expand...
Click to collapse
I have absolutely gotten further here I have managed to get throttling completely disabled actually.
The highest temp the CPU got to was 42 degrees Celsius after running Dolphin for 2 hours straight.
There is no need for thermal throttling on this device at all, hardware does a good enough job clearing the heat.
To stop the thermal throttling you need root access.
Use ES File Explorer from the play store and enable root access
Navigate to root and look for Folder system/etc and find file called thermal*******.*** ( I don't remember what it's called )
Cut this file from this location and paste it into another directory. I moved it to the sdcard for easy access. This way you can move it back if you do not like the results.
I have not experienced any overheating with this, also the battery doesn't drain like crazy. Performance is greatly improved with speed matching the Snapdragon 835 in a few scenarios.
Oh yeah restart the phone after you move the file so it can register the changes. Clock the cores appropriately with Kernal Auditor to make sure it can run at full blast when it needs to. On demand is way faster than interactive.
Cheers. I actually read the links you posted and renamed the conf file. After a reboot it was flying. The problem isn't so much the throttling, it's that mine idles at ~35C already, so it was getting capped when I did virtually anything. If I run Antutu 2-3 times in a row and check the temps in Kernel Auditor it can be in the low 60s. Using other temp apps (CPUTemp) it only shows about 45C tops.
It definitely does feel pretty damn warm since I don't use a case. but I'd love to know what the 'real' temp was. I tend to believe the lower one since I got the 45C warning when using EPIC and that's exactly what the app said. it was.
My Antutu scores increased substantially too. I was sometimes dipping down to 80-90k but I regularly get ~140k now, even 160k once. I know not to go by those scores but when I could never even get above 100k it was a concern.
gavin19 said:
Cheers. I actually read the links you posted and renamed the conf file. After a reboot it was flying. The problem isn't so much the throttling, it's that mine idles at ~35C already, so it was getting capped when I did virtually anything. If I run Antutu 2-3 times in a row and check the temps in Kernel Auditor it can be in the low 60s. Using other temp apps (CPUTemp) it only shows about 45C tops.
It definitely does feel pretty damn warm since I don't use a case. but I'd love to know what the 'real' temp was. I tend to believe the lower one since I got the 45C warning when using EPIC and that's exactly what the app said. it was.
My Antutu scores increased substantially too. I was sometimes dipping down to 80-90k but I regularly get ~140k now, even 160k once. I know not to go by those scores but when I could never even get above 100k it was a concern.
Click to expand...
Click to collapse
Yeah I'm thinking Xiaomi severely limits the thermal threshold to improve battery performance.
It's kinda all they care about in Japan for some reason.
Makes for some great performance improvements without the thermal settings being active.
This setting change is almost necessary of you need some heavy work done.
Glad you were able to get this changed.
i remove thermal_8896_blabla.conf...
Honestly device become too hot for me.... backplate change during my game (Battle Bay), very different sensation... reinstall immediatly *.conf... Finally i have decent perf and cold phone and very good battery life... no more...
My opinion !
lesscro said:
i remove thermal_8896_blabla.conf...
Honestly device become too hot for me.... backplate change during my game (Battle Bay), very different sensation... reinstall immediatly *.conf... Finally i have decent perf and cold phone and very good battery life... no more...
My opinion !
Click to expand...
Click to collapse
I think our best solution would be a modified .conf file that increases the thermal threshold as opposed to completely removing it.
Until this solution is available then this is our only choice.
i agree... i think with a ROM kitchen mayve this fil can be readable... anyway @ this point, we can only hope somebody dectypt this file to support various cool modification available over XDA...
Edit /
it seems HTC make same stuff... here it is a guideline ot example...
https://forum.xda-developers.com/showthread.php?t=2455596
lesscro said:
i remove thermal_8896_blabla.conf...
Honestly device become too hot for me.... backplate change during my game (Battle Bay), very different sensation... reinstall immediatly *.conf... Finally i have decent perf and cold phone and very good battery life... no more...
My opinion !
Click to expand...
Click to collapse
I had the same issue. I was getting 165k+ in Antutu but the phone would get uncomfortably warm when doing multiple passes, or gaming for extended periods.
In the Thermal section of Kernel Auditor, I enabled the Core Control and Temperature Throttle options and the phone still gets warm, but only as warm as you'd expect. I still get ~155k in Antutu consistently and the performance in general is still very smooth. I have the CPU governor set to ondemand, and the GPU governor to simple_ondemand. All other KA settings are default.
One other thing I always do is to reduce the Window Animation, Transition Animation and Animator duration scales to .5x (1x by default). It just makes the phone feel snappier in general. Settings > Additional settings > Developer options (MIUI-based).
I'm using the latest EPIC ROM. Using RR/LOS I couldn't replicate the same high Antutu scores consistently for some reason. I quite like MIUI after years of using CM and CM-like ROMS anyway.
already reduce animation x0.5... MIUI use a lot of this animation with complex and (very long calcul) then reduce this number make device seems much faster... anyway, u right...
A custom kernel for miui base... based on Dragon XIA exist in MI5 thread... only need to play a bit to make universal... with all source we can make somthing, but no have time to play with all tutorial available on XDA or Youtube...
Only way to make device much smoother and battery friendly or Perf/Warm destructor...

Categories

Resources