yashsingh1/xdaforums huggingface dataset:
[Moto G Original Android Development] DoctorStrange96:
Here's our first beta for R5. I labelled this build as a beta because I'm pretty damn sure that there'll be quite a few people that will have issues.

Changes in this release:

- AnyKernel installation method has been changed (zImage + dt.img instead of zImage-dtb)

- Updated with latest CM & kwoktopus' patches

- SELinux set back to Enforcing (read below for more info)

- Added toggles for bluetooth wakelocks

Note: This build will be available in "standard" and Permissive flavours. Standard keeps SELinux configurable (we all know Android will always set it to Enforcing because of how paranoid Google is), and Permissive, well... It will force it to stay in Permissive mode, without giving you the ability to set it back to Enforcing. If you cant see yourself living without system-mode SuperSU or other mods, Permissive is the only way to go. Now if you're like me and has embraced systemless style, choose either flavour, both shall work.

Note 2: You MUST flash the new stock boot image (the one from the OP, neither the dummy titan kernel, nor any untested stock kernel zip!!) before flashing this build, because of the AnyKernel change I mentioned above. Skip this step and you'll have that dreaded "Fastboot Reason: Fall-through from normal boot mode" message. If you use systemless mods, you'll have to reinstall them all. Flashing over R4 still works. No need to revert to the stock image.

Pick yo' link!
[Moto G Original Android Development] DoctorStrange96:
Stock kernel zips added to the OP.

