From 1bf8c6b8376efacd03e3ec62d5ded5b2be4bff39 Mon Sep 17 00:00:00 2001 From: Missy Connell Date: Mon, 10 Sep 2012 16:05:01 -0500 Subject: Extend VMM to 32M Add mmLinearMap to create block at a specified phys addr. Added iv_MaptoPhy in the block to indicate we are physically mapped block and to not apply the HRMOR. Change-Id: I75ddb19b82ae9a2035ff873edff8a34a33c74639 RTC:43401 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1846 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell Reviewed-by: A. Patrick Williams III --- src/include/kernel/pagemgr.H | 56 +++++++++++++++++++++++++------------------- 1 file changed, 32 insertions(+), 24 deletions(-) (limited to 'src/include/kernel/pagemgr.H') diff --git a/src/include/kernel/pagemgr.H b/src/include/kernel/pagemgr.H index 93cd82bb5..ad94d0522 100644 --- a/src/include/kernel/pagemgr.H +++ b/src/include/kernel/pagemgr.H @@ -1,26 +1,25 @@ -/* IBM_PROLOG_BEGIN_TAG - * This is an automatically generated prolog. - * - * $Source: src/include/kernel/pagemgr.H $ - * - * IBM CONFIDENTIAL - * - * COPYRIGHT International Business Machines Corp. 2010-2012 - * - * 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_TAG - */ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: src/include/kernel/pagemgr.H $ */ +/* */ +/* IBM CONFIDENTIAL */ +/* */ +/* COPYRIGHT International Business Machines Corp. 2010,2012 */ +/* */ +/* 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 */ #ifndef __KERNEL_PAGEMGR_H #define __KERNEL_PAGEMGR_H @@ -167,6 +166,14 @@ class PageManager */ static uint64_t availPages(); + /** + * Add memory to the page manager + * @param[in] i_addr, The start address of the memory to add + * @param[in] i_pageCount, The number of pages to add + * @note i_addr must be on a page boundary + */ + static void addMemory(size_t i_addr, size_t i_pageCount); + enum { MEMLEN = VmmManager::MBOX_DMA_ADDR, @@ -186,9 +193,10 @@ class PageManager private: - void* _allocatePage(size_t,bool); //!< see allocatePage() + void* _allocatePage(size_t,bool); //!< see allocatePage() void _freePage(void*, size_t); //!< see freePage() void _coalesce( void ); //!< see coalesce() + void _addMemory(size_t, size_t); //!< see addMemory() /** see queryAvail() */ ALWAYS_INLINE uint64_t _queryAvail() const -- cgit v1.2.1