mirror of
https://github.com/apache/nuttx.git
synced 2026-06-05 07:12:54 +08:00
mtd: fix some unallocated and NULL pointer issues. rwb->wrflush and rwb->wrmaxblocks in rwbuffer could get unallocated values from ftl_initialize() in some configurations. Also fixes related assert:
up_assert: Assertion failed at file:rwbuffer.c line: 643 that can happen with the following configuration: CONFIG_FTL_WRITEBUFFER=y CONFIG_DRVR_WRITEBUFFER=y # CONFIG_FS_WRITABLE is not set These problems are caused by CONFIG variable differences between the buffer layers. TODO: This is not a perfect solution. readahead support has similar issues.
This commit is contained in:
committed by
Gregory Nutt
parent
58a0b09b82
commit
0f7210b0ae
+1
-1
@@ -29,7 +29,7 @@ config MTD_PARTITION
|
||||
config FTL_WRITEBUFFER
|
||||
bool "Enable write buffering in the FTL layer"
|
||||
default n
|
||||
depends on DRVR_WRITEBUFFER
|
||||
depends on DRVR_WRITEBUFFER && FS_WRITABLE
|
||||
|
||||
config FTL_READAHEAD
|
||||
bool "Enable read-ahead buffering in the FTL layer"
|
||||
|
||||
Reference in New Issue
Block a user