[Lenovo Z6 Pro Guides, News, & Discussion] Chema_F:
RESTORE QCN

​

Introduction​

If you have ever tried to restore a QCN, you may faced that the QCN is not actually restored, this because of a damaged/erased 'persist' partition. I will describe two different methods to restore the persist partition: fastboot commands (only for unlocked bootloader) and QFIL method (locked and unlocked bootloader). So this post will be structured as follows:

- Introduction

- Erase and install 'persist' and 'modem' partition using fastboot (unlocked bootloader)

- Erase and install 'persist' and 'modem' partition using QFIL (locked/unlocked bootloader)

- Restore QCN

Erase and install 'persist' partition using fastboot

​

0. Pre-requisites

- ADB&Fastboot installed (you can download it here)

1. Put 'persist' and 'modem' partitions .img files in ADB folder

You should install the partitions from the ZUI firmware currently installed in your device. If you are using stock ZUI, just check the device info in Settings to find the ZUI version you are using, download the ZUI ROM (you can find them HERE), extract persist.img and 'NON-HLOS.bin' .img files and put them into your ADB folder in your computer. Rename 'NON-HLOS.bin' to 'NON-HLOS.img'

If you are using custom ROM and you can't remember which is the last ZUI firmware that you installed, I suggest using 'persist' and 'modem' from 11.5.229 or going for the QFIL method.

2. Reboot in Fastboot Mode and connnect to PC

Shut down your device and boot it holding pressed Volume Down + Power buttons until you see the Fastboot Mode menu. You can navigate the menu with volume buttons and confirm with Power buttons. At this point just reboot in Fastboot Mode and connect the device with computer via USB wire.

3. Open a CMD window in your ADB folder

Open your ADB folder and Shift+Right Click over an empty space of the folder. Choose 'Open CMD here' (or similar, I can't rememeber the words in English). If you don't have this option, open CMD using the search bar in your desktop or the Windows button and navigate with commands to your ADB folder.

4.Erase and install partitions

In CMD window write:

fastboot devices
[I](this should return a number which represents your device)[/I]
fastboot erase persist
fastboot flash persist persist.img
fastboot erase modem
fastboot flash modem NON-HLOS.img

5. Reboot your device

Erase and install 'persist' partition using QFIL

​

0. Pre-requisites

- QPST installed

- Lenovo drivers installed

- Qualcomm drivers installed

1. ONLY IF YOU ARE USING ANDROID 9 AND YOUR BOOTLOADER IS UNLOCKED:

You must be aware that installing Android 10 with QFIL will lock your bootloader. So you will avoid problems this way:

- Backup your data

- Remove fingerprint, pattern or any lockscreen security

- Lock the bootloader (from fastboot: fastboot flashing lock)

2. Backup

Backup everything you want to keep if you haven't done yet because this procedure will do a clean install and absolutely everything will be erased.

3. Set the FireHose Configuration

- Open QFIL, press 'Confifuration' tab and select 'FireHose Configuration'.

- Set everything as shown in the screenshots.

Note: if your QFIL doesn't show the option to "Erase All Before Download", install an older QPST version like this one.

4. Select 'programmer' and 'content'

In the QFIL main screen:

- Select "Meta Build"

- Press "Load Content" and browse to select the 'contents.xml' from the ROM folder.

- Press "Browse" to select the 'prog_firehose_ddr.elf' file from the ROM folder. Actually this file should have been self added when setting the 'contents.xml'.

5. Connect in EDL mode and Download

Shut down your device and:

- Hold pressed Volume Up and Volume Down buttons

- Connect the phone to computer with USB wire

- Release volume buttons as soon as your phone vibrates and Lenovo logo flashes on the screen.

- Press the "Download Content" button in QFIL main screen

IMPORTANT: all these steps must be done quickly, if you delay releasing volume buttons or pressing the "Download Content" button there will be errors during the installation.

If your device is not shown as "QDLoader 9008" in QFIL when connecting in EDL mode and you get "Select Port" instead, press "Select port" button top in the right, select your device and press OK. Your device should be shown now. Then unplug your phone and repeat the steps to reboot in EDL mode, connect and Download Content.

Once the installation is finished the device will reboot. Unplug the phone from computer when this happens.

6. Select "Flat Build"

In QFIL main screen select "Flat Build" and make sure that programmer file is loaded.

7. Reboot in EDL, connect and select "Partition Manager"

Select "Partition Manager" under the "Tools" tab.

8. Erase and install 'persist' partition

- Do right clik on "persist" label and select "Manage Partition Data".

- Press "Erase" button.

- Press "Load Image...", browse to select the 'persist.img' file from the ROM folder and confirm to load it.

- Press "Close".

9. Erase and install 'modem' partition

Repeat previous steps as done with persist partition. The file to load from the ROM folder for modem partition is "NON-HLOS.bin"

10. Reboot the phone.

Close the Partition Manager, unplug the phone from computer and force your phone to reboot holding pressed the Power button.

Restore QCN

​

1. Boot the phone

2. Enable Diagnostics mode as described in post #1

3. Open QFIL and connect the phone with computer

Your phone should appear in QFIL as connected in Diagnostics Mode, check post #1 if not.

4. Press the "Tools" tab and a menu will open, select "QCN Backup Restore"

5. "Browse" to select the .qcn file that you want to install and press "Restore QCN"

6. Reboot the phone

The phone won't reboot once the restore is completed so pay attention to the QFIL log to know when it's done and reboot it manually.

Your IMEI should be already restored.