Samsung-Loki/Thor

Odin communications/flash doesn't work with Galaxy S7 / SM-G930F

jmbreuer opened this issue · 4 comments

Description

Practically all Odin mode commands fail against my phone. This example is with flashTar; dumpPit fails in the same way.

Reproduction

  1. connect
  2. begin odin
  3. flashTar /path/to/firmware/directory
  4. result: Failed to bulk read: Connection timed out (110) (before even getting to select which partitions to flash)

Full logs of the tool, in debug mode

Welcome to Thor Shell v1.0.4!
Successfully loaded "usb.ids" from cache.
Type "help" for list of commands.
To start off, type "connect" to initiate a connection.
~~~~~~~~ Platform specific notes ~~~~~~~~
You have to run Thor as root or edit udev rules as follows:
1) create and open /etc/udev/rules.d/51-android.rules in an editor
2) enter SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", MODE="0666", GROUP="YourUserGroupHere"
Additionally, you may have to disable the cdc_acm kernel module:
1) To temporarily unload, run "sudo modprobe -r cdc_acm"
2) To disable it, run "echo 'blacklist cdc_acm' | sudo tee -a /etc/modprobe.d/cdc_acm-blacklist.conf"
shell> debug on
Enabled debug logging
shell> connect
[10:48:14 DBG] Number of configurations: 1
[10:48:14 DBG] Number of interfaces: 2
[10:48:14 DBG] ~~~~ Interface index 0 ~~~~
[10:48:14 DBG] Number of endpoints: 1
[10:48:14 DBG] Interface class: 0x02
[10:48:14 DBG] $$ Endpoint index 0 $$
[10:48:14 DBG] !! Class-dependant descriptor, skipping (len = 5 - 2)
[10:48:14 DBG] !! Class-dependant descriptor, skipping (len = 5 - 2)
[10:48:14 DBG] !! Class-dependant descriptor, skipping (len = 4 - 2)
[10:48:14 DBG] !! Class-dependant descriptor, skipping (len = 5 - 2)
[10:48:14 DBG] Endpoint address: 0x83
[10:48:14 DBG] !! USB_ENDPOINT_XFER_BULK fail (value = 03)
[10:48:14 DBG] !! Interface is invalid, continuing
[10:48:14 DBG] ~~~~ Interface index 1 ~~~~
[10:48:14 DBG] Number of endpoints: 2
[10:48:14 DBG] Interface class: 0x0A
[10:48:14 DBG] $$ Endpoint index 0 $$
[10:48:14 DBG] Endpoint address: 0x81
[10:48:14 DBG] $$ Endpoint index 1 $$
[10:48:14 DBG] Endpoint address: 0x02
[10:48:14 DBG] > Interface is valid, exiting
[10:48:14 DBG] Interface: 0x01, Alternate: 0x00, Read Endpoint: 0x81, Write Endpoint: 0x02
Successfully connected to the device!
Now run "begin" with the protocol you need.
shell> begin odin
[10:48:18 DBG] Bootloader version integer 0x00030000
[10:48:18 DBG] Unknown1: 0, Unknown2: 0, Version: 3
[10:48:18 DBG] Sending file part size of 1048576
Successfully began an Odin session!
shell> flashTar /tmp/s7stock
[10:48:36 DBG] Full exception: System.ApplicationException: Failed to bulk read: Connection timed out (110)
   at TheAirBlow.Thor.Library.Platform.Linux.Interop.HandleError(String message) in /home/theairblow/RiderProjects/Thor/TheAirBlow.Thor.Library/Platform/Linux.cs:line 366
   at TheAirBlow.Thor.Library.Platform.Linux.BulkRead(Int32 amount, Int32& read, Int32 timeout) in /home/theairblow/RiderProjects/Thor/TheAirBlow.Thor.Library/Platform/Linux.cs:line 228
   at TheAirBlow.Thor.Library.Protocols.Odin.DumpPIT() in /home/theairblow/RiderProjects/Thor/TheAirBlow.Thor.Library/Protocols/Odin.cs:line 205
   at ThorRewrite.Shell.Commands.ProtoOdin.FlashTar.RunCommand(State state, List`1 args) in /home/theairblow/RiderProjects/Thor/TheAirBlow.Thor.Shell/Commands/ProtoOdin/FlashTar.cs:line 22
~~~~~~~^
Failed to bulk read: Connection timed out (110)

Hardware and software

  • OS of the computer used: Gentoo Linux amd64 17.1/desktop/plasma/systemd
  • Model of the device: SM-G930F

Additional context

At the connect step, the SM-G930F is mis-identified as a GT-I9100 Phone [Galaxy S II] (Download mode) (ID 001:110)

I'm running Thor as root, and added the blacklist cdc_acm module configuration. I verified that cdc_acm is no longer being loaded (it was at first).

Facing the same issue with my Samsung S21 FE (SM-G990E). I thought to extract the odin package and flash each file manuall with flashFile, but it doesn't properly work as well.

shell> flashFile /home/ice/Android/SlimSang/dpm.img             
Is "DPM" the right partition? [y/n] (n): y
Are you absolutely sure you want to flash "DPM"? [y/n] (n): y
~~~~~~~^
Could not find file '/home/ice/Android/SlimSang/dpm.img'.

Facing the same issue with my Samsung S21 FE (SM-G990E). I thought to extract the odin package and flash each file manuall with flashFile, but it doesn't properly work as well.

shell> flashFile /home/ice/Android/SlimSang/dpm.img             
Is "DPM" the right partition? [y/n] (n): y
Are you absolutely sure you want to flash "DPM"? [y/n] (n): y
~~~~~~~^
Could not find file '/home/ice/Android/SlimSang/dpm.img'.

that's not related at all, you've obviously made a mistake in the path.

that's not related at all, you've obviously made a mistake in the path.

No, it isn't. I copy pasted the path multiple times back when I was using this.