Files in the top-level directory from the latest check-in
- patches
- src
- apply-patches.sh
- build.sh
- pinephone_defconfig
- quick-build.sh
- README.md
- setup.sh
- unapply-patches.sh
Experimental Mobian PinePhone Pro kernel patch
An experimental 6.16 kernel for Mobian with patches to improve battery life for the PinePhone Pro. The pre-built deb file contains the Mobian kernel patched with rk818_battery.patch and dwc3_core.patch:
git clone -b mobian-6.16 https://salsa.debian.org/Mobian-team/devices/kernels/rockchip-linux.git pinephonepro-linux
cd pinephonepro-linux
dpkg-source --before-build .
git apply ../patches/*.patch
dpkg-buildpackage -Pcross,nocheck -uc -us -b -aarm64 -nc
Patches
- rk818_battery.patch: reports
rsoc
instead ofdsoc
to the kernel as the battery percentage. In my testing (on 2 separate PinePhone Pro bought years apart), this results in a more accurate measure (as verified by measuring battery voltage at rest) especially when the phone is under load (e.g. watching YouTube video). Anecdotally, battery life for light web browsing goes from about 1.5 hours to over 3 hours with this patch. - dwc3_core.patch: works around a regression (since 6.12.36) that breaks the ability for the PinePhone Pro to go into suspend.
How to install
You need to be running updated Mobian. Download the deb file onto your phone, then:
sudo dpkg -i linux-image-6.16-rockchip_6.16.4-1_arm64.deb
to install it.- Shutdown your phone and remove the battery, and wait 10 minutes (to reset the battery meter)
- Boot into the new kernel. If you use U-Boot, "6.16" is this patched kernel, and "6.12" is the original kernel.
Notes
I am testing this kernel on a PinePhone Pro with:
- Megi's U-Boot (using rkbin build for more power saving)
- The Modem Distro flashed to my modem (potentially also saves power)
I am daily driving this kernel and it has been mostly stable and reliable so far. Current known issues:
- Battery percentage is sometimes wrong after a long suspend (overnight). Charging it will bump the percentage back to 100% once the battery is fully charged.
- Battery meter often gets stuck at 87% while charging, even when battery is fully charged
- Battery meter sometimes gets stuck while discharging and does not change even as battery discharges
- When plugging in a charger, charging is sometimes limited to 0.4A, and requires re-plugging one or more times to get the full 1.5A charge current
- Sometimes the phone crashes/hangs while in suspend, gets hot, and runs the battery down. Does not respond to power button, requires a hard reset by long-pressing the power button for > 5 secs.
- After a long battery charge, after disconnecting the charger, it takes a minute or more before the OS realises the charger is disconnected.
Repo
My changes can be tracked in this repo: