diff options
-rw-r--r-- | src/build/linker/linker.C | 5 | ||||
-rw-r--r-- | src/include/sys/vfs.h | 7 | ||||
-rw-r--r-- | src/runtime/rt_vfs.C | 3 | ||||
-rw-r--r-- | src/sys/vfs/vfs_init.C | 48 |
4 files changed, 37 insertions, 26 deletions
diff --git a/src/build/linker/linker.C b/src/build/linker/linker.C index 2a4c3ad16..71b79c220 100644 --- a/src/build/linker/linker.C +++ b/src/build/linker/linker.C @@ -981,7 +981,10 @@ void ModuleTable::write_table(vector<Object> & i_objects) i->offset + i->data.vma_offset; cout << "Updating base module table..." << endl; - max_modules = VFS_MODULE_MAX; + fseek(iv_output, module_table_offset, SEEK_SET); + char mx_mod_ch = 0; + fread(&mx_mod_ch,sizeof(char),1,iv_output); + max_modules = (uint64_t)mx_mod_ch; // VFS_MODULE_MAX; ++i; } else diff --git a/src/include/sys/vfs.h b/src/include/sys/vfs.h index 566f331a8..05c8ecaf1 100644 --- a/src/include/sys/vfs.h +++ b/src/include/sys/vfs.h @@ -30,8 +30,13 @@ #include <sys/task.h> #endif -// make TODO VFS_MODULE_MAX equal to the actual number of modules in the base image (+ 2?) +#ifndef __HOSTBOOT_RUNTIME +// make VFS_MODULE_MAX equal to the actual number of modules in the base image (+ 2?) #define VFS_MODULE_MAX 16 +#else +#define VFS_MODULE_MAX 32 +#endif + // Extended use 4 4k pages // Extended Module Virtual address at 1GB #define VFS_EXTENDED_MODULE_VADDR (1 * 1024 * 1024 * 1024) diff --git a/src/runtime/rt_vfs.C b/src/runtime/rt_vfs.C index 894cd47cb..73f381313 100644 --- a/src/runtime/rt_vfs.C +++ b/src/runtime/rt_vfs.C @@ -27,7 +27,8 @@ #include <vector> #include <errno.h> -VfsSystemModule VFS_MODULES[VFS_MODULE_MAX]; +VfsSystemModule VFS_MODULES[VFS_MODULE_MAX] = +{{{VFS_MODULE_MAX,0},NULL,NULL,NULL,NULL,NULL,0}}; void vfs_module_init() { diff --git a/src/sys/vfs/vfs_init.C b/src/sys/vfs/vfs_init.C index e0cf844fa..c570e100f 100644 --- a/src/sys/vfs/vfs_init.C +++ b/src/sys/vfs/vfs_init.C @@ -1,25 +1,25 @@ -// IBM_PROLOG_BEGIN_TAG -// This is an automatically generated prolog. -// -// $Source: src/sys/vfs/vfs_init.C $ -// -// IBM CONFIDENTIAL -// -// COPYRIGHT International Business Machines Corp. 2011 -// -// p1 -// -// Object Code Only (OCO) source materials -// Licensed Internal Code Source Materials -// IBM HostBoot Licensed Internal Code -// -// The source code for this program is not published or other- -// wise divested of its trade secrets, irrespective of what has -// been deposited with the U.S. Copyright Office. -// -// Origin: 30 -// -// IBM_PROLOG_END +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: src/sys/vfs/vfs_init.C $ */ +/* */ +/* IBM CONFIDENTIAL */ +/* */ +/* COPYRIGHT International Business Machines Corp. 2011,2013 */ +/* */ +/* p1 */ +/* */ +/* Object Code Only (OCO) source materials */ +/* Licensed Internal Code Source Materials */ +/* IBM HostBoot Licensed Internal Code */ +/* */ +/* The source code for this program is not published or otherwise */ +/* divested of its trade secrets, irrespective of what has been */ +/* deposited with the U.S. Copyright Office. */ +/* */ +/* Origin: 30 */ +/* */ +/* IBM_PROLOG_END_TAG */ /** * @file vfs_init.C * @brief function definitions for funtions used to initialize modules @@ -30,7 +30,9 @@ #include <sys/mm.h> #include <util/align.H> -VfsSystemModule VFS_MODULES[VFS_MODULE_MAX]; +VfsSystemModule VFS_MODULES[VFS_MODULE_MAX] = +{{{VFS_MODULE_MAX,0},NULL,NULL,NULL,NULL,NULL,0}}; + uint64_t VFS_LAST_ADDRESS; |