I have the 128GB EMMC 5.1 flo device. I was running latest stock image. Now I wanted to upgrade to lineage 18.1. So I tried the CROSS script. It did something but I cannot install rom with the twrp that is for flox device. I think it might be issue with the 5.1 EMMC.
How could I compile flox twrp that would support emmc 5.1?
Do I also need to patch and recompile lineage?
I have the 128GB EMMC 5.1 flo device. I was running latest stock image. Now I wanted to upgrade to lineage 18.1. So I tried the CROSS script. It did something but I cannot install rom with the twrp that is for flox device. I think it might be issue with the 5.1 EMMC.
How could I compile flox twrp that would support emmc 5.1?
Do I also need to patch and recompile lineage?
Both TWRP and ROM kernels need the eMMC patch. They should support it by now, it is a very old issue. Ask the devs to re-compile the kernels. A really trivial change is required, a simple 1-byte mod.
Both TWRP and ROM kernels need the eMMC patch. They should support it by now, it is a very old issue. Ask the devs to re-compile the kernels. A really trivial change is required, a simple 1-byte mod.
Thanks!
I tried to compile kernel but failed on the first go.
Then I cleaned everything and tried to build again and success.
I will describe what I did:
1) Installed with RESTOCK stock image. Then flashed emmc 5.1 kernel that is available in this thread. Verified that everything is working. I used the modified twrp that is available here. (twrp-3.3.1-0-flo-k2.img)
2) Then I used CROSS as I needed bigger partitions for Lineage 18.1. When using cross I used lineage-install-3-flox.bat and I didn't want the CROSS to reflash my twrp that was working with eMMC 5.1.
3) I compiled kernel and swapped out the boot.img from lineage-18.1-20210712-nightly-flox-signed.zip. As I had twrp for flo I had to change the flashing script from flox->flo, so it could flash.
4) Flashed the modded lineage. And it booted.
So the 128GB Nexus 7 with eMMC 5.1 and bigger partitions is working.
In this thread I would like to consolidate information about eMMC flash memory failures and remedies.
When flash memory fails it becomes inaccessible or unwriteable with errors like the following:
Code:
sending 'bootloader' <3911 KB>...
OKAY [ 0.202s ]
writing 'bootloader'...
FAILED <remote: flash write failure>
or
E:can't mount /cache/recovery/last_install
E:can't open /cache/recovery/last_install
E:failed closing /dev/block/platform/msm_sdcc. 1/by-name/misc (I/O error)
E:failed to mount /cache (Invalid argument)
or
E:Unable to find partition size for '/boot'
E:Unable to find partition size for '/recovery'
E:Unable to find partition size for '/misc'
E:Primary block device '/dev/block/platform/msm_sdcc.1/by-name/userdata' for mount point '/data' is not present!
E:Unable to mount '/data'
E:Unable to recreate /data/media folder.
dmesg...
mmc0: error -110 whilst initialising MMC card
We observe these hardware failure symptoms:
device is totally dead
dead but flashes a few times the white LED next to USB port
dead but with active USB on PC device list
works up to fastboot stage or Google logo
may slowly boot Android sometimes
intermittently Android does not boot or work at all
#1 - eMMC unrelated
#2 - battery fault is most likely
#3 - catastrophic eMMC failure or GPT/bootloader damage, PC registers a new USB\VID_05C6&PID_9008 device, refer to QPST diagnostics below
#4 - partial eMMC failure or OS error, refer to fastboot diagnostics below
#5 - probably eMMC failure, unlocking and TWRP tests are required - post your logs
#6 - unlikely eMMC fault
Fastboot Diagnostics
If your bricked unit still works in fastboot mode then please do the following tests:
boot the Nexus in fastboot mode (when off press power+vol.dn)
connect it to your PC
on PC run:
fastboot oem gpt-info
fastboot format cache
You can run the fastboot app from Windows or Linux...
on Windows get RESTOCK and run it from the 'data' folder
If you get "partition[30].size 27852783 KB" then your eMMC chip is from Kingston (very high failure rate). If the format command freezes at any stage, then the eMMC chip is faulty and needs to be replaced.
The normal format output takes only 1 second and is:
Code:
Creating filesystem with parameters:
Size: 587202560
Block size: 4096
Blocks per group: 32768
Inodes per group: 7168
Inode size: 256
Journal blocks: 2240
Label:
Blocks: 143360
Block groups: 5
Reserved block group size: 39
Created filesystem with 11/35840 inodes and 4616/143360 blocks
erasing 'cache'...
OKAY [ 0.359s]
sending 'cache' (10984 KB)...
OKAY [ 0.359s]
writing 'cache'...
OKAY [ 0.484s]
finished. total time: 1.203s
To check the chip in working units use this app or dmesg:
Code:
Kingston (MMC32G)
-----------------
mmc0: new HS200 MMC card at address 0001
mmcblk0: mmc0:0001 MMC32G 28.8 GiB
Hynix (HBG4e)
-------------
mmc0: new HS200 MMC card at address 0001
mmcblk0: mmc0:0001 HBG4e 29.1 GiB
Toshiba (016G92)
----------------
mmcblk0: mmc0:0001 016G92 14.6 GiB
It is not so simple with bricked units but this device is exceptionally easy to disassemble. The chip is on the bottom of the motherboard but unlike the top, it is not covered with any shield (the purplechip).
Thanks!
I tried to compile kernel but failed on the first go.
Then I cleaned everything and tried to build again and success.
I will describe what I did:
1) Installed with RESTOCK stock image. Then flashed emmc 5.1 kernel that is available in this thread. Verified that everything is working. I used the modified twrp that is available here. (twrp-3.3.1-0-flo-k2.img)
2) Then I used CROSS as I needed bigger partitions for Lineage 18.1. When using cross I used lineage-install-3-flox.bat and I didn't want the CROSS to reflash my twrp that was working with eMMC 5.1.
3) I compiled kernel and swapped out the boot.img from lineage-18.1-20210712-nightly-flox-signed.zip. As I had twrp for flo I had to change the flashing script from flox->flo, so it could flash.
4) Flashed the modded lineage. And it booted.
So the 128GB Nexus 7 with eMMC 5.1 and bigger partitions is working.
@Kaar31. Wow. I'm impressed. Apparently you have a flo, but I have 3 debs. Would it be feasible for you to modify your step-by-step, above, so that I can upgrade my debs to 128GB, also? Much appreciated.
I just rebuilt the software for my N7 2013 deb. I was all finished the way I wanted inclukding followmis's excellent LOS 18.1 Rom, but it noticed that Magisk v.23 was apparently not installed, even though I was pretty certain that I had flashed it, also. So, I booted back into recovery (TWRP 3.4.0-0) and flashed Magisk, but the device continuously bootlooped on the Google flash screen. I hate to start all over from scratch. Can anyone help?
Thanks
I just rebuilt the software for my N7 2013 deb. I was all finished the way I wanted inclukding followmis's excellent LOS 18.1 Rom, but it noticed that Magisk v.23 was apparently not installed, even though I was pretty certain that I had flashed it, also. So, I booted back into recovery (TWRP 3.4.0-0) and flashed Magisk, but the device continuously bootlooped on the Google flash screen. I hate to start all over from scratch. Can anyone help?
Thanks
Flash the lineage 18.1 boot image from the ROM zip. Unzip the lineage zip file and you will find the boot.img file.
You can flash it using fastboot or install it using TWRP's option to installl image files.
I am trying to fix my Nexus 7, and after alot of effort I have established that I have a faulty eMMc IC. I have found a cheap replacement FBGA 153. However one step I am not sure of is that will I still need the JTAG Box or can I just solder the blank eMMc and update it using RESTOCK.
Sorry if I have missed something which makes my query seem daft! This was all new to me 2 days ago...
Hey, I have used flo-deb_clamor_repartition_20201203 and then installed official Android 11 LineageOS 18.1-flox without any problems from stock ROM. Device started lagging terribly, some apps take ages to open, a lot not responding messages, tablet literally unusable. eMMC is HYNIX HBG4e // 31GB MAY 2013, I have formated and wipe it 4-5 times without any errors. Also tried limiting background processes to 4 and used fstrim.bat from CROSS 2.5. No significant change.
The only idea comes to my mind is repartition to make system partition bigger, now it is 1.4GB with 290MB free. Any other solution?
Hey, I have used flo-deb_clamor_repartition_20201203 and then installed official Android 11 LineageOS 18.1-flox without any problems from stock ROM. Device started lagging terribly, some apps take ages to open, a lot not responding messages, tablet literally unusable. eMMC is HYNIX HBG4e // 31GB MAY 2013, I have formated and wipe it 4-5 times without any errors. Also tried limiting background processes to 4 and used fstrim.bat from CROSS 2.5. No significant change. The only idea comes to my mind is repartition to make system partition bigger, now it is 1.4GB with 290MB free. Any other solution?
If you see errors, copy and report them. Run getlog.bat and include "getlog.log" in your post. If possible, also run relog.bat and attach "relog-xxxxxx.zip" to your post.
Hi i have tried to use clamor repartition script, and in that process tablet got disconnected from pc, i restarted tablet, but it won't boot. I've tried to use restock but it can't write it gives error failed, i can boot to bootloader. Is there any software fix or i must change emmc?
Hi i have tried to use clamor repartition script, and in that process tablet got disconnected from pc, i restarted tablet, but it won't boot. I've tried to use restock but it can't write it gives error failed, i can boot to bootloader. Is there any software fix or i must change emmc?
In this thread I would like to consolidate information about eMMC flash memory failures and remedies.
When flash memory fails it becomes inaccessible or unwriteable with errors like the following:
Code:
sending 'bootloader' <3911 KB>...
OKAY [ 0.202s ]
writing 'bootloader'...
FAILED <remote: flash write failure>
or
E:can't mount /cache/recovery/last_install
E:can't open /cache/recovery/last_install
E:failed closing /dev/block/platform/msm_sdcc. 1/by-name/misc (I/O error)
E:failed to mount /cache (Invalid argument)
or
E:Unable to find partition size for '/boot'
E:Unable to find partition size for '/recovery'
E:Unable to find partition size for '/misc'
E:Primary block device '/dev/block/platform/msm_sdcc.1/by-name/userdata' for mount point '/data' is not present!
E:Unable to mount '/data'
E:Unable to recreate /data/media folder.
dmesg...
mmc0: error -110 whilst initialising MMC card
We observe these hardware failure symptoms:
device is totally dead
dead but flashes a few times the white LED next to USB port
dead but with active USB on PC device list
works up to fastboot stage or Google logo
may slowly boot Android sometimes
intermittently Android does not boot or work at all
#1 - eMMC unrelated
#2 - battery fault is most likely
#3 - catastrophic eMMC failure or GPT/bootloader damage, PC registers a new USB\VID_05C6&PID_9008 device, refer to QPST diagnostics below
#4 - partial eMMC failure or OS error, refer to fastboot diagnostics below
#5 - probably eMMC failure, unlocking and TWRP tests are required - post your logs
#6 - unlikely eMMC fault
Fastboot Diagnostics
If your bricked unit still works in fastboot mode then please do the following tests:
boot the Nexus in fastboot mode (when off press power+vol.dn)
connect it to your PC
on PC run:
fastboot oem gpt-info fastboot format cache
You can run the fastboot app from Windows or Linux...
on Windows get RESTOCK and run it from the 'data' folder
If you get "partition[30].size 27852783 KB" then your eMMC chip is from Kingston (very high failure rate). If the format command freezes at any stage, then the eMMC chip is faulty and needs to be replaced. The normal format output takes only 1 second and is:
Code:
Creating filesystem with parameters:
Size: 587202560
Block size: 4096
Blocks per group: 32768
Inodes per group: 7168
Inode size: 256
Journal blocks: 2240
Label:
Blocks: 143360
Block groups: 5
Reserved block group size: 39
Created filesystem with 11/35840 inodes and 4616/143360 blocks
erasing 'cache'...
OKAY [ 0.359s]
sending 'cache' (10984 KB)...
OKAY [ 0.359s]
writing 'cache'...
OKAY [ 0.484s]
finished. total time: 1.203s
in-circuit Service ROM flashing - after chip replacement or if eMMC is OK but with damaged partition table or bootloader
eMMC chip replacement
do not replace it with another Kingston
search for eMMC in FBGA 153 or 169 package
you can upgrade it to a higher capacity memory
new high-performance eMMC v5.1 requires updated software, available here
Nexus 7 2013 uses 3 brands of eMMC chips: Kingston, Hynix and Toshiba.
Kingston was initially identified as unreliable in this post a few years ago:
Google Nexus 7 2013 (Asus Razor)
This is bootloader repair package for Google Nexus 7 based on QUALCOMM APQ8064 MCU. Tegra based is not supported !
- GPT is for 32GB chip, hence it's not ticked by default. DO NOT tick it if You have 16GB version
- EFS/CEFS partitions You can tick in case that nothing else works, it's not recommended to try it if You haven't made backup first. In this model, partitions layout is different from all other known Qualcomm devices, hence reading first 512MB for backup wont do any help. Do do proper backup, You have to read 2GB + size (from 0x0000 0000 0000 to 0x0000 9000 0000)
Important ! ! !
- If You have device which hangs on Google logo, and resurrection process hangs at 1%, You'll have to replace the eMMC chip first. Kingston eMMC chips used in these devices oftenly fail and become unwriteable !
Attached Files Asus_Nexus_7.rar (103.60 MB)
To check the chip in working units use this app or dmesg:
Code:
Kingston (MMC32G)
-----------------
mmc0: new HS200 MMC card at address 0001
mmcblk0: mmc0:0001 MMC32G 28.8 GiB
Hynix (HBG4e)
-------------
mmc0: new HS200 MMC card at address 0001
mmcblk0: mmc0:0001 HBG4e 29.1 GiB
Toshiba (016G92)
----------------
mmcblk0: mmc0:0001 016G92 14.6 GiB
It is not so simple with bricked units but this device is exceptionally easy to disassemble. The chip is on the bottom of the motherboard but unlike the top, it is not covered with any shield (the purplechip).
OK, let me explain the situation. When we re-uploaded the service ROM to an easily accessible server (thanks davefiddes), Jelly Bean 4.2.2 system image file was removed to decrease the download size, but Jelly Bean is great at raw eMMC presets and initialization. MM and custom ROMs can not handle empty 'persist' partition and just stop booting. No problem and we're not going to waste time downgrading to an ancient OS before flashing a modern one. Please boot TWRP, copy both attached files to the root of internal storage, 'install' p4-restore-int.zip and then reboot - Android will work now.
You might consider changing wifi and bt addresses later from the ones I made up, if you wish.
BTW, I noticed from your log that it is a deb device. Unfortunately I can't help you restoring lost IMEI. You may be able to recover it from your broken Kingston. These partitions need to be copied.
/EDIT 2019
If you have used eMMC v5.1 chip, check this post for updated software.
Both TWRP and ROM kernels need the eMMC patch. They should support it by now, it is a very old issue. Ask the devs to re-compile the kernels. A really trivial change is required, a simple 1-byte mod.
Thanks!
I tried to compile kernel but failed on the first go.
Then I cleaned everything and tried to build again and success.
I will describe what I did:
1) Installed with RESTOCK stock image. Then flashed emmc 5.1 kernel that is available in this thread. Verified that everything is working. I used the modified twrp that is available here. (twrp-3.3.1-0-flo-k2.img)
2) Then I used CROSS as I needed bigger partitions for Lineage 18.1. When using cross I used lineage-install-3-flox.bat and I didn't want the CROSS to reflash my twrp that was working with eMMC 5.1.
3) I compiled kernel and swapped out the boot.img from lineage-18.1-20210712-nightly-flox-signed.zip. As I had twrp for flo I had to change the flashing script from flox->flo, so it could flash.
4) Flashed the modded lineage. And it booted.
So the 128GB Nexus 7 with eMMC 5.1 and bigger partitions is working.
...I'm really thankful with you for all your support and time dedicated to solve my situation! And for those who own a N7 with a dead Kingstone eMMC, I encourage you to follow my steps and learn A LOT on the way .
Here goes link to download factory image MOB30X and TWRP-3.3.1-0, both with updated kernel to support eMMC 5.1: mega.nz/#F!zM9BzS7D!LANr3czGEz7IqY_MJnzQRg
P.D.: just some thought... would be possible to apply a new mcc.c to native support eMMC 5.1 HS400 (something like importing mcc.c from Android Pie)?
Congratulations on the very first adaptation of eMMC v5.1 on Nexus 7 2013! :victory:
Let's briefly compare original, old eMMC v4.5 to eMMC v5.1:
faster R/W performance
2x Interface Bandwidth
SMART (Health) Report
F/W Update option
But most importantly, there is no need to search for old stock of original or equivalent chips, as new high-performance, cheap ICs can be used (in FBGA 153/169 package of course). Furthermore, higher capacity memory like 64GB, works fine. While the advanced new features of eMMC v5.1 require additional kernel modifications and dedicated apps, we already have standard solutions for N7 ROMs. Links to stock ROM and RAM-bootable TWRP are in edovis' post, I also compiled a flashable TWRP and generic kernel for custom ROMs. More misc support files.