You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2019/03/22 21:32:43 UTC

[GitHub] [mynewt-core] wes3 commented on a change in pull request #1707: spiflash performance improvements

wes3 commented on a change in pull request #1707: spiflash performance improvements
URL: https://github.com/apache/mynewt-core/pull/1707#discussion_r268342128
 
 

 ##########
 File path: hw/drivers/flash/spiflash/src/spiflash.c
 ##########
 @@ -985,18 +1013,23 @@ hal_spiflash_write(const struct hal_flash *hal_flash_dev, uint32_t addr,
     struct spiflash_dev *dev = (struct spiflash_dev *)hal_flash_dev;
     uint32_t page_limit;
     uint32_t to_write;
+    uint32_t pp_time_typical;
+    uint32_t pp_time_maximum;
     int rc = 0;
 
     u8buf = (uint8_t *)buf;
 
     spiflash_lock(dev);
 
-    while (len) {
-        if (spiflash_wait_ready(dev, 100) != 0) {
-            rc = -1;
-            goto err;
-        }
+    if (spiflash_wait_ready(dev, 100) != 0) {
+        rc = -1;
 
 Review comment:
   Should this 100 magic number be either a definition or mynewt val?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services