Development [Kernel][03.05.2022][Android 12.1.0][Android 12.1.0 QPR Beta 2] Kirisakura 2.4.0 for Pixel 6/Pro aka "RAVIOLE"

Search This thread

KedarWolf

Senior Member
Apr 27, 2012
295
157

Worked for me, but you'll want for a public way to fix magisk. Which I doubt will take long

Alpha version of Magisk fixes root on December update, but 1.3.0 kernel still not working with the latest update.

 
  • Like
Reactions: roirraW "edor" ehT
Alpha version of Magisk fixes root on December update, but 1.3.0 kernel still not working with the latest update.

Freaks own screenshot shows there's a test version, 1.4.0, already for December build. :)
 

Freak07

Recognized Developer / Recognized Contributor
Jan 2, 2011
5,538
18,356
Just a heads up. The next update is ready. However I'm waiting for google to push the tag to be able to use the full AOSP environment with the December tag for pixel 6/pro. So far they haven't pushed it, only for devices up to pixel 5.

The kernel is ready, but in order to ship the full update in a proper working state, i need the full AOSP environment from now on, not only the kernel build environment.

So for the time being the release is ready, but still under testing and waiting for google to push.

There will be lots of changes, updates and improvements coming this month for this kernel (maybe not with the next release for December source, but eventually in time as a nice little Christmas gift for our toy if testing goes well :) )

I'm wishing everybody a nice day.

View attachment 5482107

Christmas might come a little early as I decided to release the big changes I had intended for later this month with todays release. Will be a big update so stay tuned.

:)
 

Texan1

Senior Member
Christmas might come a little early as I decided to release the big changes I had intended for later this month with todays release. Will be a big update so stay tuned.

:)
You're a good man @Freak07 ! (y)

Am assuming you'll update the OP if flashing instructions are different this time. I'm running the 'special' December version of Magisk that was released to make sure it worked with the December patch so don't know if that will make any difference to flashing new Kirisakura.
 

Freak07

Recognized Developer / Recognized Contributor
Jan 2, 2011
5,538
18,356
You're a good man @Freak07 ! (y)

Am assuming you'll update the OP if flashing instructions are different this time. I'm running the 'special' December version of Magisk that was released to make sure it worked with the December patch so don't know if that will make any difference to flashing new Kirisakura.
yes, I´ll update the instructions :)

there´s an official new canary pushed on the magisk github site, I think it´s best to use this, but in the end it shouldn´t matter (y)
 

Freak07

Recognized Developer / Recognized Contributor
Jan 2, 2011
5,538
18,356
Update to 1.4.0

Hey guys and girls,

Alright here´s the next update and it´s a really big one. There are several significant changes in this release.
Please read through the whole post to understand the changes.

Flashable kernel.zip
I decided to ship the kernel now as a flashable zip. (thanks to @eng_stk and @osm0sis)
I was hesitant to do this at first, since vendor_dlkm is part of super. That means it´s no ordinary partition, which is the reason vendor_dlkm needs to be flashed in fastbootd. Luckily simply dd´ing vendor_dlkm does still work as a bandaid on a running device, until we find a way to "properly" flash vendor_dlkm to super. But for now that way works and is sufficient. What´s more important, I couldn´t cause havoc when I tried.
That means no more flashing via fastboot. The kernel can be flashed via EXKM or FKM app. Due to ramdisk in vendor_boot being different on Pixel 6 (oriole) and Pixel 6 Pro (raven) there are two seperate zips now.
That means this project is now completely like I envisioned it in the beginning. The prior release missed several improvements that ended up in the kernel modules, which sit in vendor_boot.img.
Since we´re flashing all four images now, module verification can be enforced and I don´t need to force load the kernel modules from the stock vendor_boot any longer.
Flashing the kernel.zip will preserve root.
Shipping the kernel.zip will allow for easier flashing and for several other changes to be installed when flashing the kernel.zips, which also brings us to the next change.

Flashable kernel.zip - AK3 Helper Module
The kernel.zip flashes now all four images that are related to the kernel. boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img.
Alongside the kernel.zip a magisk module called AK3 Helper Module will be flashed. It will show up in magisk manager after the reboot following the flash of the kernel.zip. Do not delete this module, it ships a modified powerhal, which is an integral part to the changes in this release.
The powerhal will also restrict CPU-Freqs when the screen is off to save battery during e.g. music/podcast playback.l
If you used the old powerhint module, please remove that before flashing the kernel.zip.

Improvements to the Scheduler/Powerhal - Pelt Multiplier
Next big change, the pelt multiplier. This commit allows to change pelt half-life during runtime, instead of choosing before compilation as was the only way in the past.
Straight from the documentation:
prompt "Utilization's PELT half-Life"
default PELT_UTIL_HALFLIFE_32
help
Allows choosing one of the possible values for the PELT half-life to
be used for the update of the utilization of tasks and CPUs.
The half-life is the amount of [ms] required by the PELT signal to
build up to 50% utilization. The higher the half-life the longer it
takes for a task to be represented as a big one.

If not sure, use the default of 32 ms.

config PELT_UTIL_HALFLIFE_32
bool "32 ms, default for server"

config PELT_UTIL_HALFLIFE_16
bool "16 ms, suggested for interactive workloads"
help
Use 16ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load twice as fast as for the default
configuration using 32ms.

config PELT_UTIL_HALFLIFE_8
bool "8 ms, very fast"
help
Use 8ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load four time as fast as for the default
configuration using 32ms.

Default is 32ms, however this value was changed for example by @kdrag0n on the pixel 5 kernel to 16ms to improve performance. The downside of this approach is, that this needs to be chosen at compilation time, and can´t be changed during runtime. choosing 16ms or lower can lead to higher energy consumption and less battery life, but also better performance.

The inclusion of the pelt multiplier, together with an edited powerhal allows this kernel now to change pelt half-life depending on workload and interaction while the device is running. If there are certain events like interaction (scrolling, touching the screen), app launches, camera launches, taking a picture the pelt half-life will get changed dynamically. Interaction will result in 16ms half-life while app launches and camera usage will result in 8ms half-life, resulting in a performance boost when performance is needed.
If there´s no interaction happening, half-life will bump back to default 32ms as to not waste battery.

Improvements to the scheduler - Prevent frequency spikes caused by small tasks
uclamp can cause frequency spikes, by small very frequently occurring tasks (such as binder ), as was identified by a few vendors already. The following commit from the ARM-Developers aims to improve this situation.

BFQ-IO Scheduler
BFQ is now on par with linux-mainline as those changes were backported

TCP - Improvements
A series of patches was backported for the commit mentioned by this article. It can be found in my kernel tree here

F2FS-Stable Improvments
Latest F2FS-Stable was merged and tested extensively.

Several other improvements are included as well. More details in the changelog.
Download is below.
Updated instructions in the OP!


Changelog:
- linux-stable 5.10.84
- kernel/common merged
- ship kernel as flashable zip
- ship complete gki kernel (boot, dtbo, vendor_boot, vendor_dlkm)
- include powerhal module in the flashable zip
- mainline backports to the scheduler
- introduce pelt multiplier and tie it into powerhal
- prevent frequency spikes by small transient tasks
- tcp backport from mainline
- bfq backports from mainline
- f2fs-stable included
wakelock blocker
- please read [URL="https://arstechnica.com/gadgets/2018/08/p-is-for-power-how-google-tests-tracks-and-improves-android-battery-life/"]this for further info
don´t use this to block any kernel wakelocks you think keep the device awake, most are needed for the device to properly function!
You won´t know about missed notifications until it´s too late. Random other issues might be introduced by blocking wakelocks.
This is only intended for use cases like, wifi at work causes endless wakelock and the IT admin says, screw you I won´t update the firmware. In that case this might be the only option for your device to sleep.
- other changes please look at my github


Download:


Instructions can be found in the OP! Please follow the instructions to avoid any issues.
If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.
 
Last edited:

Tomatot-

Senior Member
May 11, 2012
1,651
1,576
OnePlus 6
Update to 1.4.0

