HTC One M8 bricked after flashing wrong boot.img

Oct 30, 2018
17
0
0
Recently I bricked my phone after flashing wrong boot.img. I can't get into bootloader and once the device turns on, I can't do anything except of waiting until the battery runs out of power. Is there any way to recover this phone?
 

redpoint73

Recognized Contributor
Oct 24, 2007
15,259
6,946
113
First of all, it is not bricked. As long as the screen comes on (even if just stuck on the HTC logo screen) the device is likely recoverable. A true brick is a device that can only be recovered by opening up the phone (replace motherboard, JTAG, etc.). You are simply stuck in a condition, where it won't boot to the Android OS.

Bootloader is a protected partition, and therefore can't be over-written by something like flashing a boot.img, as long as your are s-on (default condition).
Bootloader therefore is most likely still working, you just aren't accessing it properly. You probably just aren't doing the proper button combo, to get the bootloader. Try this:

1) No need to wait for battery to drain. To reboot the phone simply hold power + vol up button, until the screen goes dark to reboot. May take up to a minute, before this happens, in a "stuck" condition.
2) The moment the screen goes dark to reboot, but before the HTC logo screen comes back on, let go of the power button, and simply slide your finger from vol up, to vol down. Keep vol down pressed, until you see the bootloader screen.
3) If you don't get the bootloader, you probably just got the timing wrong. You either started pressing vol down too late, or let go of vol down too early. Simply repeat Steps 1 and 2 above, until you get the timing correct.

From bootloader, you should be able to flash the correct boot.img
Although your comment that you flashed the "wrong boot.img" raises some questions:
a) How do you know it is the wrong boot.img? Where did you get it from?
b) Why did you flash this boot.img? What were you trying to accomplish? Is it a custom kernel, or trying to solve some other problem?

If you need help finding the right boot.img, in addition to answer the above questions a-b, you should also do fastboot getvar all, and post the results (delete IMEI and serial number before posting).
 
Oct 30, 2018
17
0
0
First of all, it is not bricked. As long as the screen comes on (even if just stuck on the HTC logo screen) the device is likely recoverable. A true brick is a device that can only be recovered by opening up the phone (replace motherboard, JTAG, etc.). You are simply stuck in a condition, where it won't boot to the Android OS.

Bootloader is a protected partition, and therefore can't be over-written by something like flashing a boot.img, as long as your are s-on (default condition).
Bootloader therefore is most likely still working, you just aren't accessing it properly. You probably just aren't doing the proper button combo, to get the bootloader. Try this:

1) No need to wait for battery to drain. To reboot the phone simply hold power + vol up button, until the screen goes dark to reboot. May take up to a minute, before this happens, in a "stuck" condition.
2) The moment the screen goes dark to reboot, but before the HTC logo screen comes back on, let go of the power button, and simply slide your finger from vol up, to vol down. Keep vol down pressed, until you see the bootloader screen.
3) If you don't get the bootloader, you probably just got the timing wrong. You either started pressing vol down too late, or let go of vol down too early. Simply repeat Steps 1 and 2 above, until you get the timing correct.

From bootloader, you should be able to flash the correct boot.img
Although your comment that you flashed the "wrong boot.img" raises some questions:
a) How do you know it is the wrong boot.img? Where did you get it from?
b) Why did you flash this boot.img? What were you trying to accomplish? Is it a custom kernel, or trying to solve some other problem?

If you need help finding the right boot.img, in addition to answer the above questions a-b, you should also do fastboot getvar all, and post the results (delete IMEI and serial number before posting).
a) This is where i got it from: https:// androidfilehost.com/?fid=385035244224400814. The boot.img file was most likely not matching the system installed (LineageOS 16). It's stock boot.img for my device (propably).
b) I was trying to fix the problem, where I couldn't install Magisk, because when installing, it said that I have custom boot.img and cannot proceed. I could've ask first how to solve this instead of doing this, so I'm just an idiot.
 
Oct 30, 2018
17
0
0
a) This is where i got it from: https:// androidfilehost.com/?fid=385035244224400814. The boot.img file was most likely not matching the system installed (LineageOS 16). It's stock boot.img for my device (propably).
b) I was trying to fix the problem, where I couldn't install Magisk, because when installing, it said that I have custom boot.img and cannot proceed. I could've ask first how to solve this instead of doing this, so I'm just an idiot.
It worked! Thanks for help!
 

redpoint73

Recognized Contributor
Oct 24, 2007
15,259
6,946
113
a) This is where i got it from: https:// androidfilehost.com/?fid=385035244224400814. The boot.img file was most likely not matching the system installed (LineageOS 16). It's stock boot.img for my device (propably).
b) I was trying to fix the problem, where I couldn't install Magisk, because when installing, it said that I have custom boot.img and cannot proceed. I could've ask first how to solve this instead of doing this, so I'm just an idiot.
a) I can't tell from the link alone, what that boot.img even is, and it seems that you don't either. Even if stock boot.img, what version number (there are many - and that matters). My advice (maybe already a lesson learned) is not to flash things, if you aren't 100% sure what they are.

b) I'm not a Lineage user, so I'm not familiar whether that is a known error or not. AFAIK, Lineage should be compatible with Magisk, so as you already figured, the error may be a result of custom kernel, another previously installed root method (SuperSU?) or some other mod. In which case, there are better ways to get back to a "clean" and correct boot.img, rather than flashing files which you are unsure of. Easiest way, is to simply dirty flash the Lineage ROM again. Either just the boot.img (which is included with the ROM.zip) of the whole ROM. Whole ROM is probably the best, as it will give you a clean ROM baseline, in case there is anything else modified (besides boot.img) that is interfering with Magisk. Dirty flash means flashing the file while keeping user data, only wipe cache and Dalvik.

---------- Post added at 09:12 AM ---------- Previous post was at 09:10 AM ----------

It worked! Thanks for help!
What worked exactly? Getting into bootloader by the method I described, I pretty much figured would work. Did you also get the right boot.img flashed, and get it rooted with Magisk?
 
  • Like
Reactions: DarkKnightComes
Oct 30, 2018
17
0
0
What worked exactly? Getting into bootloader by the method I described, I pretty much figured would work. Did you also get the right boot.img flashed, and get it rooted with Magisk?
I forgot about the Power+VolDown combination. I launched Recovery from bootloader and I just installed ROM on top of the previous one. The ROM that I have has Magisk integrated.
 
Last edited: