diff options
author | Oliver O'Halloran <oohall@gmail.com> | 2017-06-15 16:00:22 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2017-06-16 14:38:46 +1000 |
commit | 92d7ccf00bdd6c994341feb013390c28993652bf (patch) | |
tree | f376330cdff46aca799a7b50c4747634623cf474 /hw/nx.c | |
parent | d939c1bbd13cb1f922be80769578eae99a30cad6 (diff) | |
download | skiboot-92d7ccf00bdd6c994341feb013390c28993652bf.zip skiboot-92d7ccf00bdd6c994341feb013390c28993652bf.tar.gz skiboot-92d7ccf00bdd6c994341feb013390c28993652bf.tar.bz2 |
hw/phys_map: Use GCIDs as a chip index
Currently we pass in a proc_chip structure to phys_map_get(). All we we
really need from this structure is the Global Chip ID (GCID). This
patch reworks the function so that we only need to pass the GCID which
allows us to use it before the proc_chip structures have been
initialised (i.e in the HDAT parser).
Cc: Michael Neuling <mikey@neuling.org>
Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Acked-By: Michael Neuling <mikey@neuling.org>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/nx.c')
-rw-r--r-- | hw/nx.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -50,7 +50,7 @@ void nx_p9_rng_init(void) */ for_each_chip(chip) { /* 1) NX RNG BAR */ - phys_map_get(chip, NX_RNG, 0, &bar, NULL); + phys_map_get(chip->id, NX_RNG, 0, &bar, NULL); xscom_write(chip->id, P9X_NX_MMIO_BAR, bar | P9X_NX_MMIO_BAR_EN); /* Read config register for pace info */ |