yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] capntrips:
Are you using the allow-errors build? I suppose I could have uploaded the wrong APK, so I added a reupload, just in case.
[Android Apps and Games] cultofluna:
Latest alpha-20 build
[Android Apps and Games] capntrips:
The fix in the allow-errors build is not included in that build. Github has them listed in the wrong order, since they were posted on the same day and semver ignores the +allow-errors.
[Android Apps and Games] cultofluna:
Thanks..

The allow-errors build is working
[Android Apps and Games] anthonnyb98:
@capntrips Do you know how I can make kernel flasher work, in kernelsu? I am using the root method through init_boot for sure it works.
[Android Apps and Games] capntrips:
Have you tried the v1.0.0-alpha20+allow-errors build? If that does not resolve the issue, can you elaborate on what doesn't work?
[Android Apps and Games] anthonnyb98:
With that version you mention at least the application opens for me, with the official one it doesn't. This is the error I have now.
[Android Apps and Games] capntrips:
That error is expected. You can see my comments in the most recent discussion in this thread and in the Github issue thread for additional details.
[Android Apps and Games] anthonnyb98:
I I tried flashing the kernel and it worked but I lost root to kernelsu. When I try to root again with KernelSU I get this error.
[Android Apps and Games] capntrips:
Does whatever kernel you flashed support KernelSU? I don't use KernelSU, so I can't really debug issues with it. If the kernel zip flashed without error, the issue likely isn't with Kernel Flasher.

Maybe one of the KernelSU users watching the thread can give some insight.
[Android Apps and Games] anthonnyb98:
Thanks for the prompt response, you are right, that could be the problem, I have contacted the kernel developer to give me more information.
[Android Apps and Games] badabing2003:
I'll chime in with what little I know based on the work I did to add support for KernelSU in PixelFlasher.

Since version 0.9.0, KernelSU supports two running modes on GKI devices:

GKI: Replaces the original kernel of the device with the Generic Kernel Image (GKI) provided by KernelSU.

In this mode regardless if the device has init_boot partition or not, boot partition is patched as the kernel is in the boot partition.

LKM: Load the Loadable Kernel Module (LKM) into the device kernel without replacing the original kernel.

In this mode, if the device has init_boot partition then init_boot is patched as the ramdisk is in init_boot, and only that is modified and the kernel in boot partition left intact.

If the device does not have init_boot partition, then the ramdisk is in bot partition and boot partition is modified again keeping kernel intact

In both cases, the Kernel should be GKI.

Is your kernel GKI?.
[Android Apps and Games] anthonnyb98:
I think the problem I'm having is due to the kernel I want to use. It is the Sultan Kernel for the Pixel 8 Pro. I leave you the link. https://xdaforums.com/t/kernel-sultan-kernel-for-pixel-8-pro-april-2-2024.4665173/
[Android Apps and Games] badabing2003:
If you have the Kernel on your device, run PixelFlasher (link found in my signature) and scan and select your device.

Tell me what it tells your what your KMI is:

It should look something like this. (this is not from Pixel 8 Pro)
[Android Apps and Games] anthonnyb98:
Selected Device on 2024-04-06 18:06:22:
Device ID: 37201......FNY
Device Model: husky
Device Active Slot: a
Device Mode: adb
Device Name: Pixel 8 Pro
Device First API Level: 34
Device Version End Date: October 2026
Device Secuity Update End Date: October 2030
Has init_boot partition: True
Device Bootloader Version: ripcurrent-14.4-11403750
Device is Rooted: False
Device Build: AP1A.240405.002
Device API Level: 34
Android Version: 14
Android Name: Android 14
Android Codename: Upside Down Cake
Android Release Date: Q3 2023
Android Latest Update: Present
Device Architecture: arm64-v8a
Device Kernel: Linux localhost 5.15.131-Sultan #1 SMP PREEMPT Tue Apr 2 23:36:53 PDT 2024 aarch64 Toybox
Device Kernel Version: 5.15
Device KMI:
sys_oem_unlock_allowed: 1
ro.boot.flash.locked: 0
ro.boot.vbmeta.device_state:
ro.product.first_api_level: 34
ro.boot.veritymode:
ro.boot.verifiedbootstate: orange
ro.secure: 1
ro.zygote: zygote64
ro.vendor.product.cpu.abilist: arm64-v8a
ro.vendor.product.cpu.abilist32:
Magisk Manager Version: :
Checked for Package: com.topjohnwu.magisk

