[Hardware Hacking General] E:V:A:
What does it all mean?

Here I give a general description to the various partitions. Most of them have

been determined, but some still remain somewhat mysterious. But there are

Terabytes written about various partition schemes and file systems etc, but

some good sources for our purpose are found on Wikipedia and Microsoft.

But the most important thing to understand, is that most of the technical

ingredients (as show in the previous post) is hardware dependent. Thus the

Android partition schemes depend on the processor / modem combination and

their firmware, and thus also the kernel, to some extent.

Some key info can be found here:

http://en.wikipedia.org/wiki/GUID_Partition_Table

http://en.wikipedia.org/wiki/Master_boot_record

http://en.wikipedia.org/wiki/Extended_Boot_Record

http://en.wikipedia.org/wiki/Host_Protected_Area

Trouble shooting Disks and Filesystems (Microsoft)

Using GPT Drives (Microsoft)
​

General Android Partition Description (Qualcomm MSM8960)

The function and content of many of the partitions are not very well

described, nor easily found in one place. Here are some further details,

that apply primarily to Qualcomm Snapdragon S4/+ based Android devices.

However, Windows Phones using these these SoC's should have a very similar

partition structures, but with different names.

For details about: RPM (PBL), SBL1, SBL2, SBL3, TZ and ABOOT (APPSBL), please

see this and this thread, where they are extensively discussed and described.

GPT: See section on PIT and GPT "partitions" below.

BACKUP: This partition should contain a copy of MODEMST2. Whether it does or

not, is described in the PARAM partition.

BOOT: This is the partition that enables the phone to boot, as the name

suggests. It includes the kernel and the ramdisk. Without this partition, the

device will simply not be able to boot. Wiping this partition from recovery

should only be done if absolutely required and once done, the device must NOT

be rebooted before installing a new one, which can be done by installing a ROM

that includes a /boot partition.

CACHE: Contain the firmware update package which is downloaded from server,

and the recovery log file. Other uses include storage for frequently accessed

data and application components. Wiping the cache doesn’t effect your personal

data but simply gets rid of the existing data there, which gets automatically

rebuilt as you continue using the device.

DATA / USERDATA: This partition contains the user's data – this is where your

contacts, messages, settings and apps that you have installed go. Wiping this

partition essentially performs a factory reset on your device, restoring it to

the way it was when you first booted it, or the way it was after the last

official or custom ROM installation. When you perform a wipe data/factory

reset from recovery, it is this partition that you are wiping.

EFS: The Android EFS partition stores all your phones important, but

accessible, hardware data, such as WiFi/BlueTooth MAC's, IMEI (or ESN for a

CDMA based device) and some others.

FOTA: Is the Firmware Over The Air partition. After the update package has

been downloaded from the server it is saved into the CACHE partition. After

that the userspace application that does the download writes a special cookie

into the FOTA partition. This cookie tells the bootloaders to take the

necessary steps to boot into recovery mode

FSG: Probably stands for File System (FS) "Golden". According to Samsung

documentation, this partition is a "Golden Copy". This is partially confirmed

by RE of the PARAM partition, which indicate that this partition should contain

a copy of MODEMST1. As such it is a backup of the current EFS2 filesystem.

The creation of a FSG is not supported on flash devices and the internal (QMI)

DIAG request "EFS2_DIAG_MAKE_GOLDEN_COPY", can only be used to

create a backup one time over the life of the device. [80-V1294-11]

GROW: << unknown >>

MISC: This partition contains miscellaneous system settings in form of on/off

switches. These settings may include CID (Carrier or Region ID), USB

configuration and certain hardware settings etc. This is an important

partition and if it is corrupt or missing, several of the device’s features

will will not function normally. Not all devices have this partition.

PARAM: This is the Parameter partition which contains a number of parameters,

variables and settings of the hardware. Apparently it has an 88 byte header

