#945508 fastboot: hangs indefinitely when trying to flash a recovery

Package:
fastboot
Source:
android-platform-tools
Description:
Android fastboot tool
Submitter:
Celejar
Date:
2020-11-24 07:54:03 UTC
Severity:
important
#945508#5
Date:
2019-11-26 02:57:41 UTC
From:
To:
I'm trying to flash a TWRP recovery to a Xiaomi Mix 2s phone:

~$ fastboot devices
xxxxxxxx	fastboot
~$ fastboot flash recovery twrp-3.3.1-1-polaris.img

The command hangs - it does not return, display any message to the
terminal, or log anything, until 120 seconds have passed, at which point
the following appears in syslog:

Nov 25 13:06:22 lila kernel: [  363.660869] INFO: task fastboot:2753 blocked for more than 120 seconds.
Nov 25 13:06:22 lila kernel: [  363.660877]       Tainted: G           OE     5.3.0-2-amd64 #1 Debian 5.3.9-3
Nov 25 13:06:22 lila kernel: [  363.660880] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
Nov 25 13:06:22 lila kernel: [  363.660884] fastboot        D    0  2753   2497 0x00000000
Nov 25 13:06:22 lila kernel: [  363.660889] Call Trace:
Nov 25 13:06:22 lila kernel: [  363.660902]  ? __schedule+0x2b9/0x6c0
Nov 25 13:06:22 lila kernel: [  363.660908]  schedule+0x39/0xa0
Nov 25 13:06:22 lila kernel: [  363.660914]  schedule_timeout+0x20f/0x300
Nov 25 13:06:22 lila kernel: [  363.660941]  ? usb_hcd_submit_urb+0xc0/0xbf0 [usbcore]
Nov 25 13:06:22 lila kernel: [  363.660948]  wait_for_completion_timeout+0x126/0x170
Nov 25 13:06:22 lila kernel: [  363.660954]  ? wake_up_q+0x60/0x60
Nov 25 13:06:22 lila kernel: [  363.660974]  usb_start_wait_urb+0x83/0x160 [usbcore]
Nov 25 13:06:22 lila kernel: [  363.660998]  proc_bulk+0x175/0x310 [usbcore]
Nov 25 13:06:22 lila kernel: [  363.661018]  usbdev_do_ioctl+0x311/0xf50 [usbcore]
Nov 25 13:06:22 lila kernel: [  363.661038]  usbdev_ioctl+0xa/0x10 [usbcore]
Nov 25 13:06:22 lila kernel: [  363.661045]  do_vfs_ioctl+0x40e/0x670
Nov 25 13:06:22 lila kernel: [  363.661052]  ksys_ioctl+0x5e/0x90
Nov 25 13:06:22 lila kernel: [  363.661057]  __x64_sys_ioctl+0x16/0x20
Nov 25 13:06:22 lila kernel: [  363.661063]  do_syscall_64+0x53/0x140
Nov 25 13:06:22 lila kernel: [  363.661067]  entry_SYSCALL_64_after_hwframe+0x44/0xa9
Nov 25 13:06:22 lila kernel: [  363.661072] RIP: 0033:0x7ff70cb255b7
Nov 25 13:06:22 lila kernel: [  363.661082] Code: Bad RIP value.
Nov 25 13:06:22 lila kernel: [  363.661085] RSP: 002b:00007fffb4e068a8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
Nov 25 13:06:22 lila kernel: [  363.661089] RAX: ffffffffffffffda RBX: 00007fffb4e068c0 RCX: 00007ff70cb255b7
Nov 25 13:06:22 lila kernel: [  363.661091] RDX: 00007fffb4e068d0 RSI: 00000000c0185502 RDI: 0000000000000004
Nov 25 13:06:22 lila kernel: [  363.661093] RBP: 0000000000000006 R08: 0000557ae441bca0 R09: 00007fffb4e06b50
Nov 25 13:06:22 lila kernel: [  363.661095] R10: 0000000000000000 R11: 0000000000000246 R12: 00007fffb4e068d0
Nov 25 13:06:22 lila kernel: [  363.661097] R13: 0000557ae441bc80 R14: 0000000000000040 R15: 0000000000000040

The same thing appears every 120 seconds. When the USB cable is
disconnected, fastboot prints this rather incoherent message to the
terminal and then terminates:

target didn't report max-download-size
sending 'recovery' (59720 KB)...
FAILED (command write failed (Success))
finished. total time: 0.000s

#945508#10
Date:
2020-11-24 07:51:16 UTC
From:
To:
Have you tried upstream binaries?  It might be that this version of
fastboot is too old for your device.