summaryrefslogtreecommitdiffstats
path: root/src/usr/targeting/attrrp.C
diff options
context:
space:
mode:
authorCamVan Nguyen <ctnguyen@us.ibm.com>2012-11-27 16:06:08 -0600
committerA. Patrick Williams III <iawillia@us.ibm.com>2012-12-04 15:40:09 -0600
commit10085bf3f511a7b76e51814c1850d4b138a5b9d1 (patch)
tree7efbac16808870a359663bbd07a2cbe810f9a846 /src/usr/targeting/attrrp.C
parent07e1c50a631d79121228354e94e2158336c843c5 (diff)
downloadtalos-hostboot-10085bf3f511a7b76e51814c1850d4b138a5b9d1.tar.gz
talos-hostboot-10085bf3f511a7b76e51814c1850d4b138a5b9d1.zip
Create new PNOR heap zero initialized section for Hostboot only attributes.
New section is needed for Hostboot specific attributes that we don't want to sync to/from FSP. This is needed for MPIPL. Change-Id: Ic40bec73c9b1331906a81b5804999865c0ec1616 RTC: 51687 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/2445 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/targeting/attrrp.C')
-rw-r--r--src/usr/targeting/attrrp.C24
1 files changed, 17 insertions, 7 deletions
diff --git a/src/usr/targeting/attrrp.C b/src/usr/targeting/attrrp.C
index db6535106..7c7b6ecf0 100644
--- a/src/usr/targeting/attrrp.C
+++ b/src/usr/targeting/attrrp.C
@@ -196,8 +196,10 @@ namespace TARGETING
case MSG_MM_RP_READ:
// HEAP_ZERO_INIT should never be requested for read
// because kernel should automatically get a zero page.
- if (iv_sections[section].type ==
- SECTION_TYPE_HEAP_ZERO_INIT)
+ if ( (iv_sections[section].type ==
+ SECTION_TYPE_HEAP_ZERO_INIT) ||
+ (iv_sections[section].type ==
+ SECTION_TYPE_HB_HEAP_ZERO_INIT) )
{
TRACFCOMP(g_trac_targeting,
ERR_MRK "AttrRP: Read request on "
@@ -395,6 +397,7 @@ namespace TARGETING
break;
case SECTION_TYPE_HEAP_ZERO_INIT:
+ case SECTION_TYPE_HB_HEAP_ZERO_INIT:
l_perm = WRITABLE | ALLOCATE_FROM_ZERO;
break;
@@ -420,12 +423,19 @@ namespace TARGETING
break;
}
- int rc = mm_alloc_block((iv_sections[i].type ==
- SECTION_TYPE_HEAP_ZERO_INIT ?
- NULL : iv_msgQ),
- reinterpret_cast<void*>(
- iv_sections[i].vmmAddress),
+ int rc = 0;
+ msg_q_t l_msgQ = iv_msgQ;
+
+ if ( (iv_sections[i].type == SECTION_TYPE_HEAP_ZERO_INIT) ||
+ (iv_sections[i].type == SECTION_TYPE_HB_HEAP_ZERO_INIT) )
+ {
+ l_msgQ = NULL;
+ }
+
+ rc = mm_alloc_block(l_msgQ,
+ reinterpret_cast<void*>(iv_sections[i].vmmAddress),
iv_sections[i].size);
+
if (rc)
{
/*@
OpenPOWER on IntegriCloud