programminghoch10/huawei-honor-bootloader-bruteforce

Failed to connect after a autoreboot - P20 on Linux

Conzar opened this issue · 1 comments

I am trying to unlock the P20 on Ubuntu 18.04. The P20 has the 5 try timeout issue so the program correctly identifies this and reboots after 4 tries. The problem is that the device is not detected after the reboot.

Here is the output from the program

Bruteforce is running...
Currently testing code 1000090461352081
Progress: 10.0%
...
FAILED (remote: device will reboot after 30S due to 5 times of wrong key.)
finished. total time: 4.519s

Target device has bruteforce protection!
Waiting for reboot and trying again...
Device reboot requested, turning on reboot workaround.
Rebooting to prevent bootloader from rebooting...
< waiting for any device >
rebooting into bootloader...
FAILED (status read failed (No such device))
finished. total time: 15.962s
Bruteforce is running...
Currently testing code 1000120615136108
Progress: 10.0%
< waiting for any device >
...
FAILED (status read failed (No such device))
finished. total time: 20.456s

dmesg after adb reboot fastboot but before autoreboot

[199011.404062] usb 1-14: USB disconnect, device number 95
[199011.465357] xhci_hcd 0000:02:00.0: WARN Set TR Deq Ptr cmd failed due to incorrect slot or ep state.
[199019.736919] usb 1-14: new high-speed USB device number 96 using xhci_hcd
[199019.928641] usb 1-14: New USB device found, idVendor=18d1, idProduct=d00d, bcdDevice= 1.00
[199019.928644] usb 1-14: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[199019.928647] usb 1-14: Product: HI3650
[199019.928648] usb 1-14: Manufacturer: Fastboot2.0
[199019.928650] usb 1-14: SerialNumber

dmesg after autoreboot

199973.743863] usb 1-14: USB disconnect, device number 17
[199973.744121] xhci_hcd 0000:02:00.0: WARN Set TR Deq Ptr cmd failed due to incorrect slot or ep state.
[199974.129856] usb 1-14: new high-speed USB device number 18 using xhci_hcd
[199979.269864] usb 1-14: device descriptor read/64, error -110
[199994.881771] usb 1-14: device descriptor read/64, error -110
[199995.117713] usb 1-14: new high-speed USB device number 19 using xhci_hcd
[199995.257737] usb 1-14: device descriptor read/64, error -71
[199995.505727] usb 1-14: device descriptor read/64, error -71
[199995.617743] usb usb1-port14: attempt power cycle
[199996.277693] usb 1-14: new high-speed USB device number 20 using xhci_hcd

Any ideas why the device doesn't connect properly to Linux after the autoreboot?

Sadly I do not have any clue on why that is happening.
To diagnose to issue: have you chosen "always trust this computer" in the adb dialogue when connecting to the computer?
To solve the issue: You can probably just flip the variable in the code beforehand to force auto reboot behaviour.