yashsingh1/xdaforums huggingface dataset:
[Nexus 4 Original Android Development] thracemerin:
There's no need to be skeptical, here are the facts:

The patch set included in my hsic_fix kernel does reduce the msm_hsic_host wakelock considerably while using 3G because it fixes the issues with the HISC host controller not returning to a fully suspended state after wakeup. The initial implementation of these patches caused some fairly significant 3G data issues as the HSIC controller would reset if there was a momentary pause in packet traffic, this has been fixed in the latest version, but this contributed to some kernel devs being cautious about re-implementing. (I believe most of the major kernels now include most if not all of the patches from my repo either directly from me or from their source at CAF)

Does this translate into significant battery savings? That depends entirely on usage, the fact is that if the only thing that is preventing deep sleep is the HSIC host controller pretty much everything else is in the lowest possible power mode anyway (other than deep sleep) so the actual drain is minimal even if it were to remain like that all day.

The thing that drains the most power during 3G operation is the radio itself which depending on signal and usage can drain the battery significantly.

So overall, does it fix the perceived problem? Yes, but does it really reduce battery consumption a lot? maybe, but we're talking a couple of percentage points during a full 100-1% drain, so you might get another 15-30 minutes out of your phone depending on usage.
[Nexus 4 Original Android Development] Necromancer3:
Thank you for your comment, its much appreciated.

although i still find it strange that this is not fully/explicitly implemented in the popular Kernels.

i mean i don't code android stuff and i don't know whats going on there or how it works, but i trust the people that compile kernels they know a little about it. if they decided to not implement it, i thought there is a reason for it.

and the fact you actively pursue these forums doesn't help.

i feel that in that case your work should be more recognized, for the sake of all of us, N4 users.

would like to hear stratosks opinion on the matter.

regardless, i seem to be forced to try out your kernel and get an opinion based on experience, as my phone is kept awake 10 times more then screen on time.

MSM_HSIC being the culprit, running for like 3 hours in 10 hour period, draining much of the battery.

i have disabled almost all possible sync's. leaving only Gmail sync, no facebook or any other apps.

my SGS1 could do 3 times better with a lot more sync's. its unacceptable this phone can't go for 24 hours before recharge (on no or very light use), even with minimum sync's.

i know the other solution is to work off WIFI, unfortunately not everyone live/work in a "WIFI environment"
[Nexus 4 Original Android Development] thracemerin:
LG took an SOC that is for tablets only and stuck it in a phone thus requiring the 3G modem to be attached via a USB controller instead of being part of the chip itself, this is an extremely poor implementation and unfortunately it's not entirely fixable by anyone on the software side (hopefully LG will have sorted this out for the N5).
[Nexus 4 Original Android Development] sirxdroid:
You mean this beast in the N5? :)

http://www.engadget.com/2013/06/18/qualcomm-snapdragon-800-mdp-benchmarks/
[Nexus 4 Original Android Development] rusak2:
I flashed the 1.4 b3. In my own opinion the nexus runs faster as with 1.3. No stuttering by fast switching to settings and scrolling them down. sorry for my bad english guys )).
[Nexus 4 Original Android Development] ctfrommn:
I hope LG makes the N5.....I may actually buy one (and risk the look afterwards) :D
[Nexus 4 Original Android Development] stratosk:
I'm sorry. Is it faster with 1.4.0b3 or with 1.3.0?
[Nexus 4 Original Android Development] rusak2:
My nexus feels faster with the 1.4 b3.
[Nexus 4 Original Android Development] Necromancer3:
Whats an SOC?

And what exactly the disadvantages of this implimentetion? Requires more energy? Response time? Bad connectivity?

Arent you guys suffering from it too? Or have you just got accustomed to it?
[Nexus 4 Original Android Development] ctfrommn:
System on chip....the cpu/gpu/modem/etc.....Its much more efficient to build it all into the SOC than have a separate modem that then needs a controller....it all adds up to a "hacked" version. It works, its just not optimal.
[Nexus 4 Original Android Development] thracemerin:
http://en.wikipedia.org/wiki/System_on_a_chip

Everybody has this problem, it all depends on usage, people who use their devices primarily in areas where they have access to WiFi and those with extremely good 3G coverage will have lower wakelock time than those that don't, it's just part of life with the N4 you just kind of have to live with it.