Hey guys and girls,

Alright here´s the next update and it´s a really big one. There are several significant changes in this release.
Please read through the whole post to understand the changes.

Flashable kernel.zip
I decided to ship the kernel now as a flashable zip. (thanks to @eng_stk and @osm0sis)
I was hesitant to do this at first, since vendor_dlkm is part of super. That means it´s no ordinary partition, which is the reason vendor_dlkm needs to be flashed in fastbootd. Luckily simply dd´ing vendor_dlkm does still work as a bandaid on a running device, until we find a way to "properly" flash vendor_dlkm to super. But for now that way works and is sufficient. What´s more important, I couldn´t cause havoc when I tried.
That means no more flashing via fastboot. The kernel can be flashed via EXKM or FKM app. Due to ramdisk in vendor_boot being different on Pixel 6 (oriole) and Pixel 6 Pro (raven) there are two seperate zips now.
That means this project is now completely like I envisioned it in the beginning. The prior release missed several improvements that ended up in the kernel modules, which sit in vendor_boot.img.
Since we´re flashing all four images now, module verification can be enforced and I don´t need to force load the kernel modules from the stock vendor_boot any longer.
Shipping the kernel.zip will allow for easier flashing and for several other changes to be installed when flashing the kernel.zips, which also brings us to the next change.

Flashable kernel.zip - AK3 Helper Module
The kernel.zip flashes now all four images that are related to the kernel. boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img.
Alongside the kernel.zip a magisk module called AK3 Helper Module will be flashed. It will show up in magisk manager after the reboot following the flash of the kernel.zip. Do not delete this module, it ships a modified powerhal, which is an integral part to the changes in this release.
The powerhal will also restrict CPU-Freqs when the screen is off to save battery during e.g. music/podcast playback.

Improvements to the Scheduler/Powerhal - Pelt Multiplier
Next big change, the pelt multiplier. This commit allows to change pelt half-life during runtime, instead of choosing before compilation as was the only way in the past.
Straight from the documentation:
prompt "Utilization's PELT half-Life"
default PELT_UTIL_HALFLIFE_32
help
Allows choosing one of the possible values for the PELT half-life to
be used for the update of the utilization of tasks and CPUs.
The half-life is the amount of [ms] required by the PELT signal to
build up to 50% utilization. The higher the half-life the longer it
takes for a task to be represented as a big one.

If not sure, use the default of 32 ms.

config PELT_UTIL_HALFLIFE_32
bool "32 ms, default for server"

config PELT_UTIL_HALFLIFE_16
bool "16 ms, suggested for interactive workloads"
help
Use 16ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load twice as fast as for the default
configuration using 32ms.

config PELT_UTIL_HALFLIFE_8
bool "8 ms, very fast"
help
Use 8ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load four time as fast as for the default
configuration using 32ms.

Default is 32ms, however this value was changed for example by @kdrag0n on the pixel 5 kernel to 16ms to improve performance. The downside of this approach is, that this needs to be chosen at compilation time, and can´t be changed during runtime. choosing 16ms or lower can lead to higher energy consumption and less battery life, but also better performance.

The inclusion of the pelt multiplier, together with an edited powerhal allows this kernel now to change pelt half-life depending on workload and interaction while the device is running. If there are certain events like interaction (scrolling, touching the screen), app launches, camera launches, taking a picture the pelt half-life will get changed dynamically. Interaction will result in 16ms half-life while app launches and camera usage will result in 8ms half-life, resulting in a performance boost when performance is needed.
If there´s no interaction happening, half-life will bump back to default 32ms as to not waste battery.

Improvements to the scheduler - Prevent frequency spikes caused by small tasks
uclamp can cause frequency spikes, by small very frequently occurring tasks (such as binder ), as was identified by a few vendors already. The following commit from the ARM-Developers aims to improve this situation.

BFQ-IO Scheduler
BFQ is now on par with linux-mainline as those changes were backported

TCP - Improvements
A series of patches was backported for the commit mentioned by this article. It can be found in my kernel tree here

F2FS-Stable Improvments
Latest F2FS-Stable was merged and tested extensively.

Several other improvements are included as well. More details in the changelog.
Download is below.
Updated instructions in the OP!


Changelog:
- linux-stable 5.10.84
- kernel/common merged
- ship kernel as flashable zip
- ship complete gki kernel (boot, dtbo, vendor_boot, vendor_dlkm)
- include powerhal module in the flashable zip
- mainline backports to the scheduler
- introduce pelt multiplier and tie it into powerhal
- prevent frequency spikes by small transient tasks
- tcp backport from mainline
- bfq backports from mainline
- f2fs-stable included
wakelock blocker
- please read [URL="https://arstechnica.com/gadgets/2018/08/p-is-for-power-how-google-tests-tracks-and-improves-android-battery-life/"]this for further info
don´t use this to block any kernel wakelocks you think keep the device awake, most are needed for the device to properly function! This is only intended for use cases like, wifi at work causes endless wakelock and the IT admin says, screw you I won´t update the firmware. In that case this might be the only option for your device to sleep.
- other changes please look at my github





Download:


Instructions can be found in the OP! Please follow the instructions to avoid any issues.
If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.
Thanks for the update, looks very promising. I have a few questions:
  • Is it still possible to flash img via fastboot & fastbootd? Not everyone paid / wants to pay for exkm or FKU. As an alternative, I can suggest SPKM https://play.google.com/store/apps/details?id=com.smartpack.kernelmanager.release&hl=fr&gl=US that is free and open source. I haven't checked personally if it works with this device and the vendor_dlkm image but I'd assume so.
  • To go back to stock kernel, same old instructions in the FAQ still apply? I heard people run into issues going back to stock after flashing bluspark.

Thanks!
 

Freak07

Recognized Developer / Recognized Contributor
Jan 2, 2011
5,538
18,356
Thanks for the update, looks very promising. I have a few questions:
  • Is it still possible to flash img via fastboot & fastbootd? Not everyone paid / wants to pay for exkm or FKU. As an alternative, I can suggest SPKM https://play.google.com/store/apps/details?id=com.smartpack.kernelmanager.release&hl=fr&gl=US that is free and open source. I haven't checked personally if it works with this device and the vendor_dlkm image but I'd assume so.
  • To go back to stock kernel, same old instructions in the FAQ still apply? I heard people run into issues going back to stock after flashing bluspark.

Thanks!
- i assumed this question would arise sooner or later. If the app can flash the zip, it should work just fine.
I can share the boot.imgs for raven/oriole. Then after extracting the other images, the four images and be flashed via fastboot.
I would also need to create a separate magisk module.
I can put all this in a separate folder and hope it doesn't create more confusion as actual benefit.

- before releasing i flashed back the four images several times without noticing problems. What kind of problems were encountered?
 

cd993

Senior Member
May 8, 2009
3,483
1,217
London
Samsung Galaxy S21 Ultra
Update to 1.4.0

Hey guys and girls,

Alright here´s the next update and it´s a really big one. There are several significant changes in this release.
Please read through the whole post to understand the changes.

Flashable kernel.zip
I decided to ship the kernel now as a flashable zip. (thanks to @eng_stk and @osm0sis)
I was hesitant to do this at first, since vendor_dlkm is part of super. That means it´s no ordinary partition, which is the reason vendor_dlkm needs to be flashed in fastbootd. Luckily simply dd´ing vendor_dlkm does still work as a bandaid on a running device, until we find a way to "properly" flash vendor_dlkm to super. But for now that way works and is sufficient. What´s more important, I couldn´t cause havoc when I tried.
That means no more flashing via fastboot. The kernel can be flashed via EXKM or FKM app. Due to ramdisk in vendor_boot being different on Pixel 6 (oriole) and Pixel 6 Pro (raven) there are two seperate zips now.
That means this project is now completely like I envisioned it in the beginning. The prior release missed several improvements that ended up in the kernel modules, which sit in vendor_boot.img.
Since we´re flashing all four images now, module verification can be enforced and I don´t need to force load the kernel modules from the stock vendor_boot any longer.
Shipping the kernel.zip will allow for easier flashing and for several other changes to be installed when flashing the kernel.zips, which also brings us to the next change.

