yashsingh1/xdaforums huggingface dataset:
[Moto X Q&A] KidJoe:
There are places on the internet to purchase a SIM unlock code for ATT moto X which will allow you to use a non-ATT sim, however, this wont unlock the bootloader and allow you to run custom roms.
[Galaxy S 4 Active Original Android Development] spegelius:
Credits go to [MENTION=4325945]ktoonsez[/MENTION] for his kernel sources and KT apps (KTweaker and KTmonitor) :good:

Disclaimer: me no responsible if you use this!

So what is this? KT-SGS4 AOSP-4.4 S4 kernel ported to S4 Active (Intl). What has changed is of course jactive related stuff:

jactive board definitions and kernel config

camera sources and handler functions

some display settings

assorted stuff, can't really remember all the imporant bits

pre 1.0.0 AOSP4.4

Also, i tried to make a unified kernel, i.e. all differences between original and jactive are controlled with code ifdefs. But this haven't been tested as i don't have S4

So what works? So far i have found only one bug, when making or receiving calls i can't hear what the other side is saying and vice versa, i.e. no audio. Call sounds fixed.

Also overclocking the CPU seems to be broken, at least KTmonitor shows CPU to go only up to 1890 even though the clock is set over that value. So that's one thing to work on. I'll try to debug someday next week.

Compiled with linaro-4.7-12.10 toolchain.

This should work on CM11 and AOSP based roms. Personally i have it running on SlimKat (dualboot) and CM11. Just flash the CWM zip. It contains KTweaker and KTmonitor apps, courtesy of ktoonsez. Thanks mate.

Latest version 04.14.2014

Personal experiences:

benchmarks are slower than with CM11 kernel, dunno if it matters...

still it's smooth in everyday use

KTweaker has lots of stuff to tweak, only if i had time... :)

AOSP4.4/CM11

This one works with CM11 and AOSP v 1.0.0 and later. Don't use with earlier AOSP since this needs newer blobs.

KT-SGS4-KK4.4-AOSP-eur-02.11.2015

Built with Linaro 4.9 2014.09

Beta release

AOSP5.0/CM12

As there is no AOSP5.0 for jactive yet, just use CM12 :).

KT-SGS4-LP5.0-AOSP-eur-02.15.2015:

fixed bootloop for now at least

supports ext4/f2fs partitions

KT-SGS4-LP5.0-AOSP-eur-02.11.2015

Built with Linaro 4.9 2014.09

Beta release

TouchWiz

This one works with KK TW roms (well i have tried only WizCyan...). Seems stable with default clocks and even with some OC. But every phone is different in regards OC, so YMMV. KTweaker and KTmonitor included. Do note that Display settings might not work as we don't have Amoled.

Changes ver 01.12.2015

Fixed unresponsive screen bug

Compiled with Linaro 4.9-2014.09

Changes ver 01.03.2015

overclocking works better now

increased touchscreen min limit freq, hopefully removes problem with unresponsiveness

built with Linaro 4.7.12.10

Changes ver 12.15.2014 (BETA)

first version of KT TW kernel for jactive

added KEXEC_HARDBOOT support, works with MultiROM

General notes

Do keep in mind that if you don't set oc settings in boot, you need to use KTweaker app and reset the cpu min and max sliders for the settings to take effect. Even though the app asks if you want to apply the settings, it doesn't update the actual min and max values.

Download here: https://drive.google.com/folderview?id=0BzJzDM42pkRvd1ZtMDZOR1M1OFE&usp=sharing

Github here: https://github.com/spegelius/KT-SGS4
[Galaxy S 4 Active Original Android Development] mythi:
god !!!!!! .... spegelius did it again ;);) you beast ... keep up the good work :p:good::good:
[Galaxy S 4 Active Original Android Development] spegelius:
Heh, thanks. Sadly there seems to be a bug with call audio, so for test use only at this point. I went through the kernel code and all i can think of to do is to try audio stuff from CM11 kernel, to see if that's the problem. Still, audio works perfectly everywhere else so really hard to say what's wrong...
[Galaxy S 4 Active Original Android Development] mythi:
Whats even harder is taking a logcat and ksmg while in a call :mad::mad:
[Galaxy S 4 Active Original Android Development] spegelius:
True, but luckily i have two phones and sims (other one is my work phone) so it's easier to debug.

