diff options
author | Stewart Smith <stewart@linux.vnet.ibm.com> | 2016-10-19 20:20:57 +1100 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2016-10-19 20:20:57 +1100 |
commit | 831971690ca92c93ccbf07c774202070f56834ad (patch) | |
tree | 15227414aadfd2f27a7848e23c6a9e2d2bd4d50a /core | |
parent | 9f25b34b7f2655c76300ee16c1c5d6840cad4985 (diff) | |
download | skiboot-831971690ca92c93ccbf07c774202070f56834ad.zip skiboot-831971690ca92c93ccbf07c774202070f56834ad.tar.gz skiboot-831971690ca92c93ccbf07c774202070f56834ad.tar.bz2 |
Revert "flash: Move flash node under ibm,opal/flash/"
This reverts commit e1e6d009860d0ef60f9daf7a0fbe15f869516bd0.
Breaks DT enough that it makes people cranky, reverting for now
Reported-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'core')
-rw-r--r-- | core/flash.c | 31 |
1 files changed, 7 insertions, 24 deletions
diff --git a/core/flash.c b/core/flash.c index 2f81aff..92de421 100644 --- a/core/flash.c +++ b/core/flash.c @@ -189,36 +189,19 @@ static int flash_nvram_probe(struct flash *flash, struct ffs_handle *ffs) static struct dt_node *flash_add_dt_node(struct flash *flash, int id) { - struct dt_node *flash_node, *flash_dir; + struct dt_node *flash_node; - /* Boot ABI on P9+, flash node is in ibm,opal/flash/flash@0 */ - - if (proc_gen >= proc_gen_p9) { - flash_dir = dt_new(opal_node, "flash"); - assert(flash_dir); - - dt_add_property_cells(flash_dir, "#address-cells", 0); - dt_add_property_cells(flash_dir, "#size-cells", 2); - - flash_node = dt_new_addr(flash_dir, "flash", id); - assert(flash_node); - - /* <= P8, flash is ibm,opal/flash@0, with legacy cell settings */ - - } else { - flash_node = dt_new_addr(opal_node, "flash", id); - assert(flash_node); - - dt_add_property_cells(flash_node, "#address-cells", 1); - dt_add_property_cells(flash_node, "#size-cells", 1); - } - - dt_add_property_string(flash_node, "compatible", "ibm,opal-flash"); + flash_node = dt_new_addr(opal_node, "flash", id); + dt_add_property_strings(flash_node, "compatible", "ibm,opal-flash"); dt_add_property_cells(flash_node, "ibm,opal-id", id); dt_add_property_u64(flash_node, "reg", flash->size); dt_add_property_cells(flash_node, "ibm,flash-block-size", flash->block_size); + /* we fix to 32-bits */ + dt_add_property_cells(flash_node, "#address-cells", 1); + dt_add_property_cells(flash_node, "#size-cells", 1); + return flash_node; } |