And here are new, untested stock kernel zips. In case they bring issues (and i'm quite sure they will), you can revert to the old, tested zips.

Falcon standard

Falcon w/ forced permissive SELinux

Peregrine standard

Peregrine w/ forced permissive SELinux
[Moto G Original Android Development] woozie.2007:
kaminari, thanks for this, if i have R3 installed, what kind of R4 i must install? standard or permissive? thanks
[Moto G Original Android Development] Wyneg:
I installed first new stock boot image from OP

(is this, right?

Quote:

Wanna go back to the stock kernel? Then flash one of these!

Falcon

Peregrine)

And after the new R5, and (again) I lost network... I flashed backup and installed R5 over R4 and all is OK.

¿?

Thanks!
[Moto G Original Android Development] DoctorStrange96:
Depends on what mods you use. If you use system-mode SuperSU and/or Xposed, go with Permissive. If you use systemless, you can choose either one.
[Moto G Original Android Development] woozie.2007:
Thank you, i use supersu and xposed, i installed permissive in the morning, untill now its perfect
[Moto G Original Android Development] Haggster66:
flashed the R5 beta standard version for falcon on top of the already running R4 without anything in between and everything runs as always without issues.

Kept my kernel aduitor settings unchanged and since people keep mentioning they're running xposed: I'm running it with various modules as well.

All of that on the most current IDcrisis ROM, the GNL version.

still very happy, I would even donate if I could.
[Moto G Original Android Development] mobilematrix:
How do you install multirom? I have installed the MultiROM Manager from Google Play but it reports:
[Moto G Original Android Development] wagmic:
R5 issue

hi first thanks for the job, the R5 [peregrine] doesn't work for me i have comming back to R4.

merci encore
[Moto G Original Android Development] DoctorStrange96:
Send me some logs. Try using the permissive version as well.
[Moto G Original Android Development] Haggster66:
do the latest kernel versions have the Adreno Idler integrated? I'm running R5 and I can't see it within Kernel Adiutor, but the GPU seems to use proper frequency scaling, instead of constantly jumping from the lowest to the maximum frequency.
[Moto G Original Android Development] :
I have a problem. I do not know why, but the kernel heats up my phone more than stock kernel. Let's do something about it? I have r5 beta 1.

Wysłane z mojego XT1063 przy użyciu Tapatalka
[Moto G Original Android Development] n0elite:
What is the difference between the uses for Regular Version and Permissive Version? I'm running stock 6.0 (Identity Crisis).

Nvm: http://xdaforums.com/showpost.php?p=68150290&postcount=262
[Moto G Original Android Development] wagmic:
R5 issues solved

hi i have just install R5 permissive kernel all seems to be ok

i am sorry because i have Xposed :p and in the post higher you said to use permissive one but sometime i read to quickly sorry again.

Merci
[Moto G Original Android Development] DoctorStrange96:
No it doesnt have it. Im still thinking about adding it back.
[Moto G Original Android Development] DoctorStrange96:
No, you no longer need to dirty flash either the rom and/or the stock kernel. You can flash my kernel right away.

Flash the same zip that everyone uses, the standard one. Always use the latest version.

Only if I release a version that brings significant changes to the installation process, or if you're switching between standard and permissive versions. And dont flash that titan boot image. I think i put a new stock - and bootable - kernel in the OP. I'll clear up those instructions later.
[Moto G Original Android Development] DoctorStrange96:
Yes. This is to work around a bug on the install script's side. I'm yet to look into it.

I thought we were talking about SuperSU. If that's the case, download the zip from Chainfire's thread and flash it.

The CM13 kernel adaptation takes the titan image's place. The latter is called dummy because it doesn't boot (different zImage, different device tree blobs). All that matters inside it is the ramdisk. So I grabbed it, modified it, put it into a image together with a bootable CM13 zImage, and the result is the new stock kernel.
[Moto G Original Android Development] SbM_:
Installed it today on top of Identity Crisis 6. Seems to work just great. I'll wait for a few weeks to be sure and then I'll send a well-deserved donation. Thanks a lot and keep up the good work!
[Moto G Original Android Development] Choochter:
Try this:

http://xdaforums.com/android/software-hacking/mod-gov-tuner-project-29th-june-2016-t3407828
[Moto G Original Android Development] DoctorStrange96:
Not /root (/), but /sdcard (internal storage). Place it exactly there, dont flash it from /sdcard/Download or any other subfolder. You can also download the zip to your computer and sideload it to your phone via adb. I'm telling you to do this because this new stock kernel uses a install script which is almost identical to the custom kernel zips' one. So they both have the same bug.
[Moto G Original Android Development] sbarrenechea:
Hi!

Thanks for this great kernel! But a note related to R5 Beta 1:

On Peregrine, the Wi-Fi is dead, MAC says 02:00:00:00:00 and of course can't enable it.

Using permissive on Identity Crisis.
[Moto G Original Android Development] mobilematrix:
Has anyone performed a performance comparison between stock kernel and this one?
[Moto G Original Android Development] Choochter:
Did you follow the instructions in the post above yours?
[Moto G Original Android Development] NIGH7MARE:
Will future updates include back new governors? I checked the OP and all governors there are "no more" but i wish i had the option to choose yankactive governor with this kernel... Whats the reason to take them out?
[Moto G Original Android Development] DoctorStrange96:
Some govs were causing massive battery drain. Your dear yankactive was one of them.
[Moto G Original Android Development] moofesr:
Does this kernel include support for the Xiaomi Piston 3 key mod?
[Moto G Original Android Development] BryanByteZ:
Use interactive + GovTuner
[Moto G Original Android Development] DoctorStrange96:
Yes. CM merged the necessary kernel patch a long time ago. This kernel is CM based so it includes said patch.
[Moto G Original Android Development] DoctorStrange96:
Oh, if anyone wants to know what I use to build this kernel, then there you go. I use Fedora 24, which is rock solid (unlike *buntu) and a custom built Linaro 4.9 optimized for Cortex-A7. I believe the 3.4.x kernel wasn't really designed to be compiled with gcc >= 5.0 (it requires quite a load of hacks to get it to compile) hence why I use this version of gcc. I wish I could build it using clang though. Havent tested other linux distros as well (Arch, openSUSE...).
[Moto G Original Android Development] BryanByteZ:
Do you build the GCC or is prebuilt?
[Moto G Original Android Development] DoctorStrange96:
Prebuilt
[Moto G Original Android Development] lost101:
[MENTION=5736790]Kamin4ri[/MENTION] - Could you clarify the situation regarding the Stock Kernels (Adapted from CM13). The test versions in post #263 above - how are they different from the version in OP?
[Moto G Original Android Development] DoctorStrange96:
They've been packaged differently. They could potentially cause trouble due to how the ramdisk was packed.
[Moto G Original Android Development] lost101:
I will be needing a 'Permissive' Stock Kernel for IDCrisis6 v1.4. No obvious issues with the Permissive Stock Test kernel so far.
[Moto G Original Android Development] leo4b:
Works on CM13? No boot here when I tried.
[Moto G Original Android Development] koshikas:
nope this kernel is exclusively for IDCrisis 2.0 stock ROMs. there is a Kamineri CM13 kernel (in a separate thread) although i'm not sure whether its up to date. You may also try hurstsky valkrie kernel or bryanbytez zero-byte kernel for CM13
[Moto G Original Android Development] DoctorStrange96:
KaminariCM R3 will be released later today.
[Moto G Original Android Development] DoctorStrange96:
Kernel updated to R5. Its the same thing as beta 1 but with the latest patches from cm. All download links are in the OP.
[Moto G Original Android Development] DoctorStrange96:
Guys I'm gonna need your help.

I'm gonna do an experiment here.

I'll format the three core partitions (cache, data*, system) to f2fs and see how the device performs after that. (Cache and system are formatted to ext4 by default).

Of course this will require ramdisk mods but i can take care of that.

My request is: can someone here build me a custom TWRP that supports both /cache and /system on f2fs?

*Data is already formatted to f2fs on non-GPE phones (which is my phone's case) so i wont format it.
[Moto G Original Android Development] lost101:
[MENTION=4792450]h2o64[/MENTION] - have you any thoughts on this concept?
[Moto G Original Android Development] h2o64:
It's possible (some bacon roms do it) if you refer to the twrp patch I'll post one this afternoon.

If you refer to ramdisk changes, just make sure that all partition are mounted through fstab (and not manually)

If you refer to benchmark, you should use bionic benchmark or classic Linux memcpy ones (goal is to benchmark i/o)

---------- Post added at 10:54 AM ---------- Previous post was at 10:18 AM ----------

Here is my suggestion for the TWRP edit : https://github.com/h2o64/android_de...mmit/02997e6cb9a5fb8e45b9803fa917bbde5ca43663

From 02997e6cb9a5fb8e45b9803fa917bbde5ca43663 Mon Sep 17 00:00:00 2001
From: Louis Popi <theh2o64@gmail.com>
Date: Sat, 3 Sep 2016 10:48:18 +0200
Subject: [PATCH] falcon: Add a script to detect if cache or system are f2fs

---
recovery/root/f2fs-changer | 21 +++++++++++++++++++++
recovery/root/init.recovery.qcom.rc | 6 ++++++
2 files changed, 27 insertions(+)
create mode 100755 recovery/root/f2fs-changer

diff --git a/recovery/root/f2fs-changer b/recovery/root/f2fs-changer
new file mode 100755
index 0000000..b6b2ce8
--- /dev/null
+++ b/recovery/root/f2fs-changer
@@ -0,0 +1,21 @@
+#!/sbin/sh
+
+function change_fs() {
+
+BDEV=`/sbin/busybox readlink /dev/block/platform/msm_sdcc.1/by-name/$1`
+FSTYPE=`/sbin/busybox blkid $BDEV | /sbin/busybox cut -d ' ' -f3 | /sbin/busybox cut -d '"' -f2`
+
+ if [ "$FSTYPE" == "ext4" ] then
+ sed -i '/'$1'/s/f2fs/ext4/g' /etc/recovery.fstab;
+ sed -i '/'$1'/s/f2fs/ext4/g' /etc/twrp.fstab;
+ fi
+
+}
+
+# Change to f2fs for system and cache
+# as userdata is already handled by
+# gpe-detect
+
+change_fs system
+change_fs cache
+
diff --git a/recovery/root/init.recovery.qcom.rc b/recovery/root/init.recovery.qcom.rc
index 5208b3f..c0ff43a 100644
--- a/recovery/root/init.recovery.qcom.rc
+++ b/recovery/root/init.recovery.qcom.rc
@@ -13,6 +13,12 @@ on init
wait /dev/block/platform/msm_sdcc.1/by-name/userdata
exec /sbin/detect-gpe

+ # Change system or cache to f2fs
+ wait /dev/block/platform/msm_sdcc.1/by-name/system
+ wait /dev/block/platform/msm_sdcc.1/by-name/cache
+ chmod 755 /f2fs-changer
+ exec /f2fs-changer
+
on boot
write /sys/module/lpm_levels/enable_low_power/l2 3
write /sys/module/msm_pm/modes/cpu0/power_collapse/suspend_enabled 1
[Moto G Original Android Development] Biz92k:
Installed the R5 (regular) over the R5beta1 (permissive) this morning, no issues so far.

Just no dt2w showing up in Kernel Adiutor for me! :(

As always thanks for your awesome work! :D
[Moto G Original Android Development] DoctorStrange96:
I removed it a while ago.
[Moto G Original Android Development] DoctorStrange96:
The problem is that i dont know how to build twrp :( . And i would like this patch to be tested against the latest official twrp release for falcon (which is 3.0.2-0 as of now).
[Moto G Original Android Development] h2o64:
Here are the steps :

# Setup a working dir
$ mkdir OMNIROM
$ cd OMNIROM
# Sync OmniROM Marshmallow
$ repo init -u git://github.com/omnirom/android.git -b android-6.0
$ repo sync -c -j8
# Download falcon tree
$ git clone https://github.com/TeamWin/android_device_motorola_falcon -b android-6.0 device/motorola/falcon
# Apply my patch
$ cd device/motorola/falcon
$ git fetch https://github.com/h2o64/android_device_motorola_falcon android-6.0-f2fs
$ git cherry-pick 02997e6cb9a5fb8e45b9803fa917bbde5ca43663
$ cd ../../..
# Lunch and build
$ . build/envsetup.sh
$ lunch omni_falcon-userdebug
$ make -j8 recoveryimage
[Moto G Original Android Development] Biz92k:
I was aware of that, but I saw it again in the features in the OP, so I thought it was back... Just that!
[Moto G Original Android Development] Haggster66:
flashed the new one on top of the beta, from /sdcard/.

Both versions, old and new, are/were enforced in regards to SELinux

Working without the slightest of issues, mega smooth.

So the new one has HZ=300? If it does than this is great, should make things more responsive.

As always, keep it up! And btw, great idea regarding f2fs on system and cache. I think it should make a small difference if cache is formatted as f2fs, /system not so much, but then again, it would make more sense to format all partitions with the same fs.

Most likely the speed gains won't be huge though, because obviously most writes happen on the data partition. I strongly assume that this is also why on stock, only that partition is formatted with f2fs.

BTW, I was wondering, you've got commit 2dd9976e1fadaaee320239a4a671032374f8a869 , but that is only one patch out of the three-piece patch set from here: https://lkml.org/lkml/2011/5/11/144 . In order to make SLUB work nicely, all three patches would be required (the patches for page_alloc.c are optional). I'm using all three patches for my own kernel and it works/compiles without issues. Otherwise I would consider switching to SLAB, which is known to work better on low-mem devices such as ours.

Anyway, soon I'll be using this kernel (well, the codebase has totally changed, lol) for a year and they're not getting worse, so keep them coming ;)
[Moto G Original Android Development] DoctorStrange96:
Nevermind :p . I havent enough disk space to download the whole android source code...
[Moto G Original Android Development] DoctorStrange96:
Could you please link me those patches?

Edit: Yeah, new codebase (CM this time :p ). And thanks!
[Moto G Original Android Development] DoctorStrange96:
For those who want CPU overclock... Here goes a TEST build. This time with a 1.73 GHz (!!!) overclock.

This build has:

* MSM Hotplug (mpdecision is gone)

* Kwoktopus' simplified msm-thermal driver

* Forced permissive selinux (custom thermal driver causes denials all the damn time)

* Usb fast charge

Fast charge might eventually make it to the stable builds.
[Moto G Original Android Development] himu_joy:
so u guys does not letting our MoTo G old? everything possible on this cutee? Impossible machine....impossible developer all there.....

thanks all.

NB: fast charge, mean now can get charge over 2A.? normally I got 1.2A max.
[Moto G Original Android Development] Haggster66:
there you go (you already got the second one);

https://lkml.org/lkml/diff/2011/5/11/46/1

https://lkml.org/lkml/diff/2011/5/11/228/1

https://lkml.org/lkml/diff/2011/5/11/143/1

The first one might or might not cause problems when trying to patch page_alloc.c - but that part can be omitted without problems, so you can remove that part from the patch but apply the rest which modifies SLUB itself.

This should make things smoother when memory is low (which is basically all of the time on a 1GB device).
[Moto G Original Android Development] DoctorStrange96:
Funny, isnt it? This little damn phone simply refuses to die! :p

About the charging current, i never measured it myself, so i cant tell...
[Moto G Original Android Development] BryanByteZ:
How much space it takes? maybe i can give a try.
[Moto G Original Android Development] DoctorStrange96:
I dont know exactly. But i assume its in the order of gigabytes (no less than 5 GB to be more exact).
[Moto G Original Android Development] h2o64:
Lol, happy to see that my oc never gets old.

PS : Be aware when you're touching those cpu corner dt, moto modified msm8x26 a bit and porting dt from other devices isn't very great (on long term)
[Moto G Original Android Development] himu_joy:
yah dear, funny thing is I've refused to switch g2/g3 because of g1's better ppi display. its unique, and I don't like more then 4.5" display.

just tell me, for what feature u telling "fast charge" term?
[Moto G Original Android Development] xenas:
I'm testing the latest kaminari kernel with OC, on the latest finest Rom provided by the master lost, and for now everything is running smoothly.

Thanks for the excellent work and keep it up buddy.
[Moto G Original Android Development] Penemue:
I'm very happy with R5 for now. Biggest change I noticed is that navigating in the phone, using the drawer and recents are feeling much more smoother somehow. Especially with recents, there was always a little lag for me before.
[Moto G Original Android Development] razlack:
Hey guys, this is slightly off topic but I have read that disabling zram can reduce lag on devices. Does anyone know how to disable zram on this device? I have googled until and tried so many things that I have almost given up. I don't want to remove this from the device permanently, just have a script to disable it if this is possible. Anyone have any ideas?
[Moto G Original Android Development] Choochter:
Doesn't that advice just apply to devices with more RAM than the Moto G?
[Moto G Original Android Development] Haggster66:
swapoff /dev/block/zram0

put that into an init.d script. and make sure apps like kernel Adiutor don't add zram again after this.

Or just use kernel Adiutor go to "on boot" and remove all lines related to zram, apart from the "swapoff" one that is already there.

BTW, I'm even increasing the stock 250MB of zram to 400MB. Decompressing a swapped out app from zram "should" be faster than re-launching apps from scratch constantly, because they keep getting killed.
[Moto G Original Android Development] zeratos:
Can I flash this over the latest cm13 snapshot?

Does over clocking really works?

I was searching about this today and everyone said it was impossible to ovet clock this phone
[Moto G Original Android Development] razlack:
Thanks, I couldn't get this working. I have decided to give up on disabling zram. Not sure if there is any point to be honest.:silly:
[Moto G Original Android Development] BryanByteZ:
Is not anymore this is based on zakee94 and h2o64 commits it really works.
[Moto G Original Android Development] Haggster66:
it really works, I can tell from having it in my pocket. I'm completely toasting the device and loving it. works well with Max frequency set to 1.4GHz, Min frequency to 0.7GHz and boost to 1.1GHz.

gentle fair sleepers activated. I like it so far, my battery probably doesn't.

just waiting until the first stains will appear on the display near where the cpu sits
[Moto G Original Android Development] zeratos:
Ok, can I flash it over CM13 latest snapshot?
[Moto G Original Android Development] Gabriele_Treglia:
Hi, I just recently installed the identity crisis 6 v. 1.4. On the old rom that I had I always used the kaminari kernel so I want to give it a try on this rom.

Is the latest version of the kernel the best one for the rom? And the one that I should install is regular or permissive version?

P. S. To flash it I just need to put it in the sdcard out of any folded and flash with a normal cache and dalvik wipe?

Inviato dal mio XT1063 utilizzando Tapatalk
[Moto G Original Android Development] con01:
Hello.

How to enable Dt2w in IC6 ?? I do not have any option in KernelAdiutor. Kernel Kaminari-R5-Falcon
[Moto G Original Android Development] Choochter:
It's no longer supported, despite what it says in the OP
[Moto G Original Android Development] NinjaFlood:
[MENTION=5736790]Kamin4ri[/MENTION] what are your thougths on the underclock and overclock frecuencies with updated volts BryanBytez applied on his kernel? Is it worth it to add it in this kernel?
[Moto G Original Android Development] nicoconunac:
Performance improved a lot in last build but at the same time battery got way more worse. Any way to rebalance battery life? I think the reason is due to the 998mhz min cpu frequency when the phone is awake maybe? What do you suggest to improve battery life again as the previous versions? Changing Governor maybe?
[Moto G Original Android Development] DoctorStrange96:
You must flash the version from the CM kernel thread, not this one. There's a link to the thread in my signature ;)
[Moto G Original Android Development] DoctorStrange96:
Honestly idk. I didnt mess with the frequencies.
[Moto G Original Android Development] DoctorStrange96:
Im still skeptical tbh. Underclocking breaks some stuff. Overclocking brought little to no performance difference in my tests. I'll think about it.
[Moto G Original Android Development] DoctorStrange96:
1. You should always flash the latest version. Use an older version if the latest is giving you problems.

2. System-mode root / xposed: Permissive. Systemless: Either version.

3. Put it in /sdcard. Cache wipes are not needed.
[Moto G Original Android Development] tme_007:
Hi [MENTION=307048]kaminari[/MENTION]

I tried your CM13 Peregrine version of this kernel on my CM13 snapshot (Peregrine) and phone didn't boot anymore.

Only flashing back complete CM13 snapshot ROM solved the problem.

Obviously, I followed your instructions by placing ZIP file in /sdcard and flashing from this location :)

So I'm back on Hurtsky Simpler kernel ...

---> Ooops my fault, didn't downloaded correct kernel since I was navigating on both kernel threads (IDCrisis and CM13) and I focused for Peregrine when looking at links :)
[Moto G Original Android Development] Biz92k:
As I said here, I found a little issue with Magisk and the kernel version of R5.

If I am on the permissive version everything works, but I can't switch the selinux to enforced, as it stays locked (and eventually switches back) on permissive. Then, because Magisk is supposed to make root systemless, I tried install the Regular R5 but it doesn't boot. What I did wrong?
[Moto G Original Android Development] DoctorStrange96:
Motorola roms need a sepolicy patch to boot correctly. And since its a closed source rom there's nothing we can do here (unless already built sepolicies can be patched).
[Moto G Original Android Development] Biz92k:
Alright, I thought I made something wrong! Anyway, that's the reason I can't edit anything permanently in the kernel? Like e.g. the host name or hotplugs that keep on revert on the original settings on reboot?

(I still would love to see dt2w back :D)
[Moto G Original Android Development] h2o64:
They can be patched (that's how super su installs)