You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/06/07 15:05:30 UTC

[GitHub] [incubator-nuttx] gustavonihei commented on a change in pull request #3834: RFQ: progmem.h: Modify interface to avoid terms like page, sector, and block, as these terms are used interchangeably by different silicon vendors.

gustavonihei commented on a change in pull request #3834:
URL: https://github.com/apache/incubator-nuttx/pull/3834#discussion_r646675017



##########
File path: include/nuttx/progmem.h
##########
@@ -49,96 +49,127 @@ extern "C"
  * Public Functions Definitions
  ****************************************************************************/
 
+/* NOTE: Since vendors use the terms page, block, and sector interchangably,
+ * it causes confusion and therefore a neutral term is used. We use the term
+ * "index" to refer to the ordinal number of erasable units of memory.
+ */
+
 /****************************************************************************
- * Name: up_progmem_neraseblocks
+ * Name: up_progmem_maxeraseindex
  *
  * Description:
- *   Return number of erase blocks
+ *   Return the total number of erasable units of memory.
+ *
+ * Returned Value:
+ *   Returns number of erasable units of memory, or 0 if there are no units
+ *   available that can be programmed.
  *
  ****************************************************************************/
 
-size_t up_progmem_neraseblocks(void);
+size_t up_progmem_maxeraseindex(void);
 
 /****************************************************************************
  * Name: up_progmem_isuniform
  *
  * Description:
- *  Is program memory uniform or erase page and read/write page size differs?
+ *  Are all erasable units of memory the same size?

Review comment:
       ```suggestion
    *   Are all erasable units of memory the same size?
   ```
   nit: Uniformize alignment of description text.




-- 
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