blob: 03dbb4b6cd832441a4c4fcdb5da91d088c04a174 [file] [log] [blame]
Klaus Heinrich Kiwi4d21da12020-03-06 11:31:13 -06001From ab2bc5d0efcfb5f1a1122d9c85b9ea9e53908454 Mon Sep 17 00:00:00 2001
2From: Reza Arbab <arbab@linux.ibm.com>
3Date: Fri, 21 Feb 2020 14:45:23 -0600
4Subject: [PATCH] hdata/spira: Add p10 NMMU base address
5
6Signed-off-by: Reza Arbab <arbab@linux.ibm.com>
7---
8 hdata/spira.c | 13 ++++++++++---
9 1 file changed, 10 insertions(+), 3 deletions(-)
10
11diff --git a/hdata/spira.c b/hdata/spira.c
12index db54a02..de6386a 100644
13--- a/hdata/spira.c
14+++ b/hdata/spira.c
15@@ -919,15 +919,22 @@ static void add_nx(void)
16 static void add_nmmu(void)
17 {
18 struct dt_node *xscom, *nmmu;
19+ u32 scom;
20
21- /* Nest MMU only exists on POWER9 */
22+ /* Nest MMU only exists on POWER9 or later */
23 if (proc_gen < proc_gen_p9)
24 return;
25
26+ if (proc_gen == proc_gen_p9)
27+ scom = 0x5012c40;
28+ else
29+ scom = 0x2010c40;
30+
31 dt_for_each_compatible(dt_root, xscom, "ibm,xscom") {
32- nmmu = dt_new_addr(xscom, "nmmu", 0x5012c40);
33+ nmmu = dt_new_addr(xscom, "nmmu", scom);
34+ /* XXX P10 */
35 dt_add_property_strings(nmmu, "compatible", "ibm,power9-nest-mmu");
36- dt_add_property_cells(nmmu, "reg", 0x5012c40, 0x20);
37+ dt_add_property_cells(nmmu, "reg", scom, 0x20);
38 }
39 }
40
41--
421.8.3.1
43