Flashable kernel.zip - AK3 Helper Module
The kernel.zip flashes now all four images that are related to the kernel. boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img.
Alongside the kernel.zip a magisk module called AK3 Helper Module will be flashed. It will show up in magisk manager after the reboot following the flash of the kernel.zip. Do not delete this module, it ships a modified powerhal, which is an integral part to the changes in this release.
The powerhal will also restrict CPU-Freqs when the screen is off to save battery during e.g. music/podcast playback.l
If you used the old powerhint module, please remove that before flashing the kernel.zip.

Improvements to the Scheduler/Powerhal - Pelt Multiplier
Next big change, the pelt multiplier. This commit allows to change pelt half-life during runtime, instead of choosing before compilation as was the only way in the past.
Straight from the documentation:
prompt "Utilization's PELT half-Life"
default PELT_UTIL_HALFLIFE_32
help
Allows choosing one of the possible values for the PELT half-life to
be used for the update of the utilization of tasks and CPUs.
The half-life is the amount of [ms] required by the PELT signal to
build up to 50% utilization. The higher the half-life the longer it
takes for a task to be represented as a big one.

If not sure, use the default of 32 ms.

config PELT_UTIL_HALFLIFE_32
bool "32 ms, default for server"

config PELT_UTIL_HALFLIFE_16
bool "16 ms, suggested for interactive workloads"
help
Use 16ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load twice as fast as for the default
configuration using 32ms.

config PELT_UTIL_HALFLIFE_8
bool "8 ms, very fast"
help
Use 8ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load four time as fast as for the default
configuration using 32ms.

Default is 32ms, however this value was changed for example by @kdrag0n on the pixel 5 kernel to 16ms to improve performance. The downside of this approach is, that this needs to be chosen at compilation time, and can´t be changed during runtime. choosing 16ms or lower can lead to higher energy consumption and less battery life, but also better performance.

The inclusion of the pelt multiplier, together with an edited powerhal allows this kernel now to change pelt half-life depending on workload and interaction while the device is running. If there are certain events like interaction (scrolling, touching the screen), app launches, camera launches, taking a picture the pelt half-life will get changed dynamically. Interaction will result in 16ms half-life while app launches and camera usage will result in 8ms half-life, resulting in a performance boost when performance is needed.
If there´s no interaction happening, half-life will bump back to default 32ms as to not waste battery.

Improvements to the scheduler - Prevent frequency spikes caused by small tasks
uclamp can cause frequency spikes, by small very frequently occurring tasks (such as binder ), as was identified by a few vendors already. The following commit from the ARM-Developers aims to improve this situation.

BFQ-IO Scheduler
BFQ is now on par with linux-mainline as those changes were backported

TCP - Improvements
A series of patches was backported for the commit mentioned by this article. It can be found in my kernel tree here

F2FS-Stable Improvments
Latest F2FS-Stable was merged and tested extensively.

Several other improvements are included as well. More details in the changelog.
Download is below.
Updated instructions in the OP!


Changelog:
- linux-stable 5.10.84
- kernel/common merged
- ship kernel as flashable zip
- ship complete gki kernel (boot, dtbo, vendor_boot, vendor_dlkm)
- include powerhal module in the flashable zip
- mainline backports to the scheduler
- introduce pelt multiplier and tie it into powerhal
- prevent frequency spikes by small transient tasks
- tcp backport from mainline
- bfq backports from mainline
- f2fs-stable included
wakelock blocker
- please read [URL="https://arstechnica.com/gadgets/2018/08/p-is-for-power-how-google-tests-tracks-and-improves-android-battery-life/"]this for further info
don´t use this to block any kernel wakelocks you think keep the device awake, most are needed for the device to properly function! This is only intended for use cases like, wifi at work causes endless wakelock and the IT admin says, screw you I won´t update the firmware. In that case this might be the only option for your device to sleep.
- other changes please look at my github





Download:


Instructions can be found in the OP! Please follow the instructions to avoid any issues.
If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.
Exciting times!

I can probably presume the answer here but just to make sure, I presume root will remain intact given root is a requirement for this kernel?

Update edit: I can confirm root remains intact 👌

Flashed with EX Kernel Manager, let the good times begin...

Many thanks!
 
Last edited:

Freak07

Recognized Developer / Recognized Contributor
Jan 2, 2011
5,538
18,356
Exciting times!

I can probably presume the answer here but just to make sure, I presume root will remain intact given root is a requirement for this kernel?
Correct. I edited the OP and the release post to reflect this.

I also added a notice to remove the old powerhint module in case using it prior to flashing 1.4.0.
 
  • Like
Reactions: Texan1 and cd993

dmmc1

New member
May 29, 2011
3
1
Update to 1.4.0

Hey guys and girls,

Alright here´s the next update and it´s a really big one. There are several significant changes in this release.
Please read through the whole post to understand the changes.

Flashable kernel.zip
I decided to ship the kernel now as a flashable zip. (thanks to @eng_stk and @osm0sis)
I was hesitant to do this at first, since vendor_dlkm is part of super. That means it´s no ordinary partition, which is the reason vendor_dlkm needs to be flashed in fastbootd. Luckily simply dd´ing vendor_dlkm does still work as a bandaid on a running device, until we find a way to "properly" flash vendor_dlkm to super. But for now that way works and is sufficient. What´s more important, I couldn´t cause havoc when I tried.
That means no more flashing via fastboot. The kernel can be flashed via EXKM or FKM app. Due to ramdisk in vendor_boot being different on Pixel 6 (oriole) and Pixel 6 Pro (raven) there are two seperate zips now.
That means this project is now completely like I envisioned it in the beginning. The prior release missed several improvements that ended up in the kernel modules, which sit in vendor_boot.img.
Since we´re flashing all four images now, module verification can be enforced and I don´t need to force load the kernel modules from the stock vendor_boot any longer.
Flashing the kernel.zip will preserve root.
Shipping the kernel.zip will allow for easier flashing and for several other changes to be installed when flashing the kernel.zips, which also brings us to the next change.

Flashable kernel.zip - AK3 Helper Module
The kernel.zip flashes now all four images that are related to the kernel. boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img.
Alongside the kernel.zip a magisk module called AK3 Helper Module will be flashed. It will show up in magisk manager after the reboot following the flash of the kernel.zip. Do not delete this module, it ships a modified powerhal, which is an integral part to the changes in this release.
The powerhal will also restrict CPU-Freqs when the screen is off to save battery during e.g. music/podcast playback.l
If you used the old powerhint module, please remove that before flashing the kernel.zip.

Improvements to the Scheduler/Powerhal - Pelt Multiplier
Next big change, the pelt multiplier. This commit allows to change pelt half-life during runtime, instead of choosing before compilation as was the only way in the past.
Straight from the documentation:
prompt "Utilization's PELT half-Life"
default PELT_UTIL_HALFLIFE_32
help
Allows choosing one of the possible values for the PELT half-life to
be used for the update of the utilization of tasks and CPUs.
The half-life is the amount of [ms] required by the PELT signal to
build up to 50% utilization. The higher the half-life the longer it
takes for a task to be represented as a big one.

If not sure, use the default of 32 ms.

config PELT_UTIL_HALFLIFE_32
bool "32 ms, default for server"

config PELT_UTIL_HALFLIFE_16
bool "16 ms, suggested for interactive workloads"
help
Use 16ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load twice as fast as for the default
configuration using 32ms.

config PELT_UTIL_HALFLIFE_8
bool "8 ms, very fast"
help
Use 8ms as PELT half-life value. This will increase the ramp-up and
decay of utlization and load four time as fast as for the default
configuration using 32ms.

Default is 32ms, however this value was changed for example by @kdrag0n on the pixel 5 kernel to 16ms to improve performance. The downside of this approach is, that this needs to be chosen at compilation time, and can´t be changed during runtime. choosing 16ms or lower can lead to higher energy consumption and less battery life, but also better performance.

