From 20429929ddd9528ae164c800b01193124dcbdef9 Mon Sep 17 00:00:00 2001 From: apio Date: Sat, 22 Oct 2022 17:23:22 +0200 Subject: [PATCH] InitRD: Bump up the filesystem limits --- kernel/src/init/InitRD.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kernel/src/init/InitRD.cpp b/kernel/src/init/InitRD.cpp index 3582df0b..02add581 100644 --- a/kernel/src/init/InitRD.cpp +++ b/kernel/src/init/InitRD.cpp @@ -116,8 +116,8 @@ void InitRD::for_each(void (*callback)(File& f)) } } -#define INITRD_MAX_FILES_IN_DIR 8 -#define INITRD_MAX_FILES 32 +#define INITRD_MAX_FILES_IN_DIR 16 +#define INITRD_MAX_FILES 64 namespace InitRD { @@ -154,13 +154,13 @@ void initrd_for_each_dir(void (*callback)(InitRD::Directory& f)) } } -static InitRD::File files[32]; +static InitRD::File files[INITRD_MAX_FILES]; static uint32_t total_files = 0; -static InitRD::Directory dirs[32]; +static InitRD::Directory dirs[INITRD_MAX_FILES]; static uint32_t total_dirs = 0; -static VFS::Node nodes[63]; // One of the dirs is the initrd_root +static VFS::Node nodes[INITRD_MAX_FILES + (INITRD_MAX_FILES - 1)]; // One of the dirs is the initrd_root static uint32_t total_nodes = 0; ssize_t initrd_read(VFS::Node* node, size_t offset, size_t length, char* buffer)