aboutsummaryrefslogtreecommitdiff
path: root/hdata
diff options
context:
space:
mode:
authorHaren Myneni <haren@linux.ibm.com>2021-08-04 12:50:54 +0530
committerVasant Hegde <hegdevasant@linux.vnet.ibm.com>2021-08-06 12:21:19 +0530
commit55d2c4837a60354257c47d703a5722c1d7b3055a (patch)
tree7946e1ff87ec6e00ee7dacd1bd2a3c7e1346d0a3 /hdata
parent2ce3f083f3999483e202ea6868d55fcb0ad61db1 (diff)
downloadskiboot-55d2c4837a60354257c47d703a5722c1d7b3055a.zip
skiboot-55d2c4837a60354257c47d703a5722c1d7b3055a.tar.gz
skiboot-55d2c4837a60354257c47d703a5722c1d7b3055a.tar.bz2
hdat/spira: Add ibm, power10-vas-x string to VAS compatible property
VAS SCOM base address and paste address format are changed on P10. This patch adds ibm,power10-vas-x string to compatible property per each VAS node. This compatible string is used to define the paste base address later during VAS initialization. Also enables NX on P10 without adding any compatible string since the NX SCOM base address is not changed. Signed-off-by: Haren Myneni <haren@linux.ibm.com> Signed-off-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com>
Diffstat (limited to 'hdata')
-rw-r--r--hdata/spira.c25
1 files changed, 16 insertions, 9 deletions
diff --git a/hdata/spira.c b/hdata/spira.c
index 2fd3da1..b7101d7 100644
--- a/hdata/spira.c
+++ b/hdata/spira.c
@@ -12,6 +12,7 @@
#include <fsp-attn.h>
#include <fsp-leds.h>
#include <skiboot.h>
+#include <vas.h>
#include "hdata.h"
#include "hostservices.h"
@@ -475,17 +476,23 @@ static void add_xive_node(struct dt_node *np)
dt_add_property(xive, "force-assign-bars", NULL, 0);
}
-/*
- * SCOM Base Address from P9 SCOM Assignment spreadsheet
- */
-#define VAS_SCOM_BASE_ADDR 0x03011800
-
static void add_vas_node(struct dt_node *np, int idx)
{
- struct dt_node *vas = dt_new_addr(np, "vas", VAS_SCOM_BASE_ADDR);
+ struct dt_node *vas;
+ const char *comp;
+ uint64_t base_addr;
- dt_add_property_cells(vas, "reg", VAS_SCOM_BASE_ADDR, 0x300);
- dt_add_property_string(vas, "compatible", "ibm,power9-vas-x");
+ if (proc_gen == proc_gen_p9) {
+ base_addr = P9_VAS_SCOM_BASE_ADDR;
+ comp = "ibm,power9-vas-x";
+ } else {
+ base_addr = VAS_SCOM_BASE_ADDR;
+ comp = "ibm,power10-vas-x";
+ }
+
+ vas = dt_new_addr(np, "vas", base_addr);
+ dt_add_property_cells(vas, "reg", base_addr, 0x300);
+ dt_add_property_string(vas, "compatible", comp);
dt_add_property_cells(vas, "ibm,vas-id", idx);
}
@@ -906,10 +913,10 @@ static void add_nx_node(u32 gcid)
"ibm,power8-nx");
break;
case proc_gen_p9:
+ case proc_gen_p10:
/* POWER9 NX is not software compatible with P8 NX */
dt_add_property_strings(nx, "compatible", "ibm,power9-nx");
break;
- case proc_gen_p10: /* XXX P10 */
default:
return;
}