WARNING! Problematic Kernel: Linux localhost 5.15.131-Sultan #1 SMP PREEMPT Tue Apr 2 23:36:53 PDT 2024 aarch64 Toybox is installed. Play Integrity would possibly fail.

Kernel string: -Sultan is known to be banned.

This is what I get, it appears blank. Could it be that the kernel does not have the KMI specified and that is why KernelSU does not detect it as a KMI?
[Android Apps and Games] osm0sis:
Worth noting that most active custom kernel developers have now added patches to circumvent the Play Integrity kernel string ban.

I was just updating my Known Banned Kernel List post about it:

🔧 [MODULE] Play Integrity Fix (SafetyNet fix)

PLAY INTEGRITY FIX This module tries to fix Play Integrity and SafetyNet verdicts to get a valid attestation. BEFORE YOU START: - Your ROM must be signed with a private key from maintainer, you can check with this command: unzip -l...

xdaforums.com
[Android Apps and Games] badabing2003:
if you patch your Kernel String to: 5.15.131-android14 not only it would help you with playintegrity, but also KernelSU will detect it as a valid KMI and create a patch.

In a future release of PixelFlasher, I'll add the ability to pass -kmi flag to KernelSU to override the value, but that would still not help your with PlayIntrgrity, it would just allow you to create a patch.

Ideally Sultan should address the issue.
[Android Apps and Games] anthonnyb98:
Thanks for the explanation, can I take your words and mention it in the kernel topic?
[Android Apps and Games] osm0sis:
Sultan's latest kernel builds all have his patch to circumvent the string check. See here:

[KERNEL] Sultan Kernel for Pixel 8/Pro [June 11, 2024]

/* * Your warranty is no longer valid, unless you lie. * * I am not responsible for bricked devices, strained relationships, * thermonuclear war, or you getting fired because the alarm app failed. Please * do some research if you have any...

xdaforums.com
[Android Apps and Games] anthonnyb98:
You mean that just adding the ability to pass the -kmi flag to KernelSu to override its value, as badabing2003 mentions above, would work?
[Android Apps and Games] badabing2003:
I think his patch is only patching for gms.unstable process.

I don't think it would help for KernelSU patching in this case unless additional flags are passed to KernelSU as mentioned above, otherwise KernelSU would still find the KMI invalid.

That alone will make your current Kernel fail PlayIntegrity, but will let KernelSU create a patch.

If you get the latest from Sulatn, and pass the KMI flag, then you get covered for both.
[Android Apps and Games] Melomi:
Does it require root first?
[Android Apps and Games] YMatrix:
Yes
[Android Apps and Games] Alk142:
Indeed. And here was I, hoping that I could use that app to *obtain* root (Vankyo S8, without any published OS updates :-( )
[Android Apps and Games] phaino00:
I flashed Despair kernel on A13 the other day with no issues.

Forgot to mention, I have the Pixel 6.
[Android Apps and Games] capntrips:
A new version is up. Here's the changelog:

I didn't make an update post for it, but alpha07 fixed a bug in the flash shell, which affected the newest AK3 on some devices. Also, the splash screen issue in alpha07 has been fixed.

Kernel update URLs and manual partition flashing are both on my shortlist for the next update.

I had vendor_boot set to required, so I made it optional. The whole required/optional thing will go away when I've added partition selection to backup and restore.

I added dtbo, init_boot, and recovery to the optional partitions list.
[Android Apps and Games] osm0sis:
Thanks! Not seeing dtbo and recovery get backed up when I make a backup on my 8T though. Both are slotted partitions. Looks like it only backs up boot now. I guess once it's optional this'll all get ironed out. 🤞

Hopefully advanced reboot menu is still on the to-do as well. 😋
[Android Apps and Games] capntrips:
It initially looks for boot in /dev/block/by-name, then it looks there for all physical partitions, as well. It looks for all logical partitions in /dev/block/mapper. vendor_dlkm is assumed to be the only logical partition in that list.

I may need to make some of that more generic. Let me know the details for the 8T, and I'll see what I can do. I've already added Hashtree Patcher to the latest builds, so I may just refactor everything to read from fstab.

Marking a partition as optional just prevents it from throwing an exception if it doesn't find it.

I just gave this a go and it seems to be working fine. I'll clean it up and get it into the next release. The commit message for this didn't give any context and a quick test without it didn't yield any interesting results, so I'm going to ignore it for now.
[Android Apps and Games] osm0sis:
Ah, I'd suggest /dev/block/by-name then /dev/block/bootdevice/by-name then /dev/block/platform/*/*/by-name or /dev/block/platform/*/by-name to cover all eras of devices.

8T has all of those (except the /*/ version of the last one, devices either have one or the other there), and the partitions in question are:

/dev/block/by-name/boot_a

/dev/block/by-name/boot_b

/dev/block/by-name/dtbo_a

/dev/block/by-name/dtbo_b

/dev/block/by-name/recovery_a

/dev/block/by-name/recovery_b

It also does have logical partitions, but no vendor_dlkm on OOS11 at least.

About that screen blanking code for reboot recovery, it's necessary on some OEM devices since with the screen on reboot recovery shows a scary "Rebooting to factory reset..." type message. Conversation on same here, for reference: https://github.com/topjohnwu/Magisk/pull/5637#issuecomment-1076060764
[Android Apps and Games] capntrips:
I changed the detection function to use the fstab entries. vendor_boot does not appear in fstab, so I had to keep the path search as a fallback. I tried to find the code that loads vendor_boot in AOSP, so I could use the same magic, but I had no luck.

Since dtbo and recovery are in the same place as boot, I'm not sure why it didn't save them. I was previously using the standard File.exists(), so I changed everything to use SuFile, so we'll see if that gets it fixed.

Thanks for the context. I'll include it.

I'll try to get the build out tomorrow.
[Android Apps and Games] osm0sis:
There are lots of things not in the fstab, so those fallback paths are important for sure. Thanks for your ongoing efforts! This is awesome. 😁
[Android Apps and Games] capntrips:
I pushed a new build, and here are the changes:

There were significant changes to the backup and restore functions, most notably they moved to /sdcard/KernelFlasher for ease of access from a file manager, and the metadata file is now JSON. As this breaks the old backups, I added a Migrate button on the Backups page, which I'll drop when the app goes stable.

I finally got around to reading the libsu 5.0.0 changelog and javadoc, and SuFile is eventually going away, so I started migrating to ExtendedFile. This is still a WIP, but all of the pieces are there.

I ended up doing basically all of the planned features except the ones I had previously planned to work on. Assuming this build doesn't crash and burn, once I get the remaining features added, I'll probably mark the next build as beta or rc.

P.S. I got a Pixel 6a today, so I'll likely make my Pixel 6 my daily driver (a year later) and the 6a my primary development device.

Any idea where/how those partitions are defined?
[Android Apps and Games] osm0sis:
Ah I see boot, dtbo, recovery and vbmeta are indeed backed up, but there's no indication in the app what partitions are present in a backup. Working well though! This is excellent! 🤘
[Android Apps and Games] capntrips:
I was looking more for where they are defined offline.

I suppose they could just be directly from the partition table. I'll see if that turns up anything.

I'm planning to add on-screen logging and the save capability to the backup and restore functions, as with flash. I'm planning to display the partition and image hashes somehow, as well.
[Android Apps and Games] capntrips:
A new build is up, It adds the ability to check for and download updates from FKM style update URLs. There are still a few things that need to be added in a future build:

it does not provide the option to flash directly

it does not check for updates automatically (either on-load or in the background)

it does not validate the input in the url field

I'm still undecided on doing periodic checks in the background. If this is something you want, feel free to comment.

I'm planning to add manual image flashing next.
[Android Apps and Games] HTC TyTN user:
Good day. Sorry for noob question, but does this flasher will work on Pixel4 ?
[Android Apps and Games] capntrips:
If you're flashing an AK3 zip for your device, the app should theoretically be relatively device agnostic. It has been tested on at least Pixel 6, OnePlus 9 Pro, and OnePlus 8T. If you try it, let us know how it goes.
[Android Apps and Games] soker111:
HELLO! PIXEL6 Kirisakura-Kernel 4.1.0, need to flash on both sides（slotA slot B）？ tk
[Android Apps and Games] capntrips:
I have seen it suggested that you at least flash the bootloader to both slots for Android 13 on Pixel 6, so you don't end up in an unbootable state if your current slot fails to boot, otherwise there is no need to flash both slots to install a kernel.

Edit: Also, Kernel Flasher will only allow you to flash to the active slot.
[Android Apps and Games] rafik25:
Hello any link to dl plz ?
[Android Apps and Games] capntrips:
The first link in the OP is to the Github repo:

You can find the download on the releases page.
[Android Apps and Games] capntrips:
A new build is up, and here are the changes:

While the app now displays the hashes of the backed up images, it does not display the live partition hashes. If this is something you might find useful, feel free to comment.

This build wraps up all of the major planned features, and assuming no significant issues arise, this will be the last alpha build, and the next few builds will likely focus on cleaning things up a bit.

