michallenc commented on code in PR #19018:
URL: https://github.com/apache/nuttx/pull/19018#discussion_r3413848002
##########
drivers/mtd/Kconfig:
##########
@@ -50,6 +50,15 @@ config FTL_READAHEAD
default n
depends on DRVR_READAHEAD
+config FTL_BBM
+ bool "Enable bad block management in the FTL layer"
+ default y if MTD_NAND
Review Comment:
No, I agree most of the drivers don't need it. But after this merge request
you have to enable `CONFIG_FTL_BBM` if you use `mtd_partition` to create
multiple partitions on your flash device. And that's not a theoretical bug,
it's fairly common use case. If you don't enable `CONFIG_FTL_BBM`, you program
runs into the debug assertion, even if your driver doesn't need bad block
management. This should be solved by the diff above and we won't have to enable
`CONFIG_FTL_BBM` for most of the NOR flash devices (perhaps for all of
them...). I can create a merge request for the change if you want.
--
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]