topjohnwu / Magisk

The Magic Mask for Android
GNU General Public License v3.0
48.29k stars 12.33k forks source link

Xperia 1 iii - v28.0 Crashes On Boot #8456

Open jasonlaguidice opened 2 weeks ago

jasonlaguidice commented 2 weeks ago

Device: Sony Xperia 1 iii / XQ-BC62 / pdx215 Android version: 13 Magisk version name: v28.0 Magisk version code: canary-28001

Cannot capture boot dmesg as adb never becomes available before device bootloops (no recovery environment available either) pstore_ramoops & last_kmesg unavailable on stock kernel

Contents of cat /proc/mounts:

XQ-BC62:/ $ cat /proc/mounts
/dev/block/dm-6 / ext4 ro,seclabel,relatime,discard 0 0
tmpfs /dev tmpfs rw,seclabel,nosuid,relatime,size=5708332k,nr_inodes=1427083,mode=755 0 0
devpts /dev/pts devpts rw,seclabel,relatime,mode=600,ptmxmode=000 0 0
proc /proc proc rw,relatime,gid=3009,hidepid=2 0 0
sysfs /sys sysfs rw,seclabel,relatime 0 0
selinuxfs /sys/fs/selinux selinuxfs rw,relatime 0 0
tmpfs /mnt tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755,gid=1000 0 0
tmpfs /mnt/installer tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755,gid=1000 0 0
tmpfs /mnt/androidwritable tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755,gid=1000 0 0
/dev/block/by-name/metadata /metadata ext4 rw,seclabel,nosuid,nodev,noatime,discard 0 0
/dev/block/dm-7 /system_ext ext4 ro,seclabel,relatime,discard 0 0
/dev/block/dm-8 /product ext4 ro,seclabel,relatime,discard 0 0
/dev/block/dm-9 /vendor ext4 ro,seclabel,relatime,discard 0 0
/dev/block/dm-10 /odm ext4 ro,seclabel,relatime,discard 0 0
tmpfs /apex tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755 0 0
tmpfs /linkerconfig tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755 0 0
none /dev/blkio cgroup rw,nosuid,nodev,noexec,relatime,blkio 0 0
none /sys/fs/cgroup cgroup2 rw,nosuid,nodev,noexec,relatime 0 0
none /dev/cpuctl cgroup rw,nosuid,nodev,noexec,relatime,cpu 0 0
none /dev/cpuset cgroup rw,nosuid,nodev,noexec,relatime,cpuset,noprefix,release_agent=/sbin/cpuset_release_agent 0 0
none /dev/memcg cgroup rw,nosuid,nodev,noexec,relatime,memory 0 0
tracefs /sys/kernel/tracing tracefs rw,seclabel,relatime,gid=3012 0 0
none /config configfs rw,nosuid,nodev,noexec,relatime 0 0
binder /dev/binderfs binder rw,relatime,max=1048576,stats=global 0 0
none /sys/fs/fuse/connections fusectl rw,relatime 0 0
none /sys/fs/bpf bpf rw,nosuid,nodev,noexec,relatime 0 0
pstore /sys/fs/pstore pstore rw,seclabel,nosuid,nodev,noexec,relatime 0 0
/dev/block/bootdevice/by-name/persist /mnt/vendor/persist ext4 rw,seclabel,nosuid,nodev,noatime,discard 0 0
/dev/block/bootdevice/by-name/modem_a /vendor/firmware_mnt vfat ro,context=u:object_r:firmware_file:s0,relatime,uid=1000,gid=1000,fmask=0337,dmask=0227,codepage=437,iocharset=iso8859-1,shortname=lower,errors=remount-ro 0 0
/dev/block/bootdevice/by-name/dsp_a /vendor/dsp ext4 ro,seclabel,nosuid,nodev,relatime 0 0
/dev/block/bootdevice/by-name/bluetooth_a /vendor/bt_firmware vfat ro,context=u:object_r:bt_firmware_file:s0,relatime,uid=1002,gid=3002,fmask=0337,dmask=0227,codepage=437,iocharset=iso8859-1,shortname=lower,errors=remount-ro 0 0
/dev/block/dm-41 /oem ext4 ro,seclabel,relatime 0 0
/dev/block/bootdevice/by-name/spunvm /mnt/vendor/spunvm vfat rw,context=u:object_r:vendor_spunvm_file:s0,noatime,uid=1000,gid=1000,fmask=0007,dmask=0007,allow_utime=0020,codepage=437,iocharset=iso8859-1,shortname=lower,errors=remount-ro 0 0
/dev/block/bootdevice/by-name/appslog /mnt/rca ext4 rw,seclabel,nosuid,nodev,noexec,noatime,discard 0 0
/dev/block/bootdevice/by-name/diag /mnt/idd ext4 rw,seclabel,nosuid,nodev,noexec,noatime,discard 0 0
tmpfs /storage tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755,gid=1000 0 0
/dev/block/dm-42 /data f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
tmpfs /linkerconfig tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755 0 0
/dev/block/dm-42 /data/user/0 f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
tmpfs /data_mirror tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=700,gid=1000 0 0
/dev/block/dm-42 /data_mirror/data_ce/null f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
/dev/block/dm-42 /data_mirror/data_ce/null/0 f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
/dev/block/dm-42 /data_mirror/data_de/null f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
/dev/block/dm-42 /data_mirror/cur_profiles f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
/dev/block/dm-42 /data_mirror/ref_profiles f2fs rw,lazytime,seclabel,nosuid,nodev,noatime,background_gc=on,discard,no_heap,user_xattr,inline_xattr,acl,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6,reserve_root=32768,resuid=0,resgid=1065,inlinecrypt,alloc_mode=default,fsync_mode=nobarrier 0 0
/dev/block/loop6 /apex/com.android.runtime@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop8 /apex/com.android.vndk.v30@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop6 /apex/com.android.runtime ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop7 /apex/com.google.mainline.primary.libs@331059000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop8 /apex/com.android.vndk.v30 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-40 /apex/com.google.mainline.primary.libs@350956000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-37 /apex/com.android.art@350913340 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-36 /apex/com.android.permission@350910080 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-32 /apex/com.android.wifi@350912040 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-31 /apex/com.android.cellbroadcast@350910020 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-36 /apex/com.android.permission ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-31 /apex/com.android.cellbroadcast ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-37 /apex/com.android.art ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-32 /apex/com.android.wifi ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop14 /apex/com.android.vndk.v33@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop14 /apex/com.android.vndk.v33 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-33 /apex/com.android.media@350914000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-30 /apex/com.android.neuralnetworks@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-34 /apex/com.android.os.statsd@350911020 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-30 /apex/com.android.neuralnetworks ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-33 /apex/com.android.media ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-34 /apex/com.android.os.statsd ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop20 /apex/com.android.vndk.v31@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop20 /apex/com.android.vndk.v31 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-29 /apex/com.android.adservices@351132000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-25 /apex/com.android.mediaprovider@350914160 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-29 /apex/com.android.adservices ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-25 /apex/com.android.mediaprovider ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-26 /apex/com.android.extservices@350912023 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-26 /apex/com.android.extservices ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-23 /apex/com.android.tzdata@332714070 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-23 /apex/com.android.tzdata ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-22 /apex/com.android.scheduling@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-24 /apex/com.android.conscrypt@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-20 /apex/com.android.appsearch@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-22 /apex/com.android.scheduling ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-24 /apex/com.android.conscrypt ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-20 /apex/com.android.appsearch ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-18 /apex/com.android.adbd@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-18 /apex/com.android.adbd ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop27 /apex/com.android.apex.cts.shim@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-21 /apex/com.android.ipsec@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-17 /apex/com.android.media.swcodec@350914020 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-21 /apex/com.android.ipsec ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-17 /apex/com.android.media.swcodec ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop27 /apex/com.android.apex.cts.shim ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-19 /apex/com.android.tethering@350911120 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-19 /apex/com.android.tethering ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop30 /apex/com.android.vndk.v32@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop30 /apex/com.android.vndk.v32 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-16 /apex/com.android.sdkext@350910000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-12 /apex/com.android.ondevicepersonalization@351134000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-16 /apex/com.android.sdkext ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-12 /apex/com.android.ondevicepersonalization ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop33 /apex/com.android.i18n@1 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/loop33 /apex/com.android.i18n ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-27 /apex/com.android.uwb@339990000 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-13 /apex/com.android.resolv@350820420 ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-27 /apex/com.android.uwb ext4 ro,dirsync,seclabel,nodev,noatime 0 0
/dev/block/dm-13 /apex/com.android.resolv ext4 ro,dirsync,seclabel,nodev,noatime 0 0
tmpfs /apex/apex-info-list.xml tmpfs rw,seclabel,nosuid,nodev,noexec,relatime,size=5708332k,nr_inodes=1427083,mode=755 0 0
/dev/block/bootdevice/by-name/LTALabel /mnt/lta-label ext4 rw,seclabel,nosuid,nodev,noexec,noatime,nobarrier 0 0
adb /dev/usb-ffs/adb functionfs rw,relatime 0 0
diag /dev/ffs-diag functionfs rw,relatime 0 0
diag_mdm /dev/ffs-diag-1 functionfs rw,relatime 0 0
diag_mdm2 /dev/ffs-diag-2 functionfs rw,relatime 0 0
mtp /dev/usb-ffs/mtp functionfs rw,relatime 0 0
ptp /dev/usb-ffs/ptp functionfs rw,relatime 0 0

Unfortunately I'll need assistance providing more information as the custom support for the Xperia 1 iii is very slim - there are no custom recoveries and the device uses the boot.img as the recovery AFAIK.

Assumed to be similar issue to https://github.com/topjohnwu/Magisk/issues/8446 Same tree of support: canary 27006 - boots canary 27007 - boots canary 27008 - doesn't boot beta 28000 - doesn't boot canary 28001 - doesn't boot

Device is using latest released stock ROM (must be fetched via xperifrm - Sony only supplies the ROM image in parts) - 61.2.A.0.472A

Stock boot.img and patched image are too large to upload directly to github (31MB compressed each) - which file upload site is preferred?

aviraxp commented 2 weeks ago

Actually not seem so same with that issue. You can upload to gdrive.

RobertoMM1986 commented 2 weeks ago

Im installed also v28 and with this version im unable to duplicate Magisk with Island, instead with v27 i was able. Any tip?

jasonlaguidice commented 2 weeks ago

Actually not seem so same with that issue. You can upload to gdrive.

No problem! Here is a patched boot.img with 28001 https://drive.google.com/file/d/18ABtSPH8tO-S03RqpbZS0V4wOZp-yszD/view?usp=sharing

And here is the stock boot image extracted from the Sony firmware dump: https://drive.google.com/file/d/1TIBKhQ32D_GRttl_ImlJZ6wafKBEFmJY/view?usp=sharing

