mkiiskila commented on a change in pull request #281: imgmgr: add erase
command, remove erase from upload command
URL:
https://github.com/apache/incubator-mynewt-core/pull/281#discussion_r119240061
##########
File path: sys/flash_map/src/flash_map.c
##########
@@ -131,6 +132,40 @@ flash_area_align(const struct flash_area *fa)
return hal_flash_align(fa->fa_device_id);
}
+int
+flash_area_is_empty(const struct flash_area *fa, bool *empty)
+{
+ uint32_t data[64 >> 2];
+ uint32_t data_off = 0;
+ int8_t bytes_to_read;
+ uint8_t i;
+ int rc;
+
+ while(data_off < fa->fa_size)
+ {
Review comment:
Can you fix the coding style?
See
https://github.com/apache/incubator-mynewt-core/blob/master/CODING_STANDARDS.md
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services