Copilot commented on code in PR #17866:
URL: https://github.com/apache/nuttx/pull/17866#discussion_r2686456561


##########
drivers/mtd/Kconfig:
##########
@@ -1503,4 +1503,18 @@ config MTD_CFI
        ---help---
                Support CFI(common flash interface) NOR FLASH.
 
+config MTD_CFI_PAGE_SIZE
+       int "page size of MTD CFI NOR FLASH (bytes)"
+       default 16

Review Comment:
   The configuration option lacks input validation. Consider adding a range 
constraint to ensure the page size is at least 1 byte and doesn't exceed a 
reasonable maximum. For example: `range 1 65536` to prevent invalid 
configurations that could cause runtime errors.
   ```suggestion
        default 16
        range 1 65536
   ```



##########
drivers/mtd/Kconfig:
##########
@@ -1503,4 +1503,18 @@ config MTD_CFI
        ---help---
                Support CFI(common flash interface) NOR FLASH.
 
+config MTD_CFI_PAGE_SIZE
+       int "page size of MTD CFI NOR FLASH (bytes)"
+       default 16
+       depends on MTD_CFI
+       ---help---
+               Configure write page size of CFI Flash.
+               According to the CFI protocol, the flash supports write
+               operation size from one byte up to a maximum number of bytes
+               defined in flash hardware acccording the CFI document JEP137B.

Review Comment:
   Typo in the word 'acccording' - it has three 'c's instead of two. It should 
be 'according'.
   ```suggestion
                defined in flash hardware according the CFI document JEP137B.
   ```



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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to