Some progress: it turns out that for some reason es325 codec can't connect to slimbus sink and thus no audio. slimbus has some kt additions, need to debug more. Also i think it would be good to try to build the kernel with some other toolchain than linaro...
[Galaxy S 4 Active Original Android Development] mythi:
Hmmm... does it build modules with kernel ?? Ya changing the compiler to maybe the google ndk gcc may fix up some issues but I think u will have alot of pain in debugging files since not all elements that linaro supports are supported by other .... I maybe wrong but ...xxxx
[Galaxy S 4 Active Original Android Development] ktoonsez:
Good job man :good: :highfive:
[Galaxy S 4 Active Original Android Development] spegelius:
Yes, modules are compiled and part of the cwm package. I haven't checked that all required modules are present, but i don't think that's the problem. Gonna be setting up a proper kernel dev env, found a good howto for Eclipse here: http://simonkagstrom.livejournal.com/33093.html. Regular editors just aren't cutting it anymore :)

Thanks :). Luckily i had some experience with LeJay's cm10.2 kernel and cm11 kernel so i knew roughly what parts differ between jf an jactive. Just a matter of diffing those parts (meld is my tool of choice for that kind of work).
[Galaxy S 4 Active Original Android Development] lijoc:
This kernel s awesome. It's speeded up my phone. I want to use this regularly has anyone found a way for the phone call sound??
[Galaxy S 4 Active Original Android Development] spegelius:
Not yet. Been debugging and the problem is somewhere in kernel's slimbus communication, it seems es325 codec cannot get audience firmware loaded properly or something...
[Galaxy S 4 Active Original Android Development] spegelius:
Ah, found he bug; && should be || when checking if CONFIG_JACTIVE_ATT or CONFIG_JACTIVE_EUR... es325 wasn't configured properly. Now call sounds work. I'll upload a new build after i do some testing first.
[Galaxy S 4 Active Original Android Development] lijoc:
Waiting for the upload
[Galaxy S 4 Active Original Android Development] spegelius:
Uploading, KT-SGS4-KK4.4-AOSP-jactive_eur-04.19.2014.zip should be online soon.
[Galaxy S 4 Active Original Android Development] lijoc:
It's working now. The volume is too low is there a way to increase it?
[Galaxy S 4 Active Original Android Development] spegelius:
Hmm doesn't the volume button work? Also what rom are you running?
[Galaxy S 4 Active Original Android Development] lijoc:
Volume button works and is on maximum. I am using carbon rom
[Galaxy S 4 Active Original Android Development] Pkt_Lnt:
I am running your AOSP 4.3.1 ROM http://xdaforums.com/showthread.php?t=2621883

I flashed this kernel in recovery, wiped cache and dalvik, but it will not boot. I get the "Samsung Galaxy S4 Active I-9295" splash screen, then it hangs, and hangs, and hangs.

I had to restore back to the version 8 nandroid of that thread. ADB would give me nothing so early in the boot sequence.
[Galaxy S 4 Active Original Android Development] 6783:
Did you read the topic? this kernel is for 4.4
[Galaxy S 4 Active Original Android Development] spegelius:
Indeed, it's for AOSP 4.4.x. You propable need to reflash the whole rom to get back original boot.img and kernel modules.

As for the phone sound being too low, dunno. If it was working ok with the original Carbon kernel, that points the problem being in the new kernel. But to my limited understanding, the volumes come from settings outside the kernel... personally i'm running CM11 with this kernel and volumes are ok.
[Galaxy S 4 Active Original Android Development] lijoc:
The volume in carbon rom also is the same. I tried the sound mods but it changes all the volumes of system other than the incall volume.
[Galaxy S 4 Active Original Android Development] Pkt_Lnt:
Sigh, yes, yes I did.

However, due to my sleep deprived brain, my enthusiasm for [MENTION=3876105]spegelius[/MENTION] work, and my wanting an AOSP ROM, my comprehension missed that one teensy number. :D Sorry and thanks.

I just wiped and restored my nand, no blood, no foul. Any chance you will work on a 4.4 AOSP ROM for the I-9295? I'd gladly throw another donation your way. Custom ROMs are interesting, but AOSP flies light and fast. :good:
[Galaxy S 4 Active Original Android Development] spegelius:
AOSP 4.4 is on my todo list, but currently this kernel is taking my limited time.

I've been debugging the overclocking and results so far:

- there's a default value of 1890Mhz for cpu max clocks. Even through i enable oc steps in KTweaker, that max value is respected and you cannot go over it

- there's a system file per cpu, scaling_booted. Writing value 1 to it changes the Max cpu to 2322Mhz. Now when i change cpu freq, it changes. Sadly, every freq i've tried hangs the phone, even with extra voltage :/. Hang doesn't happen immediately, but it hangs