I can patch that boot image to the versions stated above and when flashing (fastboot flash boot_a [file]) the device will boot okay. The device doesn't support the fastboot boot command either.

vvb2060 commented 2 weeks ago

try https://github.com/topjohnwu/Magisk/actions/runs/11354178097

jasonlaguidice commented 2 weeks ago

No such luck. Steps performed:

  1. Reverted to stock boot.img / uninstalled magisk.apk
  2. Installed test app-debug.apk
  3. Patched stock boot image
  4. Rebooted to bootloader and flashed patched image

And device boot loops.

aviraxp commented 2 weeks ago

It surprises me the commit doesn't work becuase that's the only commit in 27007-27008 that can cause boot issues. Can you try bisect between the first and last commit of 27007?

You can start here in middle and use ci builds: https://github.com/topjohnwu/Magisk/commit/b828e2d0b207f446cc112bd107a213e70f2d3e57

jasonlaguidice commented 2 weeks ago

FYI just reporting back I'll be giving this a try but it'll take me a little bit to go through - I appreciate the help and wanted to let you know I'm not vanishing on it. Expected to be able to spend a couple of hours this evening and will report back once I find a commit that causes the boot failure.

vvb2060 commented 1 day ago

https://github.com/topjohnwu/Magisk/releases/download/canary-27007/app-debug.apk flash and upload kmsg