The inclusion of the pelt multiplier, together with an edited powerhal allows this kernel now to change pelt half-life depending on workload and interaction while the device is running. If there are certain events like interaction (scrolling, touching the screen), app launches, camera launches, taking a picture the pelt half-life will get changed dynamically. Interaction will result in 16ms half-life while app launches and camera usage will result in 8ms half-life, resulting in a performance boost when performance is needed.
If there´s no interaction happening, half-life will bump back to default 32ms as to not waste battery.

Improvements to the scheduler - Prevent frequency spikes caused by small tasks
uclamp can cause frequency spikes, by small very frequently occurring tasks (such as binder ), as was identified by a few vendors already. The following commit from the ARM-Developers aims to improve this situation.

BFQ-IO Scheduler
BFQ is now on par with linux-mainline as those changes were backported

TCP - Improvements
A series of patches was backported for the commit mentioned by this article. It can be found in my kernel tree here

F2FS-Stable Improvments
Latest F2FS-Stable was merged and tested extensively.

Several other improvements are included as well. More details in the changelog.
Download is below.
Updated instructions in the OP!


Changelog:
- linux-stable 5.10.84
- kernel/common merged
- ship kernel as flashable zip
- ship complete gki kernel (boot, dtbo, vendor_boot, vendor_dlkm)
- include powerhal module in the flashable zip
- mainline backports to the scheduler
- introduce pelt multiplier and tie it into powerhal
- prevent frequency spikes by small transient tasks
- tcp backport from mainline
- bfq backports from mainline
- f2fs-stable included
wakelock blocker
- please read [URL="https://arstechnica.com/gadgets/2018/08/p-is-for-power-how-google-tests-tracks-and-improves-android-battery-life/"]this for further info
don´t use this to block any kernel wakelocks you think keep the device awake, most are needed for the device to properly function! This is only intended for use cases like, wifi at work causes endless wakelock and the IT admin says, screw you I won´t update the firmware. In that case this might be the only option for your device to sleep.
- other changes please look at my github





Download:


Instructions can be found in the OP! Please follow the instructions to avoid any issues.
If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.
there is an error, and failed:(EX kernel manager has root)
mkdir: can't create directory '/tmp/anykernal/':
Read-only file system.....
unzip: can't open 'Image.lz4': read only system Unzip failed. Aborting...
 

Tomatot-

Senior Member
May 11, 2012
1,651
1,576
OnePlus 6
- i assumed this question would arise sooner or later. If the app can flash the zip, it should work just fine.
I can share the boot.imgs for raven/oriole. Then after extracting the other images, the four images and be flashed via fastboot.
I would also need to create a separate magisk module.
I can put all this in a separate folder and hope it doesn't create more confusion as actual benefit.

- before releasing i flashed back the four images several times without noticing problems. What kind of problems were encountered?
- That would be nice I think! Thank you again.

- I don't know, I can't tell you as I didn't experience it myself. But if you didn't face any issues, it should be fine! Worse scenario a dirty flash (without fastboot -w) makes the trick afaik.
 

Tomatot-

Senior Member
May 11, 2012
1,651
1,576
OnePlus 6
I know I wasn't meant to, but I tried to install 1.4 via FKU on ProtonAOSP and it didn't work. I assume it doesn't like changing some of these partitions: vendor_dlkm or vendor_boot since changing boot img works fine (with Despair for example).

I just wanted to let everyone know so they don't waste their time.
 