Now as this is first time for me tweaking cpu freq parameters and what not, i have more questions than before i started debugging this :).

- is the scaling_booted value 1 supposed to e written to all cpus? Propably, but onto the next question ->

- what writes the value? KTweaker has an error when starting:

W/System.err( 8528): java.io.FileNotFoundException: /sys/devices/virtual/sec/tsp/slide2wake: open failed: ENOENT (No such file or directory)

- do i need to set permissions to some files in init scripts? I get some errors like this in dmesg:

<3>[ 27.333740] mpd msm_mpd_attr_em_win_size_min_us_store: Error 4 returned when setting algo param em_win_size_min_us to 100000
<3>[ 27.345153] mpd msm_mpd_attr_em_win_size_max_us_store: Error 4 returned when setting algo param em_win_size_max_us to 1000000
<3>[ 27.356170] mpd msm_mpd_attr_online_util_pct_min_store: Error 4 returned when setting algo param online_util_pct_min to 3
<3>[ 27.367584] mpd msm_mpd_attr_online_util_pct_max_store: Error 4 returned when setting algo param online_util_pct_max to 25
<3>[ 27.378356] mpd msm_mpd_attr_em_max_util_pct_store: Error 4 returned when setting algo param em_max_util_pct to 97
[Galaxy S 4 Active Original Android Development] spegelius:
Another try: modified the initial global max from 1890 to 1944 and now overclocking sticks. The problem is that it isn't stable for some reason; Antutu force closes before even starting the test run. Always. There's some error about stack corruption in logcat. However, all other things work propery, like Quadrant, some apps and even had a walk with Sports Tracker tracking.

Also setting the initial global max to higher level seems to force the cpu freq max to that level regardless of the setting in KTweaker. That's propably why my phone crashed every time i tried writing 1 to scaling_booted (which set the global max to 2322Mhz). More debugging...
[Galaxy S 4 Active Original Android Development] spegelius:
Found the post-init script which sets scaling_booted to 1. But the problem seems to be that when changing cpu frequency, only the first core is affected or the oveclocking doesn't stick; right now i have max cpu freq set to 1458 and running Stability test. At first cpu0 was running at 1458 and the rest at 1944. After a little while they all jumped to 1890 and now they are running at 1674 for some reason (throttling?)...

Having a WTF moment... is this normal behaviour for mobile cpus? I've only oveclocked desktop stuff and with them you can at least rely on them running at the speed you set them to run. Not liking this...
[Galaxy S 4 Active Original Android Development] pen²:
Is this kernel still good for the recent cm 11 experimental builds? I liked it a lot, would love to use it again or maybe a new version
[Galaxy S 4 Active Original Android Development] spegelius:
It should be ok, i had a build of SlimKat running with this kernel without problems. But haven't tested with CM, so can't say for sure
[Galaxy S 4 Active Original Android Development] pen²:
Runs well with cm 11
[Galaxy S 4 Active Original Android Development] atfaniqbal:
Where is 4.4.2 stock rom version? ?
[Galaxy S 4 Active Original Android Development] spegelius:
There is none
[Galaxy S 4 Active Original Android Development] spegelius:
No there's a verson for TW roms too. Props again for [MENTION=4325945]ktoonsez[/MENTION] for awesome base to work on :). It's great that these devices are so close to each other, it's quite easy to make jf kernels work with jactive.

I also added KEXEC_HARDBOOT support so it works with MultiROM.
[Galaxy S 4 Active Original Android Development] spegelius:
There seems to be some problems with the kernel and more investigations is needed. So probably not a good idea to take in use if phone stability is required
[Galaxy S 4 Active Original Android Development] JASONRR:
Kernel seems to work fine in normal usage other than the unresponsive touchscreen after wake up from deep sleep experienced twice in 2 days of usage. Hard boot restart fixes the issue.

Wifi, bluetooth in car for voice and music, GPS all good except slightly little more battery drain than stock (not too much to be a bother)

Good job!!! Can't thank you enough firstly for the CM builds and now this kernel.

Maybe when you have time, it wojld be nice if you can look at the touchscreen issue.
[Galaxy S 4 Active Original Android Development] Pkt_Lnt:
I'm running it on your AOSP 4.4.4 build (current build and kernel) as a daily driver with absolutely no problems. I use the profiles and scripts from the KTweaker as well for extra battery life.
[Galaxy S 4 Active Original Android Development] spegelius:
Yes, there seems to be some problem with phone waking up, i had mine go completely unresponsive this morning. I'll try to get a last_kmsg to see what the problem is. Some of the KT enhancements related to turning stuff on and off when screen is off probably. Also the unresponsive touchscreen was there, couldn't unlock the phone.