Most phone SoCs have integrated modems which means that a secondary bus is not required to allow for 3G connectivity, since the SoC in the N4 doesn't have an integrated modem it requires a secondary USB host controller which is the device that is identified as msm_hsic_host, the problem is that this host doesn't go into suspend properly with the stock functionality and holds a wakelock for an unnecessarily long period of time, chips with integrated modems don't have this problem. Just to be clear, it's not possible to have 0 msm_hsic_host wakelock without shutting down the entire 3G modem including cellular calls, but reductions without loss of functionality are possible, however as I said before the actual benefit to battery life is likely to be reasonably insignificant, just because your device is awake doesn't necessarily equate to significant battery drain.
[Nexus 4 Original Android Development] Necromancer3:
But is that the reason for the massive drain?

HMmm... i just lost 10% surfing xda for 10 minutes...

Edit: my device seems to be awake 10 times longer then my screen on.

90% of it is due to that HSIC.

I also noticed that in period of time the phone is in deep sleep it looses less then 1% for hour.

If its not it (as you said, wake doesnt neccessarily means battery drain) what can it be?
[Nexus 4 Original Android Development] thracemerin:
Screen on + 3G radio use is about the highest drain scenario possible, so browsing XDA on 3G is going to drain your device very quickly, that has nothing to do with msm_hsic_host, that's because the baseband that comes with the N4 is very poorly coded, nothing at all can be done about this, basebands are closed source.
[Nexus 4 Original Android Development] sirxdroid:
Phone calls drain battery like crazy too :( At least the screen can be off during a phone call. Anything that moves data through that darn cell radio sucks.
[Nexus 4 Original Android Development] capoooro:
Yes screen time without call time is a null parameter for me. I mean that I use to receive and make phone calls. And with 90 minutes of calls... You drain your battery a lot.

pizza mandolino pasta
[Nexus 4 Original Android Development] mesarabi:
Hi

sorry for noob question

what is undervolting?Benefit?Risks?

and why touch control does not work?how it works?i use the semaphore app but still does not work
[Nexus 4 Original Android Development] ctfrommn:
Lowering the cpu voltage. Benefits are less heat (heat is public enemy #1).....Risks are instability and crashes if it is set too low. Start modest (-25/50mv) and go down from there. Stop whenever you are happy with the results. FYI, Ive seen very little additional benefit once you get to -100mv and below. Most chips will handle -100 just fine.

Touch control is NOT touch wake as some kernels have. This is to turn the screen back on after it times out (within a certain set time)....if you turn the screen off with the power button touch wake wont do anything. I think he has a good explanation in the OP.
[Nexus 4 Original Android Development] stratosk:
One more (maybe the last) just to be sure: 1.4.0b4

- ondemand: new tunables to control touch boost and some cleanups in the code.

Tunables:

- touch_load: the simulated load when there is touch in the screen (default 65)

- touch_load_threshold: over this load will be applied the touch_load (default 12)

- touch_load_duration: the duration of the simulated load in msec (default 1300)

So, with default values when there is a touch in the screen a pseudo load of 65% will be applied to the CPU if the current load is above 12%, for 1300ms.

Increasing touch_load will result in higher frequencies when touch the screen.

Increasing touch_load_threshold will result in less sensitive touch boosts. For more aggressive ondemand where there is touch you may decrease this value.

Please note that the default sampling rate has changed in previous beta to 20000.
[Nexus 4 Original Android Development] a g bell:
Yes!!:)awesome:)
[Nexus 4 Original Android Development] vandizzam:
Did the color change on the new beta? Might be something on my end.
[Nexus 4 Original Android Development] stratosk:
Nothing changed regarding colors.
[Nexus 4 Original Android Development] philidor:
[MENTION=3750240]stratosk[/MENTION] You were to much silent :) I'm waiting something from you ... Flashing new beta will report tomorrow. Great work

Edited (sleeping while writing :))
[Nexus 4 Original Android Development] edwardeutsch:
After some tests with some ROMs, it's time to flash again your kernel! Flashed latest b4. Seems smooth and battery friendly...will report back tomorrow! Great work as ever stratosk!

EDIT: Little gaming test. Subway Surf works better with 1.3.0 (smooth) than 1.4.0 b4 (i can see some stuttering).

Yeah, i know is still a beta build!

Linaro CM 10.1 @ Tapatalk 4
[Nexus 4 Original Android Development] copi:
on me there's no stutering in subway surfer with beta4 ? I'll play a little longer then to test it. the kernel is good atm. thanks stratosk.
[Nexus 4 Original Android Development] edwardeutsch:
Stock settings?

