[G2 and Desire Z General] srv1973:
Hi all,

[I originally posted a question about this in the General Discussions forum, before I realized that there were dedicated forums for each phone model. So please forgive me for effectively double-posting]

Totally new to Android, only got my Desire Z last Friday. I'd like to root my phone and play around with custom ROMS, but I'm worried if I ever need to return the phone for warranty purposes, and for when I buy another phone and want to sell this one.

So my objective is to make sure I have a failsafe way to revert back to my current stock HTC ROM before I start messing around with rooting/custom roms.

As I understand it, the generic steps for rooting/s-off/custom rom are:

- Gain temproot

- Gain permroot + S-OFF

- Install custom bootloader and recovery image (ROM Manager/Clockworkmod)

- Install custom ROM

So if I want to revert back to the stock HTC ROM, I image I need to do the following:

- Restore HTC ROM

- Restore original recovery image and bootloader

- Remove permroot and set S-ON back

- Remove all traces of the method to gain root/S-OFF

Is that generally correct?

I'm currently thinking about using the following procedure, but there's a few gaps in there still. I'd appreciate it if people could verify my procedure and fill in the gaps...

Permroot+S-OFF the phone

Step 1. Back up phone data

Planning to use HandyBackup for that, just need contacts, SMS and call log...

Step 2. Flash older HTC firmware

There's no permroot/S-OFF hack for firmwares >=1.72 at the moment, so we have to first downgrade to 1.33.405.5 using the method described on http://xdaforums.com/showthread.php?t=905261 (steps 1-12)

After I do this, make sure I never ever upgrade this phone to >=1.72 again!

Question: this guide tells me to make a goldcard first. As I understand it that's only required if you have a branded phone. My Desire Z is not branded as far as I know, so is it correct to say that I do not need a goldcard?

Step 3. permroot+S-OFF

Follow steps 13-19 from the link above.

Better get the original CID here as well? How?

Step 4. Create a backup of the existing bootloader and recovery image

Question: how can I do this?

dd if=/.... of=/....

dd if=/.... of=/....

Step 5.Install ROM Manager

Step 6. Install recovery image from inside ROM Manager

Step 7. Create a backup of the phone using ROM Manager

This will be a backup of the stock HTC rom, which is rooted+S-OFF. I will need this later in case I ever want to revert the phone back to factory defaults

Now how to revert back to factory defaults:

Step 8. Restore stock HTC ROM using ROM Manager

Restore using the backup I created in step 7 above.

Step 9. Restore original bootloader and recovery image

Question: how can i do this?

dd if=/... of=/....

dd if=/... of=/...

Step 9. S-ON and remove root

Question: "gfree -r -f"? This link here: http://xdaforums.com/wiki/index.php?title=HTC_Vision#Returning_to_Stock talks about using "gfree -r" to restore "partition 7", but I've not seen anywhere where this backup of partition 7 is actually created...

Step 10. Clean up after myself

remove psneuter, gfree, uninstall ROM Manager, Visionary, SuperUser

So, summarizing my questions:

- Do I need to make a goldcard/debrand my phone first?

- How can you make a backup of the existing bootloader/recovery image?

- How can I restore the original bootloader/recovery image?

Kind regards...