I also noticed that overclocking doesn't seem to work, at least the monitoring sw seems to show max clocks at 1674MHz no matter what i set them at.

Nice. An unpdate is due, i merged all the changes from KT's github and there's a new version coming, for CM12 also. Sadly that won't work with AOSP until i update the rom to support newer props and ril stuff.
[Galaxy S 4 Active Original Android Development] Saalschlacht:
I'm waiting for a kernel with CPU OC and fast Charging...

I'm a great Fan of Boeffla Kernel, but he don't support our SGS4A... So i hope on your work.

I really impressed by your cm12 port and i never will miss it!

Is there a way to read the reference value of charging current by loading chip?

Gesendet von meinem GT-I9295 mit Tapatalk
[Galaxy S 4 Active Original Android Development] spegelius:
CM12 kernel is in the works, one version boots but there's a problem with RIL, no phone. Seems somekind of race condition during boot... work in progress.

Not sure about the charging current, haven't looked into the code that much. Possibly...

New TW version available, KT-SGS4-KK4.4-TW-eur-01.03.2015.zip. Spent two days debugging why my max clocks were limited to 1640MHz... turns out there's no problem with the kernel, some external program was limiting the max clocks and quite aggressively, too (60 C and down to 1640 we go and can't go back to 1890 anymore). Don't know if this a special feature of WizCyan or some Samsung crapware... I didn't find the process doing this, but instead disabled to limit option in kernel. Do keep this in mind; i haven't got any overheating or such, KT kernel handles this fine.

Also do keep in mind that if you don't set oc settings in boot, you need to use KTweaker app and reset the cpu min and max sliders for the settings to take effect. Even though the app asks if you want to apply the settings, it doesn't update the actual min and max values.

Changes:

overclocking works better now

increased touchscreen min limit freq, hopefully removes problem with unresposiveness

built with Linaro 4.7.12.10
[Galaxy S 4 Active Original Android Development] JASONRR:
After using the new TW kernel for a day and a half, Power consumption is much better compared to the previous one; Almost same as stock using 'asking alexandria' profile. However touchscreen issue still remains, I have a feeling that it could be that the touch response is active after screen is off causing it to hang. When the touchscreen becoms unresponsive and active display gets activated the screen flickers on touch.
[Galaxy S 4 Active Original Android Development] spegelius:
I only had that kind of problems in lock screen a couple of times, couldn't unlock due to the problem. I got out of it by pressing power key to show power menu, after that it started working ok. Been over two seeks since last time that happened, was waiting for it to happen again so i could get a logcat. Most of the time been running the previous version of this kernel, occasionally booting to AOSP or CM12. If you can, take a logcat when the problem is happening.
[Galaxy S 4 Active Original Android Development] JASONRR:
This seems to only happen when the phone is up without restart for over 20-24 hours.

I had the issue again but got out after pressing the power key several times (putting it to sleep and waking it up). Attached is the logcat, the touchscreen freeze occurred between 20:52 and 20:54.

Thanks for looking into the issue
[Galaxy S 4 Active Original Android Development] spegelius:
Thanks, had a look at the file an nothing really obvious problem was seen. I suspect possible error or debug messages from kernel are more likely to be in dmesg. I'll leave my phone on WizCyan for today and tomorrow, hopefully i can get the error reproduced. Also if you can get dmesg prints, that'll help also.
[Galaxy S 4 Active Original Android Development] spegelius:
Do you use headphones by any change? I got the unresponsive screen problem this morning, after only about 16 hours usage. It happened after cycling to work, using Sports Tracker to track it and listening music. Phone worked fine when stopping the tracking and music, but sometime afterwards it was unresponsive when trying to unlock. I suspect removing headphones might have caused this... or stopping music. In previous occasions, while using Sports Tracker, but not listening to music, the phone has been working fine.
[Galaxy S 4 Active Original Android Development] JASONRR:
I do not use headphones. It happened again this morning (had rebooted the phone at night and switched to flight mode). The alarm went off and I was unable to turn it off as the touchscreen was not responding, only managed to silence it with the volume button. Tried with the power, home, back & menu buttons several times to no avail. Finally long press of back key got the touchscreen to respond back. This is the most common occurrence for me along with a couple of times when left idle to charge. Attached is the dmesg taken this morning if it can help.
[Galaxy S 4 Active Original Android Development] spegelius:
Ok, didn't get anything meaningful from the dmesg yet. However, added some debug prints to touchscreen source, new build KT-SGS4-KK4.4-TW-eur-01.08.2015_debug1.zip available in GDrive (debug folder). If/when the problem occurs, take another dmesg. There are some additions in KT kernel where a function that seems to release all fingers is called quite a lot. Let's see if it is the culprit...
[Galaxy S 4 Active Original Android Development] JASONRR:
Ok will install and check. Occurred once again just now while left to charge and again could get it to work keeping the back key pressed for a few seconds.
[Galaxy S 4 Active Original Android Development] JASONRR:
Attached are the logcat and the dmesg. had installed the kernel and let to charge and the touchscreen froze again immediately this time and does not come off even after long pressing the back key now
[Galaxy S 4 Active Original Android Development] spegelius:
Alright, none of the debugs i added shown on the logs so the parts i thought would be the culprit aren't causing this problem.

Question1: how did you take the dmesg (for both of the logs)? Immediately after noticing the unresponsiveness or only after the situation was cleared? I'm asking because dmesg log is only certain size and if waiting too long, the relevant lines might be lost.

Question2: is wlan on and do you have AP defined? I'm interested about this because my phone seems to get unresponsive only in the morning, when i get to work and to my desk. Happened two times on a row now.

The differences to my home location are:

1. there are few wlan APs at work, but i haven't registered them, i.e. they aren't know to my phone. At home, i have two wlan APs registered.

2. when travelling with bicycle, i sports tracker and listen to music with headphones.
[Galaxy S 4 Active Original Android Development] JASONRR:
The first dmseg was taken from the phone itself through the ktweaker app, the 2nd one along with logcat was taken through computer with adb when the touchscreen was not responding & logcat was showing that screen is off (at the end of logcat) while it was on but not responding (maybe this could be it).

My wifi is always on and connected to my home network (there are others available but not registered). But then most of the time this happens when my phone is on flight mode and in the morning when the alarm wakes up the phone. The 2nd dmseg was taken in the night when the phone was connected to wifi and left idle for charging (no notifications received during this time).
[Galaxy S 4 Active Original Android Development] spegelius:
Ok, i might found the problem: i was going through ktoonsez later changes to kernel and started looking at the touchscreen code from different place. Tracing some functions back, i got to the point where KT kernel differs from stock kernel. But the KT specific stuff was compiled only for jf boards, not jactive. Copied that code to jactive portion. The code i copied is the KT specific code for turning touchscreen on and off. Seems that specific type of screen on/off commands have been missing all the time, and touchscreen has been turning on by change (or hasn't turned properly off for most of the time, dunno).

Anyway, new build is on the debug folder: KT-SGS4-KK4.4-TW-eur-01.09.2015_debug2.zip
[Galaxy S 4 Active Original Android Development] JASONRR:
Thanks!!! After over 2 days of usage the issue has not come up, so we can say the touchscreen issue is fixed.
[Galaxy S 4 Active Original Android Development] spegelius:
:good: good to hear :). I'll make an official release build later, which will be essentially the same you are running now.
[Galaxy S 4 Active Original Android Development] JASONRR:
Just wanted to let you know. You can do it whenever you find the time.
[Galaxy S 4 Active Original Android Development] spegelius:
New TW kernel release, ver 01.12.2015:

Changes:

Fixed unresponsive screen bug

Compiled on Linaro 4.9-2014.09
[Galaxy S 4 Active Original Android Development] spegelius:
Experimental CM11 KT kernel ALPHA1-01.12.2015

I'm releasing a build for CM11/AOSP (for AOSP 1.x.x only) for testing. It's alpha because there's some strange bug:

phone might reboot itself during boot or right after boot

if phone survives the boot, it seems stable

Now i've yet to find plausible reason for this, but things like somehow unclean work area after switching from TW branch to AOSP branch could be a reason, some of the optimised build flags or even Multirom that i'm using.

Before installing, make sure you have a working boot.img somewhere, preferably make a backup in CWM or TW recovery, you can restore only boot.img if needed. I'll make a CWM zip later with recent CM11 boot.img.

Reports appreciated.
[Galaxy S 4 Active Original Android Development] atfaniqbal:
Where is the download link for 4.4.2 stock rom version [KERNEL][I9295][TW-4.4]KT-SGS4 port for Active Intl ??????
[Galaxy S 4 Active Original Android Development] JASONRR:
Check the bottom of the op 'Download here:' with a link to Gdrive from where you can download the kernel