Re:Reverse-engineering and analysis of SanDisk High Enduranc...
by remram on Sunday February 02, 2025 @06:21PM
(#42912941)
How come there is so much "permanent" config for SD cards?
Re:Reverse-engineering and analysis of SanDisk High Enduranc...
by userbinator on Sunday February 02, 2025 @10:46PM
(#42914720)
The spec was developed with DRM as one of its use cases.
Re:Reverse-engineering and analysis of SanDisk High Enduranc...
by msarnoff on Monday February 03, 2025 @11:05AM
(#42919573)
Probably the same reason microcontrollers have OTP fuses—to prevent accidental corruption in the field or from buggy programming.
Re:Reverse-engineering and analysis of SanDisk High Enduranc...
by hypercube33 on Monday February 03, 2025 @11:15AM
(#42919718)
I believe it's because it originally was SD/MMC which was supposed to be a future media for audio and the like for retail sale. I had some read only palm pilot cards like this - books etc were also sold this way for a short period.
The single biggest thing you can do to improve the reliability of your embedded system is to use eMMC’s built-in hardware partitioning.
- Each hardware partition is a separate block device. A firmware update cannot corrupt the device by overwriting a partition table.
- There are two small boot partitions, and they can be made permanently read-only after programming, thus preventing corruption of your bootloader. You can also use the other one read-write for your uboot environment.
- You can easily have two OS partitions for A/B firmware updates. In addition to mounting them readonly, temporary write protection can be enabled on a per-partition basis and disabled when needed for fw updates.
- If you can’t afford the capacity hit from pSLC, I believe it can be enabled on a per-partition basis. (Don’t quote me on this, it could be wrong).
All these settings can be configured with either mmc-utils or u-boot. In volumes, programming houses can take care of this for you. (You’ll have to list all the registers out very specifically in an Excel spreadsheet)
The downside is that calculating all the correct register values is not a simple process, and you’ll have to spend a bit of time reading the eMMC spec.