The biggest remaining changes are related to the Updates feature, and I imagine they'll be the bulk of the next build.

Note: This build does not include the latest build of lptools, so be careful with the restore function after an OTA. See here for details. It will be included in the next build.
[Android Apps and Games] osm0sis:
This is looking great! My only feedback is that it would be nice if when displaying kernel version it would also show the build # a lot of developers use to show their versions/revisions.

E.g. 4.19.110+blu-spark-OOS #130
[Android Apps and Games] cultofluna:
Hi , thanks for the great app

Supports flashing vendor_ dlkm , vendor_ boot img also?..( asking because if yes ..i can restore stock kernel on my p6pro without using a pc)..it could be useful
[Android Apps and Games] capntrips:
This is done in my personal build, will be included in the next release. For long kernel strings, you can tap the text to reveal the whole thing. The full string will be included in any new backups, as well.

Yes, it supports boot, vbmeta, dtbo, vendor_boot, vendor_dlkm, init_boot, and recovery on the devices that include them. For logical partitions (vendor_dlkm), it uses the same method as AK3 to flash it. The note about lptools from my last message applies.
[Android Apps and Games] Ghisy:
Hey @capntrips!

I don't know if you're still maintaining this app but it doesn't work on the newest Pixel 7 Pro: it says "no boot.img found" when starting up the app.

I know rooting is now done with the new init_boot.img file instead of the boot.img before. Maybe it can help you to update your app.
[Android Apps and Games] capntrips:
I'm expecting delivery of a Pixel 7 today. I've got a lot going on in the next few weeks, but I'm sure I won't be able to help myself and will dive into it over the weekend, if not sooner.
[Android Apps and Games] capntrips:
A new build is up and the changes are:

This defaults to init_boot as the source of the ramdisk, if it is present. As I was typing this, I realized this will break the kernel version search on those devices, so I'll likely need to keep up with both going forward. I'll look into that in the next day or so.
[Android Apps and Games] osm0sis:
Can the kernel version check in each slot be automatic? It seems pretty quick on every device I've tried.

Same goes for checking for kernel update via json. Then there could be an indicator of some kind on the top level button when there's an update pending?
[Android Apps and Games] capntrips:
The kernel check takes right at 10 seconds on a Pixel 6. While not strictly slow, when done frequently, it really seems to make the app seem sluggish. I've left it up to the user to know if they need to check it, but I can see the appeal of having it done automatically, especially before backups and after flash/restore. It already does it before backups on the inactive slot.

I had previously avoided adding it to the refresh function, which is also called on app load, but I suppose I could have the kernel check done on app load outside of that function, so it doesn't affect refresh (which really only affects vendor_dlkm status, anyway).

If the user is doing their own flashing outside of the app, they can just press the button.

As for automatic json kernel update checks, I've had it on my todo list since I started working on the feature, but I just haven't carved out the time to get it implemented. I'll try to take another look at it in the next few days.
[Android Apps and Games] krkhaha:
Which slot should I select when I flashing kernel? I mean pixel 7 pro
[Android Apps and Games] capntrips:
The active one (as displayed in the device section). Also, you should only be presented with the option to flash to the active slot. The other slot only allows you to make backups.
[Android Apps and Games] capntrips:
{Mod edit: Quoted post has been deleted}

the question seems to be missing
[Android Apps and Games] osm0sis:
Spam links. Reported. 🙂
[Android Apps and Games] Neuken6969:
directions to flash a kernel? i see slot a and slot b .. dont want to brick anything
[Android Apps and Games] capntrips:
View the active slot (as displayed in the device section). Click flash and select the AK3 zip for the kernel you're flashing.

Note: You should only be presented with the option to flash to the active slot. The other slot only allows you to make backups.
[Android Apps and Games] dimm0k:
help, stock Android 13 October '22 update and Pixel 4XL, but app is crashing on start after getting root
[Android Apps and Games] capntrips:
Can you share a logcat?
[Android Apps and Games] -Happy Feet-:
Hello,

I tried to Install the Kernel in my Pixel 6 Pro. But got an Error when flashing the vendor_dlkm3.

Kirisakura_Raven-4.4.2_A13_stable.zip was flashed.

The settings and the App says after flashing i had installed the Kirisakura Kernel, so i think ITS currently unbootable.

I made an backup with the Kernel Flasher before flashing, So i think the solution ist to restore the previous Kernel, or Not?
[Android Apps and Games] capntrips:
Yes, though you may get the exact same error when you attempt to restore the backup. If so, you should be able to skip vendor_dlkm on restore and still be fine. In any case, you may want to be prepared to install a factory image on the next reboot.