Linaro CM 10.1 @ Tapatalk 4
[Nexus 4 Original Android Development] copi:
yes stock setting,, just uv 87500 all, and color tweak.
[Nexus 4 Original Android Development] edwardeutsch:
I've tested it again. Stock settings. I can see microlags on b4 compared to 1.3.0 that runs smoothly...

Linaro CM 10.1 @ Tapatalk 4
[Nexus 4 Original Android Development] a g bell:
Just tried this game l cannot get it to run smoothly at all then l tried the game dead trigger and that runs like hot butter smooth as hell.Both with b4 but that's just my ten cents:eek:
[Nexus 4 Original Android Development] vandizzam:
Really good battery life with latest beta.

Undervolted and underclocked to 1.4.
[Nexus 4 Original Android Development] emanuele1986:
Me too, i continue to see microlag in the drawer also with b4 version
[Nexus 4 Original Android Development] stratosk:
Did you had the chance to play with the new tunables?
[Nexus 4 Original Android Development] emanuele1986:
I do not know what I have to touch in the setting. What do you advise to modify?
[Nexus 4 Original Android Development] stratosk:
You may lower touch_load_threshold (10 maybe).

You may also increase touch_load (higher freq when you touch the screen).

Finally, if you observe micro lags 1-1.5 sec after you touch the screen you may increase touch_load_duration (maybe to 1500-2000msec).

Edit: if you need absolutely smooth experience try these:

touch_load 95

touch_load_threshold 5

But, battery drain will be higher
[Nexus 4 Original Android Development] Kagath:
The trouble with version 1.4 is that the 4 cores are always on, that heat the CPU.

And the battery have a shorter duration.

It's shame that it don't have power save mode.

Otherwise good job I'm always a really big fan of your work.

I love your kernel
[Nexus 4 Original Android Development] a g bell:
Sorry but l have to disagree l dont see any adverse cpu temps or reduced battery life could you give example? You could just reduce your Max CPU frequency

:)
[Nexus 4 Original Android Development] stratosk:
The goal of 1.4.0 betas is to examine the function of the kernel without mpdecision.

Without mpdecision 4 cores will be online every time.

So, in your opinion 1.4.0 fails to this goal?

There will be an option to Semaphore Manager to select the number of online cores.

But this will be 'permanent' option and online/offline will change after user selection.
[Nexus 4 Original Android Development] trillo69:
I'm not sure how, i think it is because another hotplug solution, but trinity kernel doesn't use mpdecision and it has the possibility of set min_cores_online to 1 (although default is 4). Maybe you could check that, it works pretty well and it's a good solution to reduce heat now in summer time, because indeed 4 cores always online produce a bit more heat.
[Nexus 4 Original Android Development] emanuele1986:
i'll try it
[Nexus 4 Original Android Development] philidor:
How to use this settings? Can I use semaphore manager?

Edit: I have semaphore manager but I set with ROM toolbox pro
[Nexus 4 Original Android Development] stratosk:
You can't set them from Semaphore manager yet.
[Nexus 4 Original Android Development] manjee:
After 2 days of testing, I prefer 1.3 to 1.4b. I think 1.3 is easier on battery and if I had to choose arbitrarily which one is snappier, I'd say 1.3 though this could be placebo as the difference is thin.

Cheers and thank you for sharing your great work stratosk.

Envoyé depuis mon Nexus 4 en utilisant Tapatalk 4 Beta
[Nexus 4 Original Android Development] coloxim:
Can you add low freq 192?
[Nexus 4 Original Android Development] -iNSiGhT-:
Same as manjee. ;)

Paranoid mako
[Nexus 4 Original Android Development] philidor:
I reflashed stock ROM and install last CM. tomorrow I will see how battery friendly is 1.4 b4 after a new installation.
[Nexus 4 Original Android Development] pnut22r:
I like your work, just one question, if your kernel worked so well with mpdecsion, why move away from that? I understand the benefits, but is it that much better to run without ?
[Nexus 4 Original Android Development] sirxdroid:
+1 I really liked Semaphore because it was a stock-ish kernel with just a few needed additions such as color profiles, UV. Many have tried to get rid of mpd but there's only one kernel out there that I think matches mpd's performance: Franco.

[MENTION=3750240]stratosk[/MENTION] - if you drop mpd, I hope you succeed in matching its performance via a custom hotplug solution, while improving battery life.
[Nexus 4 Original Android Development] coloxim:
Mpdecsion makes my phone more fast...

With other kernel I've always micro lag..

Sincerely I don't know about the battery life if really change..
[Nexus 4 Original Android Development] rusak2:
Don't drop mpd. Because it's the key for smoothness in my opinion.

Gesendet von meinem Nexus 4 mit Tapatalk 4 Beta
[Nexus 4 Original Android Development] apatal:
Although I love Semaphore with mpdecision during the times that I tried it, I'm going to be the devil's advocate and say that mpdecision isn't the end-all-be-all for buttery performance for our phone. I agree with another poster above that Franco kernel may be a good alternative to mpdecision-driven kernels but it is not the only kernel to offer smooth experience without mpd. I know of a couple actually. Another route that [MENTION=3750240]stratosk[/MENTION] may take is to have mpdecision available but offer the option to disable it for those who like more control over their CPU tunables. In the end though, it would depend on him and let's respect the choices he makes for his project. :)
[Nexus 4 Original Android Development] a g bell:
Could not agree more,l don't know how to get these micro lags once l have set the tunables l have the best performance/battery on b4 l have ever had on any kernel but again that's just MY opinion. I have been running semaphore for a longtime without mpdecision and now with tuneables its more awesome than ever lmho.But as apatal said whatever stratosk's mp decision is it will be the best one:)
[Nexus 4 Original Android Development] matthewgwilt:
Amazing work

I know this is a development thread but I'd just like to show my appreciation for this Kernel. I've been a big fan of the semaphore kernel since it was released for the i9000 in the Gingerbread days... It goes hand in hand with CyanogenMod! A big thank you!!
[Nexus 4 Original Android Development] spr33:
I've been running the latest beta since it was released and I'm finding battery life is taking a hit. I've checked to see if there are any wakelocks causing battery deficiency and there aren't any that I can spot. Unsure if it's to do with the weather being 10C+ warmer since the beta release or not but I can't see heat being a factor for drain.

I'll return to the 1.3 release to see if I still get the drain.
[Nexus 4 Original Android Development] stratosk:
Thanks everybody for your feedback.

I will try to answer to your posts.

1.4.0b is an experiment about the possibility to drop mpdecision.

It's not final that mpdecision will be dropped from Semaphore.

Why do I experiment with this? Kernel runs just fine with mpdecision.

I agree, but I have 2 points:

1) I would like a pure 4 core device.

2) mpdecision gives no possibility to tweak it's behavior.

The 2) is obvious but I would like to explain 1) more:

CPU hotplug is a kernel operation that is made in case you need to replace a CPU or to add a CPU to a system.

Hotplug is not developed for battery efficiency. Hot plugging a CPU costs in kernel. It's a very time consuming kernel task.

Of course CPU hotplug begun to used on phones as a battery saver. And again I will agree that mpdecision does it's job.

But I think CPU hotplug is an ugly way to save battery. It's like switch off your engine in crossroad waiting for green light.

So, I decided to test the possibility to have 4 cores online all the time. And I like it.

It's definitely faster on medium to heavy loads. System does not wait cores to come online.

There is a force waiting for you to use it.

IMHO, is as smooth as mpdecision and it may tuned via tunables to be more smooth.

1.4.0 drains almost the same battery as mpdecision (maybe a little bit more) and it heats the device a little bit more.

1.4.0 is also tunable. You may tweak it to save battery (less smooth results) or push it more.

If I was the only Semaphore user, I will decided to drop mpdecision. I like my hardware uncapped.

My goal was/is to check if this solution is best for all.
[Nexus 4 Original Android Development] a g bell:
I'm the semaphore user l would like my hardware uncapped:)No but seriously thanks for explaining in details
[Nexus 4 Original Android Development] GreenSGS:
May I dare to ask a question Stratos, if I install Franco kernel to check performance etc and want to come back on Semaphore, is this straight forward install zip from CWM or I need to do something else. Sorry to bother, if it's been answered. I am not getting clear info. Thank you. Please ignore if question is repeated.

NooBs are rare to be seen on XDA, why because there are lot of noob killers on xda. Don't believe me then just act like a noob.
[Nexus 4 Original Android Development] pnut22r:
+1

That's awesome. I think most users are curios, but don't always technically know why things are happening. That's why I asked, now I know why and it makes sense. Thank you.

It's good to learn along the way :)
[Nexus 4 Original Android Development] stratosk:
As far as I know franco kernel changes a coouple of system binaries.