Top Liked Posts

  • 4
    GOT IT WORKING! Running Magisk Canary 24313 with Kiri kernel 2.4-stable.

    Join this thread for what I did with @capntrips great work!
    This.
    Preciate the summarized guide, it's up and booting.

    Love y'all and love the work.
  • 34
    Update to 2.4.0

    Hey guys and girls,


    Alright here´s the next update and it´s fine to flash on May firmware. As I suspected we already had all the changes for May by merging upstream.
    I´ll include the changelog from 2.3.0 as well in this release post, since I think a lot of people flash the kernel on a monthly basis when the security updates drop. So this post pictures the changes going from 2.1.0 to 2.3.0! As I said 2.3.0 was kind of a final rehearsal to make sure everything is good for the May update.
    I´ll put a remark behind changes going from 2.3.0 to 2.4.0.
    This release is made for stable Android 12.1.0 May firmware. Not QPR Beta or A13 Beta!
    Once I find enough time or QPR beta gets updated, I might update the QPR beta release. No plans to support A13 beta.

    I also finished up the tables/graphs in regards to different binnings with the respective voltages on different tensor chips thanks to the dmesgs you all provided. I really want to put out a big thanks here to everyone for taking the time and participating. It was really great to see this kind of response.
    I´ll provide them in a post in this thread soon.
    So with that in mind we´ll get to the next paragraph were I could put those tables to good use.

    A few changes from A13 Beta are merged to the kernel so we can enjoy the improvements on A12 ahead of time. Most of them aim to improve the scheduler and task placement.

    However the recently dropped A13 Beta source contains a commit that can restrict max-cpufreqs based on PMU (Power monitor unit) reading. I setup this mechanism (lets call it "PMU Limiter") to mildly cut back max-freqs when they aren´t needed. It works quite well so far, with no performance impacts during scenarios where max cpufreq is beneficial. (e.g. app launching, camera launching, interaction etcetc)
    That means if a certain threshold is not crossed the max-freqs will be restricted to 1,4GHZ/1,6GHZ/2,4GHZ (for little/mid/big cores). As soon as the PMU detects enough pressure, those limits will be lifted.
    The frequency limits are based on tracing during various scenarios, benchmarking and also factor in the voltage table I was able to create. For example: 2.4GHZ for the big cores is the last freq step where a steady linear increase in voltage can be seen. Freq steps higher than 2,4ghz have a steeper slope.
    Keep in mind CPU-Freqs shouldn´t be touched in EXKM/FKM or other kernel managers. They are controlled by various mechanisms now (thermal hal, powerhal, pmu limiter etc) and values will get overwritten based on input.
    That means if you open the CPU section in a kernel manager, the maxfreqs will not be the actual maxfreqs that are possible. or the minfreqs might be raised. That´s normal and there´s nothing wrong if that´s the case.

    Additionally to the previous changes tasks of rt, sf and ta groups are now biased to start on high capacity CPUs during app launches, interactions etc.
    As usual, depending on your usage you may or may not notice a difference during these scenarios. :)

    While tracing I noticed kswapd often takes 100% cpu share when reclamation is happening. Since we use an 8 core cpu, an additional kswapd thread is being spawned during boot, which increases throughput for kswapd in these scenarios. Reasoning behind this can be found here.

    The trusty driver which connects to the fingerprintreader hal uses now a high prio workqueue when the phone is unlocked via fingerprint scanner. This means better performance, especially under stress. Keep in mind this is a kernel level change, it won´t magically improve fingerprint reader times manifold.

    DAMON and DAMON-Reclaim were removed from 2.3.0 going to 2.4.0. I tested the feature privately and it unfortunately collides with googles EH zram implementation causing the phone to crash at the moment. Tried to debug this issue, but no luck for the May release here.
    If you previously enabled the feature without adjusting the parameters properly and your phone didn´t crash, DAMON-Reclaim just didn´t do anything.

    2.4.0 also has an updated anykernel3.zip, which includes all the latest anykernel3 changes.
    Thanks to @capntrips we now have full support to resize vendor_dlkm partition which is part of the super partition. That means we finally can flash larger than stock vendor_dlkm partitions via anykernel3.zips and resize the partition properly instead of just dd´ing to it.
    A huge thanks to @capntrips for working on this and to @osm0sis for maintaining anykernel3.


    Disclaimer:
    I´ll keep the warning as to preferably using magisk stable to avoid potential issues as well here in this post.
    Please note that 24306 works fine for me though on non beta, stable May firmware!
    Important:
    Make sure you´re being rooted with magisk 24300 stable before flashing the kernel if you´re unsure. Any magisk version above 24303 might potentially lead to a reboot back to bootloader since android 12.1.0 and A12L QPR3 Beta. At the moment this only affects canary, but I put the warning just in case this will not get resolved in upstream magisk in time until the next stable drops. I saw a post that some modules also have problems with latest canary, so there´s a lot going on at magisk´s side at the moment.
    A post containing a short write-up how to "downgrade" magisk can be found following this link.

    If you´re one of the unfortunate ones that suffer from the device is corrupt bug on pixel 6 series please take a look at the FAQ at the beginning of this thread it contains a solution. The issue is probably caused by a bug that affects pixel 6 devices and has nothing to do with magisk or a kernel, it just happens to get triggered when using any of those.



    Changelog:

    - Linux-stable merged to 5.10.113
    - Use prebuilt Google Clang 14.0.5 for compilation
    - Utilize an additional kswapd thread to increase throughput for memory reclaim
    - remove DAMON and DAMON-Reclaim from kernel build (2.4.0)
    - improve trusty driver performance which connects to fingerprintscanner-hal by using high prio wq during fp unlock (2.4.0)
    - mm improvements from kernel/common (2.4.0)
    - improvements from kernel-common a13 to page_pinner
    - mainline backports for BFQ scheduler
    - rework Multi-Gen LRU implementation
    - scheduler improvements for RT (realtime) tasks
    - other scheduler improvements
    - include scheduler improvements from A13 Beta regarding better task placement
    - introduce and setup PMU limiter (prevents CPU from spiking to max when it isn´t needed, based on PMU reads)
    - bias tasks of rt, sf and ta groups to prefer high capacity cpus during app launches, interactions, camera launches, etc
    - updated anykernel3.zip (thanks to @osm0sis) -> adds full support for resizing vendor_dlkm ( huge thanks to @capntrips )



    Download:


    Instructions can be found in the OP! Please follow the instructions to avoid any issues and read this post carefully. Don´t use magisk canary 24303 or more recent to avoid potential issues!
    If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.

    I wish everybody a great day/evening!
    Have fun, enjoy the kernel and your phone.


    If you like my work please consider a donation.
    Donations are not mandatory but very welcome.
    If you like my work and want to buy me a coffee/green tea: http://paypal.me/freak07
    29
    Update to 2.3.0

    Hey guys and girls,


    Alright here´s the next update. It´s a major one. I want to put it out shortly before we hopefully receive the next monthly security update on Monday kinda as a final rehearsal.
    This kernel is made for stable Android 12.1.0 April firmware. Not QPR Beta or A13 Beta!
    Once I find enough time or QPR beta gets updated, I might update the QPR beta release. No plans to support A13 beta.

    A few changes from A13 Beta are merged to the kernel so we can enjoy the improvements on A12 already. Most of them aim to improve the scheduler and task placement.
    A13 Beta source contains a commit that can restrict max-cpufreqs based on PMU reading. I setup this mechanism to mildly cut back max-freqs when they aren´t needed. It works quite well so far, with no performance impacts during scenarios where max cpufreq is beneficial. (e.g. app launching, camera launching etc)
    Tasks of rt, sf and ta groups are now biased to start on high capacity CPUs during app launches, interactions etc.
    As usual, depending on your usage you may or may not notice a difference during these scenarios. :)

    While tracing I noticed kswapd often takes 100% cpu share when reclamation is happening. Since we use an 8 core cpu, an additional kswapd thread is being spawned during boot, which increases throughput for kswapd in these scenarios.

    DAMON patch-series is included to this release as it was merged to kernel/common. It includes DAMON-reclaim. You can read more about it here.
    This feature is currently disabled by default on this kernel. If you want to use it you can tune it to your liking as per the documentation linked above.
    The feature can be enabled via:
    Code:
    echo 1 > /sys/module/damon_reclaim/parameters/enabled
    I think Google might start to use it in the not so far future, but for now it´s disabled by default.


    Disclaimer:
    I´ll keep the warning as to preferably using magisk stable to avoid potential issues as well here in this post.
    Please note that 24306 works fine for me though on non beta, stable April firmware!
    Important:
    Make sure you´re being rooted with magisk 24300 stable before flashing the kernel if you´re unsure. Any magisk version above 24303 might potentially lead to a reboot back to bootloader since android 12.1.0 and A12L QPR3 Beta. At the moment this only affects canary, but I put the warning just in case this will not get resolved in upstream magisk in time until the next stable drops. I saw a post that some modules also have problems with latest canary, so there´s a lot going on at magisk´s side at the moment.
    A post containing a short write-up how to "downgrade" magisk can be found following this link.

    If you´re one of the unfortunate ones that suffer from the device is corrupt bug on pixel 6 series please take a look at the FAQ at the beginning of this thread it contains a solution. The issue is probably caused by a bug that affects pixel 6 devices and has nothing to do with magisk or a kernel, it just happens to get triggered when using any of those.



    Changelog:

    - Linux-stable merged to 5.10.113
    - Use prebuilt Google Clang 14.0.5 for compilation
    - Utilize an additional kswapd thread to increase throughput for memory reclaim
    - improvements from kernel-common a13 to page_pinner
    - mainline backports for BFQ scheduler
    - rework Multi-Gen LRU implementation
    - merge DAMON to the kernel, which includes DAMON-Reclaim (this feature is not enabled by default, you need to enable it manually if you want to test)
    - scheduler improvements for RT (realtime) tasks
    - other scheduler improvements
    - include scheduler improvements from A13 Beta regarding better task placement
    - introduce and setup PMU limiter (prevents CPU from spiking to max when it isn´t needed, based on PMU reads)
    - bias tasks of rt, sf and ta groups to prefer high capacity cpus during app launches, interactions, camera launches, etc



    Download:


    Instructions can be found in the OP! Please follow the instructions to avoid any issues and read this post carefully. Don´t use magisk canary 24303 or more recent to avoid potential issues!
    If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.

    I wish everybody a great day/evening!
    Have fun, enjoy the kernel and your phone.


    If you like my work please consider a donation.
    Donations are not mandatory but very welcome.
    If you like my work and want to buy me a coffee/green tea: http://paypal.me/freak07
    25
    May update is out. :)

    no source update pushed from google yet. I guess it´ll happen in a few hours when I´ll be asleep.
    I went ahead and flashed the latest release for stable 12.1.0 without any issues so far.

    If you can´t wait, it should be fine to flash based on that short experience.

    If you want to be absolutely sure there will be no issues due to incompatible source/firmware, I´ll try to update the kernel with any new potential changes in the source for May as soon as I find time, which will hopefully/probably be tomorrow if everything goes as expected. :)

    I wish everybody a great day/evening.
    20
    The app is Crédit Mutuel

    And yes, you just gotta get to the actual log-in screen after accepting the conditions and cookies. At the log-in screen there will be a red warning that root has been detected.

    Thanks!
    Managed to reproduce the issue. It´s a magisk issue that surfaces probably since 2.0.1 where direct USB access was added and was not kernel related.
    To get direct USB access working a firmware file in vendor/firmware is replaced during bootup when my kernel is flashed, which is required for the kernel changes to actually work.
    The denylist trick to hide modifications stumbles upon that dir and fails due to a selinux error as denylist is not allowed to access that dir.
    As a workaround I fixed that selinux denial and root is no longer being detected by the app. :)

    Code:
    05-08 08:45:40.268   778   778 D Zygote  : Forked child process 18269
    05-08 08:45:40.269  3697  5245 I AssistantForeground: Get launcher package: com.google.android.apps.nexuslauncher
    05-08 08:45:40.269  1579  1769 I ActivityManager: Start proc 18269:com.cm_prod.bad/u0a313 for pre-top-activity {com.cm_prod.bad/com.e_i.bad.controls.activities.StartActivity}
    05-08 08:45:40.271 18269 18269 I Magisk  : zygisk64: [com.cm_prod.bad] is on the denylist
    05-08 08:45:40.274 18269 18269 D Magisk  : denylist: Unmounted (/system/bin/magiskpolicy)
    05-08 08:45:40.274 18269 18269 D Magisk  : denylist: Unmounted (/system/bin/magisk)
    05-08 08:45:40.274 18269 18269 D Magisk  : denylist: Unmounted (/system/bin/app_process64)
    05-08 08:45:40.274 18269 18269 D Magisk  : denylist: Unmounted (/system/bin/app_process32)
    05-08 08:45:40.275 18269 18269 D Magisk  : denylist: Unmounted (/system/bin)
    05-08 08:45:40.275 18269 18269 D Magisk  : denylist: Unmounted (/product/overlay)
    05-08 08:45:40.272 18269 18269 W main    : type=1400 audit(0.0:1514): avc: denied { search } for name="firmware" dev="dm-4" ino=722 scontext=u:r:zygote:s0 tcontext=u:object_r:vendor_fw_file:s0 tclass=dir permissive=0
    05-08 08:45:40.276 18269 18269 D Magisk  : denylist: Unmounted (/dev/G8MMn)
    05-08 08:45:40.277 18269 18269 D Magisk  : denylist: Unmounted (/system/etc/hosts)
    05-08 08:45:40.277 18269 18269 D Magisk  : denylist: Unmounted (/system/app/Stk)
    05-08 08:45:40.277 18269 18269 D Magisk  : denylist: Unmounted (/vendor/etc/powerhint.json)

    After flashing the updated zip what I did was hide the magisk app in magisk manager, enable deny list and added the app to the list. Wipe data of the banking app, reboot (not sure if needed but rebooting is always good in these cases) and root was no longer detected by the app.

    Attached are zips which include the fix the selinux denial for you to confirm.

    This might also fix root detection by other banking apps that are not detecting root on stock kernel, but were broken after flashing the few last releases of this kernel.
    11
    A12L QPR Beta Kernel

    For those on the A12L QPR Beta 3 here are zips to try. They are only supposed to be flashed on Android 12 QPR Beta!
    They should work fine on QPR Beta 3 as source was pushed already, merged and I have confirmation it´s working fine on Beta 3.
    That kernel has feature parity with the 2.4.0. So for a detailed changelog please refer to the release post of 2.4.0.


    I don´t know what´s the current situation with magisk and flashing kernels on QPR Beta, but it´s probably best to use magisk stable if you don´t want to face issues. (although I have confirmation magisk canary 24307 works fine with verity/verification disabled, don´t know about vbmeta enabled)
    I´m not myself on QPR Beta so please leave feedback, but remember:
    These zips are provided as is I don´t have time to flash between stable and QPR
    Feel free to report issues with proper bug reports (containing logs, steps to reproduce according to the guide linked in the FAQ), but they might remain unresolved if it´s not easy to fix without running A12L Beta on my own end.


    I wish everybody a great weekend!
    Have fun, enjoy the kernel and your phone.


    If you like my work please consider a donation.
    Donations are not mandatory but very welcome.
    If you like my work and want to buy me a coffee/green tea: http://paypal.me/freak07
  • 99
    Kirisakura-Kernel for the Pixel 6/Pro

    Hello everyone,

    To keep it short: Here is Kirisakura - Kernel for the Google Pixel 6 Pro aka Raven and the Pixel 6 aka Oriole, together Raviole.
    I would appreciate if everybody that flashes the kernel, reads at least once through this opening post and the following ones.

    The kernel aims to keep most of the subsystems updated, way ahead of the stock kernel, thereby improving security, stability and performance!
    This includes Linux-Stable, F2FS-Stable and kernel/common!
    If that got you curious,have a read about linux-stable and why it is important here. The stable-process is not the same for every subsystem, but the general idea, rule of thumb and benefits are applicable for other subsystems as well.

    The kernel includes a lot of improvements and contributions from other developers as well. Without this kernel would not exist.
    A big part of improvements originate from @arter97´s, @kdrag0n´s and @Sultanxda´s work. Many others contributed in some way or another to this kernel.
    A big thanks to all of them at this place!

    Now lets continue with a list of features in the next paragraph!

    Features:
    Main Features:
    - Based on latest kernel sources from Google, Kernel is made for Android 12
    - Linux-Stable-Upstream included to 5.10.113
    - Compiled with prebuilt Google clang 14.0.5
    - merged kernel/common (improvements to android-common-kernel straight from google)
    - Multi-gen LRU backported (more info here, here as well and here) to improve mm and reduce cpu cycles
    - Utilize an additional kswapd thread to increase throughput for memory reclaim
    - pelt multiplier tied into powerhal to speed up scheduler during interaction (more info here)
    - prevent frequency spikes caused by small transient tasks when the device is idle(more info here)
    - tie mechanism to prevent frequency spikes caused by small tasks also into powerhal
    - scheduler improvements for RT (realtime) tasks
    - introduce and setup PMU limiter (prevents CPU from spiking to max when it isn´t needed, based on PMU reads)
    - improve camera performance by tuning the powerhal during recording
    - bias tasks of rt, sf and ta groups to prefer high capacity cpus during app launches, interactions
    - improve app launches via powerhal
    - improve trusty driver performance which connects to fingerprintscanner-hal by using high perf wq during fp unlock
    - restrict maximum CPU-Freqs during screen off/ idle to 1.1GHZ for all clusters to save power
    - introduce unfair f2fs rwsems to prevent writer starvation and improve IO perf under heavy load
    - fuse: give wakeup hints to scheduler to speed up compress/decompress in internal storage (details)
    - enable RCU_BOOST (details here), also fix RCU_BOOST behaviour
    - F2FS-Stable updated
    - TCP backports from mainline
    - BFQ updates backported from mainline
    - use bbr as default TCP congestion algorithm (fasted algo according to this excellent research from @kdrag0n found here )
    - Enable support for TTL spoofing
    - Include LRNG, see here and here for more info (thanks @arter97 for the work on his op9 kernel)
    - important patches from kernel/common for 5.10 (here are more details)
    - CleanSlate Features from @tbalden, big applause here! (s2s, notification booster, battery saver, flashlight notifications. Please note: cleanslate features that work otherwise with rooted devices like kadaway (adblocking) are not implemented on this kernel since I´m running rooted)
    - dirty pipe exploit fixed
    - supports direct usb access for hi-res playback over USB-C DACs
    - flashing the kernel will preserve root

    Various Optimizations:
    - update several drivers to use power efficient workingqueues (for example wlan driver)
    - kernfs: use buffer from the stack space
    - printk: use buffer from the stack space
    - kthread: use buffer from the stack space
    - bpf: avoid dynamic memory allocation for small value buffers
    - binder: Reserve caches for small, high-frequency memory allocations
    - kernfs: use kmem_cache pool for struct kernfs_open_node/file
    - cgroup: use kmem_cache pool for struct cgrp_cset_link
    - f2fs: reduce timeout for uncongestion
    - f2fs: Demote GC thread to idle scheduler class
    - f2fs: set ioprio of GC kthread to idle
    - mm: vmstat: use power efficient workingqueues
    Wakelock Blocker:
    - advanced wakelock blocker with the ability to block any wakelocks (dangerous, use with caution)
    - please read [URL="https://arstechnica.com/gadgets/2018/08/p-is-for-power-how-google-tests-tracks-and-improves-android-battery-life/"]this for further info

    AK3 Helper Module:
    - restrict little cluster to 1,19ghz mid cluster to 1,19ghz and big cluster to 1,1ghz during screen off, to reduce battery usage for example during music playback
    - tie pelt multiplier into the powerhal (more info here)
    - prevent frequency spikes caused by small transient tasks during idle operation (more info here)
    - boost scheduler using the pelt multiplier during fingerprint unlock operation

    DOWNLOAD:
    Download is always located in this folder:

    Changelog:
    Android 12.0.0

    1.0.0 Initial Release
    1.0.2 https://forum.xda-developers.com/t/...r-pixel-6-pro-aka-raven.4358435/post-85910621
    1.0.5 https://forum.xda-developers.com/t/...r-pixel-6-pro-aka-raven.4358435/post-85924419
    1.3.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-85976139
    1.4.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86109665
    1.5.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86259863
    1.7.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86390563
    1.8.4 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86541727

    Android 12.1.0 Stable (March feature drop and more recent)
    2.0.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86617873
    2.0.1 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86637233
    2.1.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86695911
    2.3.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86821331
    2.4.0 https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86834981

    Android 12L QPR Beta
    Build for Android 12 QPR Beta: https://forum.xda-developers.com/t/...pixel-6-pro-aka-raviole.4358435/post-86857033

    Requirements

    - unlocked Bootloader
    - USB-Debugging in developer options enabled
    - latest adb and fastboot binaries
    - working adb and fastboot environment so you can flash back to stock in case something goes wrong
    - working magisk environment (a device rooted with latest magisk stable in case you want to be absolutely safe, magisk 24303 and higher will bootloop on QPR beta and might act up on stable A12.1.0 too!)


    How to flash the Kernel:
    1a. Make sure you tick all the requirements above
    1. Download the correct kernel.zip depending on your device (Pixel 6 = oriole || Pixel 6 Pro = raven)
    (if you´re for whatever reason on November firmware -> use 1.3.0! More recent kernel releases will bootloop)
    2. Flash the correct kernel.zip via EXKM or FKM. Root will be preserved. The AK3 magisk helper module will be automatically installed during flashing the kernel.zip and be present on next reboot.
    Do not remove or disable the AK3 Magisk Helper Module otherwise the device will bootloop.
    3. Reboot and profit.

    Manual installation without relying on paid apps like fkm/exkm:
    Please have a look at the linked post.



    Donations:
    Donations are not mandatory but very welcome if you want to support development or just buy me a coffee/tea/beer :)
    If you like my work: http://paypal.me/freak07

    Credits:
    @osm0sis for all his work on AK3.
    @tbalden for being the best HTC, Pixel, OnePlus and Asus wingman!
    @LeeDroid and @mwilky for their awesome roms and work I used on multiple devices!
    @Captain_Throwback for all the mentoring and guidance!
    @Eliminater74 for bringing me into the game and the Inspiration
    @nathanchance for his upstream guidance and assistance
    @RenderBroken for helping me out
    @flar2 for all his work
    @joshuous for all the help he provided to me in the past!
    @arter97 for giving me advice
    @kdrag0n for his help and advices!
    @topjohnwu for magisk and his entire work!


    Source Code: https://github.com/freak07/Kirisakura_Raviole
    37
    Update to 1.8.4

    Hey guys and girls,


    So here´s the next update. It´s kind of an off schedule update, as I planned to update the kernel with the next security update/feature drop.

    But in the light of recent events regarding the new exploit called "Dirty Pipe" (more info here), which is similar to the "Dirty Cow" exploit from a while ago, but easier to exploit this time, I decided to release an update ahead of schedule.

    This exploit was fixed in linux-stable 5.10.102, as opposed to a single commit in AKC (android kernel common, commit here). This shows once more why merging linux-stable is beneficial as explained in detail in the OP.

    Since one of the key aspects of this kernel is security and staying on par with upstream (which often fixes exploits way ahead of android security bulletin updates, even before an exploit is even known or fixed via a patch on the security bulletin) I decided to release this update as quickly as possible, so this exploit is fixed on devices running this kernel.

    Several other notable improvements and changes in this release:
    Bring in scheduler updates from Android 13 Developer Preview, which aim at improving task placement. (adjust powerhal accordingly)
    BFQ IO-Sched is now on par with linux-mainline.
    Several fixes to mm subsystem, f2fs and others.

    Several other improvements are included as well. More details in the changelog.
    Download is below.
    Updated instructions in the OP!


    Changelog:
    - linux-stable 5.10.103
    - contains fix for the dirty pipe exploit
    - built with clang 14.0.2 prebuilt by google
    - improvments from kernel/common
    - fix memory leaks
    - security related patches
    - mm improvments
    - f2fs fixes
    - scheduler fixes
    - for details please check github
    - built with improvements from A13 Dev Preview to display driver
    - other changes please look at my github


    Download:


    Instructions can be found in the OP! Please follow the instructions to avoid any issues.
    If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.
    37
    Update to 1.7.0

    Hey guys and girls,


    So here´s the next update. It includes the february security update. Most of the changes brought by the February kernel source drop, were already included in this kernel by merging kernel/common and linux-stable.


    Several other notable improvements and changes in this release:
    Improve f2fs performance by merging a patchset to prevent writer starvation for the checkpoint thread. This was discussed this month in the f2fs mailing list and is already merged to the kernel/common tree. It´ll improve performance under heavy I/O utilization.
    You can find more information following the discussion here.
    Necessary backports were brought to the kernel and the platform specific f2fs-implementation was also adjusted.
    Latest f2fs-stable was also merged to the kernel.

    Update the patchset to prevent frequency spikes caused by small tasks as well. Tie those new changes into the powerhal. (That means users not flashing the kernel.zip, but instead use the manual installation method, which are only a handful from the download count, need to flash the updated magisk helper module. Users that flash the kernel.zip via FKM/EXKM have to just flash and forget)

    Several other improvements are included as well. More details in the changelog.
    Download is below.
    Updated instructions in the OP!


    Changelog:
    - February Security update merged
    - linux-stable 5.10.96
    - include latest f2fs-stable
    - improvments from kernel/common
    - fix memory leaks
    - security related patches
    - mm improvments
    - for details please check github
    - introduce unfair f2fs rwsems to prevent writer starvation and improve IO perf
    - update patchset to prevent freq spikes caused by small transient tasks (also tie this into powerhal)
    - give pelt multiplier power hint for scheduler performance boost during fingerprint unlock
    - fuse: give wakeup hints to scheduler to speed up compress/decompress in internal storage (details)
    - enable RCU_BOOST (details here), also fix RCU_BOOST behaviour
    - update LRNG implementation (thanks to arter97 )
    - improvements/fixes for CleanSlate features
    - other changes please look at my github


    Download:


    Instructions can be found in the OP! Please follow the instructions to avoid any issues.
    If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.
    36
    Update to 2.1.0

    Hey guys and girls,


    Alright here´s the next update. And it´s again a really big update! :)
    A few weeks ago google pushed a backport of Multi-Gen LRU for the 5.15 kernel to their aosp/kernel common branches. I went ahead and backported that to our 5.10 tree alongside other mm-improvements from linux-mainline. By now google pushed their own backport for 5.10, but I decided to go with my original implementation as it contains a lot more improvements alongside the main Multi-Gen LRU backport and ran stable for well over 3 weeks.

    Powerhal was adjusted quite significantly too. CPU-freqs are restricted to 1.1GHZ max during screen off/device idle operations to save more power. App launches and camera operation are improved as well in the powerhal. General usage benefits from those changes too.

    Latest linux-stable, f2fs-stable and kernel/common were merged as well.

    Users that decide to not use the CleanSlate features and don´t install the apps won´t see the kernel parsing for the config files extensively.
    Vibration Booster from CleanSlate was improved as well to kind of counter the weaker haptic feedback since the March update. Please check the linked thread from the changelog. Huge thanks to @tbalden for this. If you want to give a little bit back consider purchasing the apps via playstore or maybe a small donation. :)



    I´ll keep the warning as to preferably using magisk stable to avoid potential issues as well here in this post.
    Please note that 24305 works fine for me though on non beta, stable April firmware!
    Important:
    Make sure you´re being rooted with magisk 24300 stable before flashing the kernel if you´re unsure. Any magisk version above 24303 might potentially lead to a reboot back to bootloader since android 12.1.0 and A12L QPR3 Beta. At the moment this only affects canary, but I put the warning just in case this will not get resolved in upstream magisk in time until the next stable drops. I saw a post that some modules also have problems with latest canary, so there´s a lot going on at magisk´s side at the moment.
    A post containing a short write-up how to "downgrade" magisk can be found following this link.



    Changelog:

    - Update for April Source
    - Linux-stable merged to 5.10.109
    - f2fs-stable merged
    - fixes and improvements from kernel/common including several subsystems
    - multi-gen LRU ( more info here, here as well and here)
    - general LRU improvements from Linux-Mainline
    - improve camera performance by tuning the powerhal during recording
    - improve app launches via powerhal
    - restrict maximum CPU-Freqs during screen off/ idle to 1.1GHZ for all clusters to save power
    - remove cleanslate config files getting parsed excessively even if user did not install the CleanSlate apps
    - improve vibration boosting feature in CleanSlate config app to allow stronger vibration again(please have a look at this post )
    - other fixes for CleanSlate features such as sweep to sleep
    - updated anykernel 3 zip, thanks to @osm0sis
    - probably a lot more I forgot as time is short for me.


    Download:


    Instructions can be found in the OP! Please follow the instructions to avoid any issues and read this post carefully. Don´t use magisk canary 24303 or more recent to avoid potential issues!
    If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.

    I wish everybody a great day/evening!
    Have fun, enjoy the kernel and your phone.


    If you like my work please consider a donation.
    Donations are not mandatory but very welcome.
    If you like my work and want to buy me a coffee/green tea: http://paypal.me/freak07
    34
    Update to 2.4.0

    Hey guys and girls,


    Alright here´s the next update and it´s fine to flash on May firmware. As I suspected we already had all the changes for May by merging upstream.
    I´ll include the changelog from 2.3.0 as well in this release post, since I think a lot of people flash the kernel on a monthly basis when the security updates drop. So this post pictures the changes going from 2.1.0 to 2.3.0! As I said 2.3.0 was kind of a final rehearsal to make sure everything is good for the May update.
    I´ll put a remark behind changes going from 2.3.0 to 2.4.0.
    This release is made for stable Android 12.1.0 May firmware. Not QPR Beta or A13 Beta!
    Once I find enough time or QPR beta gets updated, I might update the QPR beta release. No plans to support A13 beta.

    I also finished up the tables/graphs in regards to different binnings with the respective voltages on different tensor chips thanks to the dmesgs you all provided. I really want to put out a big thanks here to everyone for taking the time and participating. It was really great to see this kind of response.
    I´ll provide them in a post in this thread soon.
    So with that in mind we´ll get to the next paragraph were I could put those tables to good use.

    A few changes from A13 Beta are merged to the kernel so we can enjoy the improvements on A12 ahead of time. Most of them aim to improve the scheduler and task placement.

    However the recently dropped A13 Beta source contains a commit that can restrict max-cpufreqs based on PMU (Power monitor unit) reading. I setup this mechanism (lets call it "PMU Limiter") to mildly cut back max-freqs when they aren´t needed. It works quite well so far, with no performance impacts during scenarios where max cpufreq is beneficial. (e.g. app launching, camera launching, interaction etcetc)
    That means if a certain threshold is not crossed the max-freqs will be restricted to 1,4GHZ/1,6GHZ/2,4GHZ (for little/mid/big cores). As soon as the PMU detects enough pressure, those limits will be lifted.
    The frequency limits are based on tracing during various scenarios, benchmarking and also factor in the voltage table I was able to create. For example: 2.4GHZ for the big cores is the last freq step where a steady linear increase in voltage can be seen. Freq steps higher than 2,4ghz have a steeper slope.
    Keep in mind CPU-Freqs shouldn´t be touched in EXKM/FKM or other kernel managers. They are controlled by various mechanisms now (thermal hal, powerhal, pmu limiter etc) and values will get overwritten based on input.
    That means if you open the CPU section in a kernel manager, the maxfreqs will not be the actual maxfreqs that are possible. or the minfreqs might be raised. That´s normal and there´s nothing wrong if that´s the case.

    Additionally to the previous changes tasks of rt, sf and ta groups are now biased to start on high capacity CPUs during app launches, interactions etc.
    As usual, depending on your usage you may or may not notice a difference during these scenarios. :)

    While tracing I noticed kswapd often takes 100% cpu share when reclamation is happening. Since we use an 8 core cpu, an additional kswapd thread is being spawned during boot, which increases throughput for kswapd in these scenarios. Reasoning behind this can be found here.

    The trusty driver which connects to the fingerprintreader hal uses now a high prio workqueue when the phone is unlocked via fingerprint scanner. This means better performance, especially under stress. Keep in mind this is a kernel level change, it won´t magically improve fingerprint reader times manifold.

    DAMON and DAMON-Reclaim were removed from 2.3.0 going to 2.4.0. I tested the feature privately and it unfortunately collides with googles EH zram implementation causing the phone to crash at the moment. Tried to debug this issue, but no luck for the May release here.
    If you previously enabled the feature without adjusting the parameters properly and your phone didn´t crash, DAMON-Reclaim just didn´t do anything.

    2.4.0 also has an updated anykernel3.zip, which includes all the latest anykernel3 changes.
    Thanks to @capntrips we now have full support to resize vendor_dlkm partition which is part of the super partition. That means we finally can flash larger than stock vendor_dlkm partitions via anykernel3.zips and resize the partition properly instead of just dd´ing to it.
    A huge thanks to @capntrips for working on this and to @osm0sis for maintaining anykernel3.


    Disclaimer:
    I´ll keep the warning as to preferably using magisk stable to avoid potential issues as well here in this post.
    Please note that 24306 works fine for me though on non beta, stable May firmware!
    Important:
    Make sure you´re being rooted with magisk 24300 stable before flashing the kernel if you´re unsure. Any magisk version above 24303 might potentially lead to a reboot back to bootloader since android 12.1.0 and A12L QPR3 Beta. At the moment this only affects canary, but I put the warning just in case this will not get resolved in upstream magisk in time until the next stable drops. I saw a post that some modules also have problems with latest canary, so there´s a lot going on at magisk´s side at the moment.
    A post containing a short write-up how to "downgrade" magisk can be found following this link.

    If you´re one of the unfortunate ones that suffer from the device is corrupt bug on pixel 6 series please take a look at the FAQ at the beginning of this thread it contains a solution. The issue is probably caused by a bug that affects pixel 6 devices and has nothing to do with magisk or a kernel, it just happens to get triggered when using any of those.



    Changelog:

    - Linux-stable merged to 5.10.113
    - Use prebuilt Google Clang 14.0.5 for compilation
    - Utilize an additional kswapd thread to increase throughput for memory reclaim
    - remove DAMON and DAMON-Reclaim from kernel build (2.4.0)
    - improve trusty driver performance which connects to fingerprintscanner-hal by using high prio wq during fp unlock (2.4.0)
    - mm improvements from kernel/common (2.4.0)
    - improvements from kernel-common a13 to page_pinner
    - mainline backports for BFQ scheduler
    - rework Multi-Gen LRU implementation
    - scheduler improvements for RT (realtime) tasks
    - other scheduler improvements
    - include scheduler improvements from A13 Beta regarding better task placement
    - introduce and setup PMU limiter (prevents CPU from spiking to max when it isn´t needed, based on PMU reads)
    - bias tasks of rt, sf and ta groups to prefer high capacity cpus during app launches, interactions, camera launches, etc
    - updated anykernel3.zip (thanks to @osm0sis) -> adds full support for resizing vendor_dlkm ( huge thanks to @capntrips )



    Download:


    Instructions can be found in the OP! Please follow the instructions to avoid any issues and read this post carefully. Don´t use magisk canary 24303 or more recent to avoid potential issues!
    If you´re coming from another kernel restore stock boot.img, dtbo.img, vendor_boot.img and vendor_dlkm.img before flashing. Thank you.

    I wish everybody a great day/evening!
    Have fun, enjoy the kernel and your phone.


    If you like my work please consider a donation.
    Donations are not mandatory but very welcome.
    If you like my work and want to buy me a coffee/green tea: http://paypal.me/freak07