structure that tell us if the MODEMST1 and MODEMST2 have been backed up to the

FSG and BACKUP partitions, respectively. Furthermore it contain all the debug

settings (DLOW/DMID/DHIG etc), the "triangle" status of whether or not you have

flashed custom ROMs and the flash count (0x3FFE00). Current boot mode in use,

and much more. The info about this partition could easily occupy a book by

itself.

PERSIST: << unknown >> The use of this partition is unknown and apparently

only exists on Qualcomm based devices.

PIT: See below.

RECOVERY: Holds the recovery boot image. When updating the system we boot

into recovery mode by using the boot image stored in this partition. It lets

you boot the device into a recovery console for performing advanced recovery

and maintenance operations on it.

SSD: "Secure Software Download" is a memory based file system (RAMFS) for

secure storage, used to download and store "who knows what" on the eMMC. It is

a referenced part in the Remote Storage RPC Client of the MSM kernel.

SYSTEM: This partition basically contains the entire operating system, other

than the kernel and the ramdisk. This includes the Android user interface as

well as all the system applications that come pre-installed on the device.

Wiping this partition will remove Android from the device without rendering it

unbootable, and you will still be able to put the phone into recovery or

bootloader mode to install a new ROM.
​

Older Types of Qualcomm Partitions

DBL Device Boot Loader (loads OSBL)
OSBL Operating System Boot Loader (loads AMSS)
AMSS Advanced Mobile Subscriber Software (Qualcomm CP FW)
EMMCBOOT Embedded MMC (eMMC) boot (loads EMMCBOOT)
ADSP AP (Application Processor) DSP (Qualcomm DSP FW)

Qualcomm Partition Type Cross Reference

When inspecting the partitioning of the eMMC's used by Qualcomm Snapdragon based

hardware, we see that they tend to use different partition types, for their

different partitions depending on their function. For example, for the MSM8960

SoC/PoP, we often find the following partition ID's, when inspected by

mounting the device with on linux PC. This seem to remain fairly consistent across

all their Snapdragon class/based devices.

[SIZE=2]ID Type Label oldLabels Filename(s) Description
-----------------------------------------------------------------------
05 EXT -- -- -- Extended partition
0C FAT32X MODEM FAT non-hlos.bin
45 SBL3 sbl3.mbn
46 TZ OEMSBL tz.mbn, osbl.mbn
47 RPM rpm.mbn
48 BOOT boot.img
4A MODEM_ST1 --
4B MODEM_ST2 --
4C ABOOT emmc_appsboot.mbn
4D Boot SBL1 CFG_DATA sbl1.mbn, dbl.mbn
51 SBL2 sbl2.mbn
58 FSG --
5D ??HTC
60 RECOVERY recovery.img
64 ?BOOT1 --
65 "misc" misc.img
83 EXT4 [1] // // Native Linux
-----------------------------------------------------------------------
[1] This is a standard linux partition of any EXT2/3/4 type, thus there
are many different labels used here.
[/SIZE]

Some additional partition IDs found from their CodeAurora sources in

[kernel/msm][arch/arm/mach-msm/rmt_storage_client.c]:

4A /boot/modem_fs1 RAMFS_MODEMSTORAGE_ID
4B /boot/modem_fs2 "
58 /boot/modem_fsg "
59 q6_fs1 RAMFS_MDM_STORAGE_ID
5A q6_fs2 "
5B q6_fsg "
5D ssd RAMFS_SSD_STORAGE_ID

Thus we can conclude that most of the standard (but outdated) MBR definitions

of partition type ID's are no longer valid, but used as an identifier for

various sub-system software.

From another document [80-VP120-1 Rev.K] the Secure Boot 3.0 based devices use MBR partition types as shown below:

However, this document is from 2010 and may not be up-to-date with what you have.

Check your kernel sources!

Additional eMMC types:

0x0b - FAT32
0x0c - FAT32L
0x0e - FAT16