X-Git-Url: https://git.ao2.it/ddsect.git/blobdiff_plain/85ff655a5eea0655a97bda948426d61e8a977c4d..refs/heads/master:/README diff --git a/README b/README index 0c292b2..dc5a0d6 100644 --- a/README +++ b/README @@ -6,9 +6,18 @@ or to split a raw flash dump into its MTD partitions. The format for describing each memory section in a map file is: - HexStartingAddres-HexEndingAddress : "name" + HexStartingAddress-HexEndingAddress : "name" -just like the output of the MTD driver in linux. +where HexEndingAddress is actually the address of the byte _after_ the last +one of the section (HexStartingAddress + size); this is because of how the +output of the MTD driver in linux is formed (see drivers/mtd/mtdpart.c). + + printk(KERN_NOTICE "0x%012llx-0x%012llx : \"%s\"\n", (unsigned long long)slave->offset, + (unsigned long long)(slave->offset + slave->mtd.size), slave->mtd.name); + +This is slightly different from the format used in other memory layout files +(like for instance the one used by flashrom, which specifies the actual end +address), but it allows to just reuse the output of the linux mtd driver. Empty lines and lines starting with the '#' character will be ignored in the map file.