summaryrefslogtreecommitdiffstats
path: root/hdata
diff options
context:
space:
mode:
Diffstat (limited to 'hdata')
-rw-r--r--hdata/memory.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/hdata/memory.c b/hdata/memory.c
index c9222605..7d5f3b37 100644
--- a/hdata/memory.c
+++ b/hdata/memory.c
@@ -567,6 +567,8 @@ static struct dt_node *dt_hb_reserves;
static struct dt_node *add_hb_reserve_node(const char *name, u64 start, u64 end)
{
+ /* label size + "ibm," + NULL */
+ char node_name[HB_RESERVE_MEM_LABEL_SIZE + 5] = { 0 };
struct dt_node *node, *hb;
if (!dt_hb_reserves) {
@@ -580,10 +582,15 @@ static struct dt_node *add_hb_reserve_node(const char *name, u64 start, u64 end)
dt_add_property_cells(dt_hb_reserves, "#address-cells", 2);
}
- node = dt_new_addr(dt_hb_reserves, name, start);
+ /* Add "ibm," to reserved node name */
+ if (strncasecmp(name, "ibm", 3))
+ snprintf(node_name, 5, "ibm,");
+ strcat(node_name, name);
+
+ node = dt_new_addr(dt_hb_reserves, node_name, start);
if (!node) {
prerror("Unable to create node for %s@%llx\n",
- name, (unsigned long long) start);
+ node_name, (unsigned long long) start);
return NULL;
}
OpenPOWER on IntegriCloud