As for the error itself, it appears your super partition isn't large enough to hold the temporary vendor_dlkm during the replace operation. You'll likely need to mod the kernel zip to get it flashed with a resize instead of a replace. If you're interested in pursuing that, I'll see if I can provide a patch.

Edit: I doublechecked the source, and Kernel Flasher should fallback on a resize if replace fails, so the backup should restore even if there's not enough room for the latter.
[Android Apps and Games] -Happy Feet-:
That would be nice.
[Android Apps and Games] capntrips:
Support for resize fallback was added to AK3 here. So we'll copy the kernel files from the Kiri zip to the latest AK3.

Grab the latest AK3 with either git or by downloading and extracting the zip. Copy anykernel.sh, banner, dtbo.img, Image.lz4, modules, vendor_boot.img, and vendor_dlkm.img from the kernel zip to the AK3 folder. Then zip the contents of the AK3 folder.

If you're on Linux, you can run the following from wherever you have the kernel zip:

mkdir Kirisakura_Raven-4.4.2_A13_stable
unzip Kirisakura_Raven-4.4.2_A13_stable.zip -d Kirisakura_Raven-4.4.2_A13_stable
git clone https://github.com/osm0sis/AnyKernel3.git
cd AnyKernel3
cp -a ../Kirisakura_Raven-4.4.2_A13_stable/{anykernel.sh,banner,dtbo.img,Image.lz4,modules,vendor_boot.img,vendor_dlkm.img} .
zip -r9 ../Kirisakura_Raven-4.4.2_A13_modified.zip * -x .git README.md *placeholder
cd ..
[Android Apps and Games] -Happy Feet-:
Thanks for helping.

I think it would work when i reflash the custom Rom. Same Error with the modified Kernel.

But Thanks fot your Help.
[Android Apps and Games] capntrips:
It looks like it tried to resize it, but it was unable to unmap the partition. My only other suggestion would be to flash the vendor_dlkm and dtbo (AK3 flashes it after vendor_dlkm) images in fastboot.
[Android Apps and Games] -Happy Feet-:
Yes, i think so
[Android Apps and Games] capntrips:
A new build is up, here are the changes:

Thanks to @tiann for the contributions.

The changes to kernel version detection and automatic update checks discussed with the release of alpha12 are still on my todo list. There is a bug that affects at least some Pixel 4a and OnePlus 7 Pro users that may force an update sooner than later. In either case, I'll make an effort to get those changes made in the next few days, most likely next weekend.

P.S. If you have Pixel 4a or OnePlus 7 Pro, feel free to get involved here. I don't have either of those devices, so I rely on others to run the tests.
[Android Apps and Games] capntrips:
A test build, v1.0.0-alpha12+tempfs, that fixes this issue is up. I'll make a proper release in the next few days soon.
[Android Apps and Games] halfbytecode:
I'm really liking this app. Good work.

I have two suggestions. Please add confirmation dialogs before the flash zip/image process initiates to prevent accidental flashes.

It would also be appreciated if an option to flash "vendor_kernel_boot" partition is added. It seems to be needed for kernels on Pixel 7 series.
[Android Apps and Games] sinnbro:
Hello 👋

Do you have any ideas that I can't access this app after I flashed anykernel?

It says invalid boot.img
[Android Apps and Games] capntrips:
Both excellent suggestions. I'll try to slap together a build with at least the latter and the tempfs fix below this weekend. I'll add the former to the v1.0.0 stable roadmap.

It is likely related to this. This has been fixed in v1.0.0-alpha1I2+tempfs.

As noted above, I'll try to get at least this and vendor_kernel_boot into a release this weekend.
[Android Apps and Games] capntrips:
A new build is up, and here are the changes:

Thanks to @eng.stk, @osm0sis, @powellnorma, and @xfzv for the help debugging and testing the cpio/fscrypt issue and tmpfs builds.

Thanks to @halfbytecode for the vendor_kernel_boot suggestion.

I anticipate releasing another build in the next few days at some point with a few of the previously discussed features and one or two others. I imagine I'll consider 1.0.0 to be feature complete at that point and mark it beta01.
[Android Apps and Games] jlokos:
Thanks for your development of the flasher. I'm on ExoX on Raven and flashed the radioactive kernel. I got an error message. I'm grateful that the app allows you to save the log, but I'm not sure I understand the error. Any insights on what the issue is would be appreciated.