phaino00
Senior Member
Does it throw an error message? If not, is there anything in thelogcat
?
I flashed Despair kernel on A13 the other day with no issues.
Forgot to mention, I have the Pixel 6.
Does it throw an error message? If not, is there anything in thelogcat
?
I flashed Despair kernel on A13 the other day with no issues.
added Hashtree Patcher for mount and unmount
added additional optional partitions
hid vendor_dlkm elements on devices without
Got some errors trying to backup on my 8T since there's no vendor_boot, so I guess some logic will be needed for whether they exist.
Probably the feature should be like "backup slot" and save init_boot, boot, vendor_boot, dtbo, recovery, vendor_dlkm and vbmeta from the chosen slot if any of them exist.
I added dtbo, init_boot, and recovery to the optional partitions list.
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.
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.fstab
.It initially looks forboot
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 fromfstab
.
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.
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.
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./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
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.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
I changed the detection function to use thefstab
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 loadsvendor_boot
in AOSP, so I could use the same magic, but I had no luck.
Sincedtbo
andrecovery
are in the same place asboot
, I'm not sure why it didn't save them. I was previously using the standardFile.exists()
, so I changed everything to useSuFile
, 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.
addedfstab
entries as primary source of block devices
addedresize
fallback when not enough room for temporary partition
moved backups to/sdcard/KernelFlasher
replaced backup prop metadata with json and data classes
added backup partition hashes to backup metadata
restored AK3 zip filename to flash log
added advanced reboot menu
/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.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.There are lots of things not in the fstab, so those fallback paths are important for sure.
/dev/block/by-name
/dev/block/bootdevice/by-name
/dev/block/platform/*/*/by-name
/dev/block/platform/*/by-name
system /system ext4 ro,barrier=1,discard wait,slotselect,avb=vbmeta_system,logical,first_stage_mount,avb_keys=/avb/q-gsi.avbpubkey:/avb/r-gsi.avbpubkey:/avb/s-gsi.avbpubkey
system_ext /system_ext ext4 ro,barrier=1,discard wait,slotselect,avb=vbmeta_system,logical,first_stage_mount
product /product ext4 ro,barrier=1,discard wait,slotselect,avb=vbmeta_system,logical,first_stage_mount
vendor /vendor ext4 ro,barrier=1,discard wait,slotselect,avb,logical,first_stage_mount
odm /odm ext4 ro,barrier=1,discard wait,slotselect,avb,logical,first_stage_mount
/dev/block/by-name/metadata /metadata ext4 noatime,nosuid,nodev,discard,sync wait,check,formattable,first_stage_mount
/dev/block/bootdevice/by-name/op2 /mnt/vendor/op2 ext4 noatime,nosuid,nodev,barrier=1,data=ordered wait,check
/dev/block/bootdevice/by-name/userdata /data f2fs noatime,nosuid,nodev,discard,reserve_root=32768,resgid=1065,fsync_mode=nobarrier,inlinecrypt latemount,wait,check,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized+wrappedkey_v0,metadata_encryption=aes-256-xts:wrappedkey_v0,keydirectory=/metadata/vold/metadata_encryption,quota,reservedsize=512M,sysfs_path=/sys/devices/platform/soc/1d84000.ufshc,checkpoint=fs
/dev/block/bootdevice/by-name/persist /mnt/vendor/persist ext4 noatime,nosuid,nodev,barrier=1 wait
/dev/block/bootdevice/by-name/misc /misc emmc defaults defaults
#/devices/platform/soc/8804000.sdhci/mmc_host* /storage/sdcard1 vfat nosuid,nodev wait,voldmanaged=sdcard1:auto,encryptable=footer
#/devices/platform/soc/1da4000.ufshc_card/host* /storage/sdcard1 vfat nosuid,nodev wait,voldmanaged=sdcard1:auto,encryptable=footer
/devices/platform/soc/*.ssusb/*.dwc3/xhci-hcd.*.auto* /storage/usbotg vfat nosuid,nodev wait,voldmanaged=usbotg:auto
#/dev/block/bootdevice/by-name/spunvm /mnt/vendor/spunvm vfat rw,noatime,shortname=lower,uid=1000,gid=1000,dmask=007,fmask=007,context=u:object_r:vendor_spunvm_file:s0 wait
/dev/block/bootdevice/by-name/modem /vendor/firmware_mnt vfat ro,shortname=lower,uid=1000,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait,slotselect
/dev/block/bootdevice/by-name/dsp /vendor/dsp ext4 ro,nosuid,nodev,barrier=1 wait,slotselect
/dev/block/bootdevice/by-name/bluetooth /vendor/bt_firmware vfat ro,shortname=lower,uid=1002,gid=3002,dmask=227,fmask=337,context=u:object_r:bt_firmware_file:s0 wait,slotselect
:/ # ls /dev/block/by-name
ALIGN_TO_128K_1 keymaster_a qupfw_a
ALIGN_TO_128K_2 keymaster_b qupfw_b
ALIGN_TO_512K keystore rawdump
abl_a limits recovery_a
abl_b limits-cdsp recovery_b
abl_log logdump reserve1
aging_kernel logfs reserve2
aging_mod logo_a reserve3
android_log logo_b reserve4
aop_a mdm1m9kefs1 sda
aop_b mdm1m9kefs2 sdb
apdp mdm1m9kefs3 sdc
bluetooth_a mdm1m9kefsc sdd
bluetooth_b mdm1oemnvbktmp sde
boot_a mdm_oem_dycnvbk sdf
boot_b mdm_oem_stanvbk secdata
carrier mdmddr spunvm
cdt mdtp_a ssd
cmnlib64_a mdtp_b storsec_a
cmnlib64_b mdtpsecapp_a storsec_b
cmnlib_a mdtpsecapp_b super
cmnlib_b metadata tz_a
config misc tz_b
ddr modem_a uefisecapp_a
devcfg_a modem_b uefisecapp_b
devcfg_b modemdump uefivarstore
devinfo modemst1 userdata
dip modemst2 vbmeta_a
dsp_a msadp vbmeta_b
dsp_b multiimgoem_a vbmeta_system_a
dtbo_a multiimgoem_b vbmeta_system_b
dtbo_b multiimgqti_a vm-data
featenabler_a multiimgqti_b vm-keystore
featenabler_b oem_cust1_a vm-linux_a
frp oem_cust1_b vm-linux_b
fsc oem_cust2_a vm-system_a
fsg oem_cust2_b vm-system_b
hyp_a op1 xbl_a
hyp_b op2 xbl_b
hyp_log param xbl_config_a
imagefv_a persist xbl_config_b
imagefv_b persist_bkp
kernel_log qsee_log
:/ #
Code:/dev/block/by-name /dev/block/bootdevice/by-name /dev/block/platform/*/*/by-name /dev/block/platform/*/by-name
Probably Qualcomm or whoever defined these at some point, especially the old platform ones, then the bootdevice and direct by-name one were created by Google, Qualcomm or someone to simplify accessing them on newer devices.
But the fstab is only for things with somewhat defined mount points I guess?
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.
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.Good day. Sorry for noob question, but does this flasher will work on Pixel4 ?
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.HELLO! PIXEL6 Kirisakura-Kernel 4.1.0, need to flash on both sides(slotA slot B)? tk
Kernel Flasher is an Android app to flash, backup, and restore kernels.
added partition image flashing
added selective backup and restore
added output console for backup and restore
listed partition hashes
lptools
, so be careful with the restore function after an OTA. See here for details. It will be included in the next build.v1.0.0-alpha20
allow invalid inactive slot
allow non-A/B devices
addedpt_BR
translations (thanks to @igormiguell for the contribution)
allow-errors
build will ignore any kernel or ramdisk errors (even on the active slot), which will hopefully allow it to work with KernelSU installed as a kernel module mode. This may have implications in other areas. For example, since it allows a null sha1, it may behave unexpectedly when attempting to make backups when there is a ramdisk error. I'll make an effort to add a settings screen with toggles for sha1 and error handling before I remove the pre-release tag.Im getting this when im trying to launch the app ( rooted with kernelSU ( LKM method)
Thanks for the dumps. Someone reported what appears to be the same issue on Github here (I assume the KM above is for kernel module). I'm dealing with the flu, so hopefully I'm going to sleep for the next 12 hours, but I'll try to look at the dumps tomorrow.
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
.Thanks..The fix in theallow-errors
build is not included in that build. Github has them listed in the wrong order, since they were posted on the same day andsemver
ignores the+allow-errors
.
I'll chime in with what little I know based on the work I did to add support for KernelSU in PixelFlasher.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.
In both cases, the Kernel should be GKI.Thanks for the prompt response, you are right, that could be the problem, I have contacted the kernel developer to give me more information.
vendor_dlkm
may not be immediately available for backup after flash or restore. This can be resolved by unmounting, unmapping, then remapping it.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
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
lptools
from my last message applies.That is already done in my own personal test version of the app, but I haven't had a chance to clean it up and get it released. I'll make an effort to get that done this evening.Can you please leave the kernel installation log opened after the process ends with an error? Currently it's impossible to see what went wrong since the log disappears instantly and is being replaced by an error screen.
A test build, v1.0.0-alpha12+tempfs, that fixes this issue is up. I'll make a proper releaseThere is a bug that affects at least some Pixel 4a and OnePlus 7 Pro users that may force an update sooner than later.
fixedinit_boot
devices
added tap to expand for long strings
bumpedlptools
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.