Notes about firmware update procedure.
Posted: Sat Feb 02, 2019 2:41 pm
Overall, there are two methods to update the drive firmware:
In self-update mode the flasher application sends the file to the drive. The drive firmware then analyzes the file for correctness, performs various checks and then updates itself. This is the method used by “official” firmware update tools.
In raw flash write mode the drive firmware plays no part at all – flashing application writes firmware image directly to drive flash memory.
The self-update mode, by design, is inherently safe. Very little can go wrong when updating drive in this mode – the drive checks firmware image for correctness and hardware compatibility, and would refuse self-update process in case of any discrepancy. The areas of flash memory containing configuration data are not touched during the update at all. Even if update process is interrupted, drive would go into recovery mode where update process can be safely restarted. It is nearly impossible to brick or damage the drive when using this mode.
On a contrast, there are lot of things that can go wrong in raw flash write mode. Entire flash memory is overwritten in this mode, including boot code and areas with configuration data. In raw flash write mode drive would accept anything, including absolute garbage data, rendering the drive unbootable. Since drive performs no firmware image verification whatsoever, one should be very careful when preparing such image (by “stiching” boot code, firmware and configuration data together). In short, it is very easy to brick the drive in raw flash mode. NB: To date we had not yet seen a 100% correct firmware image "stiching" instructions. All publicly available "firmware cleaning tools" do produce a raw firmware image with (slightly) damaged configuration data.
As mentioned earlier, all “official” firmware update tools use the safe self-update mode. In this mode the drive would refuse firmware images deemed incompatible – for example, firmware downgrade is often disabled. This is the reason people use dosflash and similar tools, that operate using raw flash write mode.
The usual advice is not to use and tool that uses raw flash write mode, unless you really know what you are doing and understand all risks involved.
p.s. List of popular firmware written tools and mode used:
Self-update mode:
- Drive self-update mode.
- Raw flash write mode.
In self-update mode the flasher application sends the file to the drive. The drive firmware then analyzes the file for correctness, performs various checks and then updates itself. This is the method used by “official” firmware update tools.
In raw flash write mode the drive firmware plays no part at all – flashing application writes firmware image directly to drive flash memory.
The self-update mode, by design, is inherently safe. Very little can go wrong when updating drive in this mode – the drive checks firmware image for correctness and hardware compatibility, and would refuse self-update process in case of any discrepancy. The areas of flash memory containing configuration data are not touched during the update at all. Even if update process is interrupted, drive would go into recovery mode where update process can be safely restarted. It is nearly impossible to brick or damage the drive when using this mode.
On a contrast, there are lot of things that can go wrong in raw flash write mode. Entire flash memory is overwritten in this mode, including boot code and areas with configuration data. In raw flash write mode drive would accept anything, including absolute garbage data, rendering the drive unbootable. Since drive performs no firmware image verification whatsoever, one should be very careful when preparing such image (by “stiching” boot code, firmware and configuration data together). In short, it is very easy to brick the drive in raw flash mode. NB: To date we had not yet seen a 100% correct firmware image "stiching" instructions. All publicly available "firmware cleaning tools" do produce a raw firmware image with (slightly) damaged configuration data.
As mentioned earlier, all “official” firmware update tools use the safe self-update mode. In this mode the drive would refuse firmware images deemed incompatible – for example, firmware downgrade is often disabled. This is the reason people use dosflash and similar tools, that operate using raw flash write mode.
The usual advice is not to use and tool that uses raw flash write mode, unless you really know what you are doing and understand all risks involved.
p.s. List of popular firmware written tools and mode used:
Self-update mode:
- All official vendor firmware update packages
- Unlocked LG flasher
- dosflash
- $109 user-friendly dosflash clone