• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

Development [r2] arter97 kernel for OnePlus 9 series

Search This thread

Samuel Holland

Senior Member
Jun 26, 2013
517
249
lake charles
Have you tried Omega, if yes, how is it compared to this one ?
There both solid kernels, and I feel blessed to have them for our device. One thing to note, Omega is based on the oxygen source while this kernel is based on latest and greatest Qualcomm has to offer with only the necessary oxygen for our device. Omega kernel is the reason I went from 8 pro to the 9 Pro. 👍👍
 
  • Like
Reactions: Smedslund and Klbgr

Dashwood Foxe

Senior Member
Dec 23, 2014
157
54
Things didn't go well for me. Every time I rebooted it kept saying new sim card detected need to reboot. No way out.
Partitions Backup Manager is bugged (likely because it's so old) and will be unable to properly restore your backed up partitions. Restoring via the manager leads to system instability and bootloops. You would have to move the backed up images to your PC and fastboot flash your backups. Or use twrp.
 

Dashwood Foxe

Senior Member
Dec 23, 2014
157
54
I actually used the twrp way. After installing the kernel I had that pop up message. Had made a back up of boot etc through twrp. Restored it and gave me the error of no OS. decided to just MSM back to stock as I don't have much time to tinker.
Could maybe be your device. I had a similar issue but with my wifi. My wifi breaks and freezes up my device with any custom kernel I touched so I took a dive and opened a support and repair ticket through OnePlus and they fixed it. I had no problem since and can run custom kernels without issues. Seems like a an unused feature set on wireless component likes to die on this phone and custom kernels like to poke at it.
 

eugenechiuu

Senior Member
Oct 20, 2011
250
20
thank you so much for this kernel!

This solved one of the more unspoken issues of OP9 Pro which is the slow scrolling due to the stock kernel.

Now I get back the scrolling which I used to get in older OP phones.

Coming from omega kernel, will monitor how's the battery life in comparison and report back
 
  • Like
Reactions: l_mike
Will
I am cery curious if you notice any battery life improvement.
As far as I can tell after a day use on battery life:
- When I play a game, it's usage is about the same compared with Omega. It gets a lot less warm though
- With active use in Chrome I don't notice any difference in battery life
- Standby seems a bit better

With all that said, I notice in the battery stats, that I use less power comparing yesterday with Omega and today with this masterpiece 😇
 

Attachments

  • Screenshot_20211014-205242.jpg
    Screenshot_20211014-205242.jpg
    229.5 KB · Views: 112

GreaterLesser

Senior Member
Sep 19, 2014
493
192
Chicago
OnePlus 9 Pro
  • Like
Reactions: tathagatab

eugenechiuu

Senior Member
Oct 20, 2011
250
20
Will

As far as I can tell after a day use on battery life:
- When I play a game, it's usage is about the same compared with Omega. It gets a lot less warm though
- With active use in Chrome I don't notice any difference in battery life
- Standby seems a bit better

With all that said, I notice in the battery stats, that I use less power comparing yesterday with Omega and today with this masterpiece 😇
My experience so far have been similar to yours.

Genshin Impact on arter97 seems to be consuming slightly lesser power (31-32%/hour compared to 34-35%/hour), overall heat also slightly as my max temp caps lower than Omega/stock.

Overall, heat management is much better I think credits to better core management. I am getting lesser random heat ups from e-commerce apps or any of my daily tasks, contributing to a better battery life in theory.
 

l_mike

Senior Member
Jan 6, 2013
227
118
Xiaomi Mi Pad 4
Google Pixel 4a 5G
First impressions after moving from Omega:
- I think the device is way cooler during everyday tasks. It still gets warm, but it lasts cool longer.
- active drain is a little bit lower
- idle drain too. Device goes into deep sleep faster
- Overall performance is the same or a little better, but I can't tell for sure, cause op 9 pro is very fast phone.

Don't get me wrong - Omega kernel is way better than the stock one. But I think arter's doesn't have stock op kernel issues since it is Qualcomm based.
 
  • Like
Reactions: tathagatab

DashDashCZ

Senior Member
Oct 19, 2014
135
58
Czech Republic
OnePlus 9 Pro
Thank you for the kernel arter. It performs beautifully, battery life is great and performance is smooth.

I don't see much difference in the scrolling acceleration if any, I don't know if I'm doing anything wrong or if other people are having placebo but I've never had issues with it as this is my first OP phone so I'm not used to it as other people. Also the speedometer on chrome is still in mid 70s, same as it was on blu_spark. I don't care about this either tho, it feels snappy to me.

Screenshot_20211017-154521.jpg
 
  • Like
Reactions: tathagatab

Top Liked Posts

  • There are no posts matching your filters.
  • 18
    r2 is up, and it's a big release.

    Changelog is quite self-explanatory.

    r2
    Display-related processes are now allowed to use the middle cores as well for better smoothness
    Enabled more mremap() performance improvement that was missing from r1
    LA.UM.9.14.r1-18400-LAHAINA.0 merged
    LA.UM.9.16.r1-08100-MANNAR.0 merged
    LA.UM.10.9.1.r1-00300-QCS610.0 merged (contains a lot of new improvements including power optimizations)
    Linux v5.4.159 merged
    Wi-Fi drivers updated to 2.0.8.25M
    2021-11-06 security patch merged
    Watermark boosting disabled to fix aggressive app killings (by Sultan)
    Workaround added to fix unwanted doubles presses from the power button
    6
    @r4p70r @thirtythr33 @l_mike There is another way via fastboot (provided of course you have the backup files). That's what I did yesterday with the help of others.

    Be on 11.2.9.9, then do the following while in fastboot:

    fastboot flash boot boot.img (this should be stock 11.2.9.9 kernel)
    fastboot flash dtbo dtbo.img
    fastboot flash vendor_boot vendor_boot.img


    You'll boot into unrooted 11.2.9.9, then you can local upgrade to 11.2.10.10 and re-root.

    If you're unsure about the slot, do fastboot getvar current-slot, then flash the correspondent commands/images accordingly.

    By the way, the "Partitions Backup & Restore" app from play store does backup both slots for each, which puts your mind at ease when you do, so you get "dtbo_a" and "dtbo_b" and so on.

    4
    Reflashing the whole ROM is not a option - it would take too much time to restore all my data.

    And your answer does not help at all.... oO Your answer is like "ah you have a problem with your windows - reinstall it and dont try to fix it"
    he mean just make "dirty" flash without wiping anything. I did that just for testing, and everything goes well
    3
    Daam, I don't use telegram, so I won't set up new account only for that. Will try to flash stock 11.2.9.9 via adb when I come from work.

    -- update --

    Did it differently - installed twrp, than flashed 11.2.10.10 dowloaded with Oxygen Updater, than flashed Magisk and flashed kernel with twrp.
    Everything seems to be working fine with newest update. Took me like 5 mins.

    I was going to try twrp anyway, so I had a good reason to do so :)
    3
    Have you faced any random reboots with r2?
    yep, although it took a while to get one (others were getting random reboots sooner than I was) -- in short, when I open my camera, I have about a 1 in 4 chance of getting a reboot, don't know why, but that is the only time I get them. went back to stock bc having my phone reboot when trying to take a video on xmas is something I don't feel like dealing with unfortunately. thing is this kernel is awesome in every way and I wish I could continue using, but that's the deal breaker for me
  • 42
    arter97-xda.png



    arter97 kernel for OnePlus 9 series running OxygenOS

    /* Features */

    Supports OnePlus 9 series
    Fully rebased kernel without unnecessary OnePlus code
    Latest CAF msm-5.4 kernel fully merged
    Latest Linux v5.4 subversion merged
    Latest Google’s security fix merged
    BBR as the default TCP network congestion control
    Features the latest WireGuard
    Modules support disabled for lighter kernel
    Latest Wi-Fi drivers from Qualcomm with customized config
    Built with Clang 12 and ThinLTO
    Power optimizations
    Memory management optimizations
    Latest SELinux subsystem backported from mainline
    Latest f2fs backported from mainline
    Latest BFQ I/O scheduler backported from mainline
    mmap/mremap backported from mainline for a major performance boost
    Touchscreen optimizations for lower latency
    Uses LRNG for better performance

    /* Details */

    - Fully rebased kernel without unnecessary OnePlus code -



    This kernel is not based on the stock OxygenOS kernel source provided by OnePlus. Instead, it’s based on the latest and greatest Qualcomm has to offer. Only the necessary parts from the OnePlus kernel have been cherry-picked, such as OnePlus 9 specific device drivers.

    This effectively kills all kernel modifications/optimizations from OnePlus, including the infamous app throttler.
    Due to the completely different base, this kernel will behave drastically different from other kernels, in both good and bad ways.


    - Power optimizations -


    This kernel makes some conscious decisions for reducing power consumption.

    First, the stock OnePlus configuration forces display-related processes to use the big cores exclusively.
    This configuration brings a huge power regression since it makes every frame dispatch to wake up and use the power-hungry cores.

    This kernel resets this profile to use the configuration Google recommends, which is to use the LITTLE cores exclusively instead. (Reverted in r2 as it seems like that little cores aren't enough to drive 120 Hz fluidly.)
    This kernel allows these processes to use little and middle cores (0-6), depending on the load.

    Second, this kernel disables wakelocks upon Wi-Fi’s RX unicast packet transmissions. qcom_rx_wakelock is one of the major culprits to increased idle power consumption. Although its total wakelock time is quite low, it's catched very frequently and prevents the system from entering suspend repeatedly.

    As dropping unicast or local ARP packets doesn’t pose practical issues on Android, this kernel disables qcom_rx_wakelock.

    Third, this kernel reduces the duration of the Bluetooth ISR wakelock from 2 seconds to 100ms. This was done from an observation that the average userspace response time from ISR is less than 10ms.
    My kernels have been doing this for years and no Bluetooth-related issues were reported.

    Fourth, the vibrator driver used in this kernel no longer controls the cpuidle driver. The stock kernel disables the cpuidle whenever the vibrator is used. This kernel disables it as the vibrator is not that sensitive to deadline misses.

    There are other small improvements throughout the kernel tree as well.


    - Memory management optimizations -


    This kernel disables LMKD and uses an in-kernel solution called SimpleLMK, made by kerneltoast. You can track how often SimpleLMK kicks in by monitoring:
    Code:
    /sys/module/lowmemorykiller/parameters/lmk_count

    This kernel also changes a lot related to swap and zram.

    The swap-related code has been backported from Linux v5.9 (link1, link2) to efficiently support fast swap device and allow swappiness over 100. This kernel currently sets swappiness to 160 on < 6GB of RAM, 120 on 8GB and 90 on 12GB.

    zram has been also backported from mainline Linux and further tweaked to use block device writeback. This is equivalent to the recent “RAM Plus” feature that companies have been marketing that uses the internal storage to extend RAM.

    This kernel uses zram writeback to offload idle pages (i.e., really, really unused RAM) to the internal storage. As it's extremely slow to bring pages back from UFS, writeback code works quite conservatively. It'll start to writeback pages that haven't been used for a day or two. It makes use of the hidden 2GB “last_parti” partition from the UFS storage.

    Along with zram writeback, this kernel also enables deduplication with xxHash. Each page stored in zram is checked for deduplication to further save memory. With these 2 features combined, RAM reaching 1GB is additionally saved, but your mileage may vary.

    The post boot script used in the stock ROM is also overridden and it sets the readahead to 128KB. As I/O workload under Android is mostly random, high readahead doesn’t help and only increases memory thrashing.

    This kernel also incorporates a lot of patches to reduce/optimize memory allocations used throughout the entire kernel.

    mmap/mremap code was also backported from Linux v5.10 to optimize ART (see here for more info).


    - Latest subsystems -


    This kernel backports the SELinux subsystem from mainline Linux. This includes caching improvements that drastically reduces time spent on lookups. 10K lines of code has been changed.

    This kernel also backports f2fs (Flash-Friendly File System) from mainline Linux. This includes bug fixes and performance improvements such as shorter discard latency, more optimized GC logic for Android, and checkpoint merging.

    BFQ I/O scheduler has also been backported from mainline Linux for better I/O performance.


    - LRNG -


    This kernel ditches the traditional RNG driver from the Linux kernel in favor of LRNG. See here and here for more info.

    A rudimentary throughput benchmark shows an improvement of 10.5% (keep in mind that this is only one aspect of an RNG metric).


    /* Notice */

    Only OxygenOS on Android 11 is supported.

    This kernel touches vendor_boot and dtbo partitions, meaning you'd need to restore said partitions whenever you're switching to another kernel or stock.
    Please make a back-up of these partitions. The installer doesn’t do this automatically for you. Installing the stock ROM with a full OTA restores said partitions as well.

    /* Disclaimer */

    Your warranty is now void.
    I am not responsible for bricked devices, dead SD cards,
    thermonuclear war, or you getting fired because the alarm app failed. Please
    do some research if you have any concerns about features included in this kernel
    before flashing it! YOU are choosing to make these modifications, and if
    you point the finger at me for messing up your device, I will laugh at you. Hard. A lot.

    /* Thanks to */

    Vishalcj17
    kristofpetho
    kdrag0n
    kerneltoast (SultanXDA)

    /* Instructions */

    1. Read the above. Please.
    2. Flash the zip file from FK Kernel Manager. Any other installation methods are untested.

    /* Downloads and links */

    arter97.com
    Kernel source
    Telegram chat link
    18
    r2 is up, and it's a big release.

    Changelog is quite self-explanatory.

    r2
    Display-related processes are now allowed to use the middle cores as well for better smoothness
    Enabled more mremap() performance improvement that was missing from r1
    LA.UM.9.14.r1-18400-LAHAINA.0 merged
    LA.UM.9.16.r1-08100-MANNAR.0 merged
    LA.UM.10.9.1.r1-00300-QCS610.0 merged (contains a lot of new improvements including power optimizations)
    Linux v5.4.159 merged
    Wi-Fi drivers updated to 2.0.8.25M
    2021-11-06 security patch merged
    Watermark boosting disabled to fix aggressive app killings (by Sultan)
    Workaround added to fix unwanted doubles presses from the power button
    15
    After using the kernel myself and daily driving for few days and monitoring how the kernel behaves, I now feel comfortable to mark it stable.

    r1 is released.

    The original post is re-written to feature what's special with this kernel.
    Please take your time and re-read the original post.
    10
    /* Changelog */

    r2

    Display-related processes are now allowed to use the middle cores as well for better smoothness
    Enabled more mremap() performance improvement that was missing from r1
    LA.UM.9.14.r1-18400-LAHAINA.0 merged
    LA.UM.9.16.r1-08100-MANNAR.0 merged
    LA.UM.10.9.1.r1-00300-QCS610.0 merged (contains a lot of new improvements including power optimizations)
    Linux v5.4.159 merged
    Wi-Fi drivers updated to 2.0.8.25M
    2021-11-06 security patch merged
    Watermark boosting disabled to fix aggressive app killings (by Sultan)
    Workaround added to fix unwanted doubles presses from the power button

    r1
    First stable release
    9
    Another new alpha build is up with big changes yet again.
    I still have quite a few TODOs left, but I ported many changes from my OnePlus 7 Pro kernel.

    Wi-Fi will behave differently with this kernel, so please let me know if you encounter Wi-Fi issues.

    r1a7

    Wi-Fi configuration merged with the latest CAF
    Wi-Fi's rx_wakelock disabled and removed
    Support for WireGuard added
    Bunch of memory optimizations
    Bunch of optimizations for screen and the GPU driver