So, you need to restore them in case you need to flash back Semaphore.

Some people use a 'reset' kernel. Though I've never tested. Others dirty flash their ROM.

We all were noobs :)
[Nexus 4 Original Android Development] a g bell:
Sorry to jump in but if you come from Franco to semaphore you should dirty flash your ROM first due to changes made by Franco to binaries

Oops:o
[Nexus 4 Original Android Development] GreenSGS:
Thank you friend, If I stock rooted then what is my option, I didn't do backup. Stupid me.

NooBs are rare to be seen on XDA, why because there are lot of noob killers on xda. Don't believe me then just act like a noob.
[Nexus 4 Original Android Development] Droid2drummer:
I always flash revert zip and never had issue. But I'm sure I'm missing something...
[Nexus 4 Original Android Development] matthewgwilt:
4 cores mpdecision

So by having 4 cores online all the time... wouldn't that make the cpu behave more like the way Samsung tune their kernels with their closed source Pegasus governor? Am I right in saying the Pegasus governor is closed source? Before my Nexus 4 I had the i9305 and the default governor was Pegasus.. when tested all cores were always on... hence its great performance and benchmarks.. although battery life was questionable
[Nexus 4 Original Android Development] stratosk:
I can't say since I've never tried S3 :)
[Nexus 4 Original Android Development] sirxdroid:
And this is exactly what modern cars such as BMW do these days to save gas. V8 gas guzzlers turn off 2-4 cylinders too when cruising. I guess we have cars running mpdecision :)

The new Moto X is probably making the right decision to go with a dual core CPU. I hope they keep the 2 cores online all the time. For my use pattern I think a 4 core CPU is a waste.

[MENTION=3750240]stratosk[/MENTION] - I assume it's more expensive to online/offline cores than to vary the frequency of a core that's already online. I wonder what onlining a core does to the voltage requirements and whether it's more problematic if undervolted. It would be nice if we could actually get the CPU to run at say 192Mhz instead of 384Mhz then having 4 cores on all the time would be fine. But from what I read I'm not convinced this CPU can run lower than 384Mhz no matter what the sysfs may be reporting.
[Nexus 4 Original Android Development] stratosk:
Yes, but modern cards designed to do this.

Hotplug is like switch off the engine with the key.

Kernel does a lot of work when you put a CPU online/offline. It has to reschedule all threads, workqueues etc to other CPU.

Also, modern CPUs (on our desktops for example) use efficiently C states where the core is actually inactive. But the kernel still sees this core as online. As far as I know C states are somehow problematic in our phone's CPU.

About your question online/offline CPU is by far more expensive than to modify frequency. If I recall correctly online/offline can be done in msec (maybe 100-200msec). Changing core frequency is a matter of nano seconds. For example governors usually poll system load every 10000 microseconds to change frequency.

Honestly, I don't know what will be the impact if we lower the freq to 192MHz (if it's actually possible).

EDIT: BTW, put CPU online/offline is also a task that requires a lot of energy. Also, to awake a CPU from a deeper sleep state requires more energy than awaking the same CPU from a not so deep sleep state.
[Nexus 4 Original Android Development] a g bell:
That is something l will never understand why modern cars do this
[Nexus 4 Original Android Development] stratosk:
I also cannot understand why someone buys a BMW V8 and then wants to save gas. :)

It's almost the same as modern smartphones.

We buy a quad core phone and then we try to find a way use it as 2 core most of the time. :)
[Nexus 4 Original Android Development] ctfrommn:
Ive always been intrigued by the idea of all cores online all the time....Trinity was actually the 1st to default like that. The issue I run into (esp [MENTION=1528666]151[/MENTION]2) is heat. This setup causes a lot more heat, for me at least. Even UV'ing it it runs a good 5-10c hotter all the time. I do agree that hotplugging costs at least as much as it saves though. I just dont know if the side effects are worth it in the end. Keep up the fabulous work! :)
[Nexus 4 Original Android Development] coloxim:
Sorry.. My English is very bad.. But in the end mpt will turn off? And we will have 4 CPU on?
[Nexus 4 Original Android Development] apatal:
For the beta builds, yes. But stratosk is yet to decide on whether this will become permanent for future builds. :)
[Nexus 4 Original Android Development] ceejay83:
Another option would be to have 2 cores always online.
[Nexus 4 Original Android Development] coloxim:
Thanks... Anyway I've triedi matrix and faux... the battery seems better, but this is more smoothness...