sub-sys: disk: ram: Make RAM disk size be configurable
Hardcoded 96KB starts to overload RAM regions and fail CI tests. Quick test shows that 80KB ramdisk is ok, (passes tests/posix/fs). And of course, targets with wealth of RAM may want to use bigger ramdisks. Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
This commit is contained in:
parent
62c75107a3
commit
4fd593068e
2 changed files with 9 additions and 3 deletions
|
@ -47,6 +47,12 @@ endif # DISK_ACCESS
|
|||
|
||||
if DISK_ACCESS_RAM
|
||||
|
||||
config DISK_RAM_VOLUME_SIZE
|
||||
int "RAM Disk size in kilobytes"
|
||||
default 96
|
||||
help
|
||||
Size of the RAM Disk.
|
||||
|
||||
config DISK_RAM_VOLUME_NAME
|
||||
string "RAM Disk mount point or drive name"
|
||||
default "RAM"
|
||||
|
|
|
@ -20,10 +20,10 @@
|
|||
*/
|
||||
#include "fat12_ramdisk.h"
|
||||
#else
|
||||
/* A 96KB RAM Disk, which meets ELM FAT fs's minimum block requirement. Fit for
|
||||
* qemu testing (as it may exceed target's RAM limits).
|
||||
/* RAM Disk of configurable size. Fit for qemu testing (as it may exceed
|
||||
* target's RAM limits).
|
||||
*/
|
||||
#define RAMDISK_VOLUME_SIZE (192 * RAMDISK_SECTOR_SIZE)
|
||||
#define RAMDISK_VOLUME_SIZE (CONFIG_DISK_RAM_VOLUME_SIZE * 1024)
|
||||
static u8_t ramdisk_buf[RAMDISK_VOLUME_SIZE];
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue