diff options
author | Nicholas Piggin <npiggin@gmail.com> | 2019-12-08 22:22:44 +1000 |
---|---|---|
committer | Oliver O'Halloran <oohall@gmail.com> | 2019-12-16 14:50:56 +1100 |
commit | 0ed09ec18e3f856d5456908c4abe3649a025ea12 (patch) | |
tree | 20b76cfd7599e2550af377071b445a94d9766b45 /hw/vas.c | |
parent | ca412e3e4ec28a108ffe8be34ab2226c0cf36a9c (diff) | |
download | skiboot-0ed09ec18e3f856d5456908c4abe3649a025ea12.zip skiboot-0ed09ec18e3f856d5456908c4abe3649a025ea12.tar.gz skiboot-0ed09ec18e3f856d5456908c4abe3649a025ea12.tar.bz2 |
cpu: use dt accessor device tree access
In several cases the make test reference .dts files were incorrectly
byteswapped, these are fixed here too.
Reviewed-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com>
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Diffstat (limited to 'hw/vas.c')
-rw-r--r-- | hw/vas.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -379,7 +379,6 @@ static struct vas *alloc_vas(uint32_t chip_id, uint32_t vas_id, uint64_t base) static void create_mm_dt_node(struct proc_chip *chip) { - int gcid; struct dt_node *dn; struct vas *vas; uint64_t hvwc_start, hvwc_len; @@ -388,7 +387,6 @@ static void create_mm_dt_node(struct proc_chip *chip) uint64_t pbf_start, pbf_nbits; vas = chip->vas; - gcid = chip->id; get_hvwc_mmio_bar(chip->id, &hvwc_start, &hvwc_len); get_uwc_mmio_bar(chip->id, &uwc_start, &uwc_len); get_paste_bar(chip->id, &pbar_start, &pbar_len); @@ -404,8 +402,8 @@ static void create_mm_dt_node(struct proc_chip *chip) pbar_start, pbar_len, pbf_start, pbf_nbits); - dt_add_property(dn, "ibm,vas-id", &vas->vas_id, sizeof(vas->vas_id)); - dt_add_property(dn, "ibm,chip-id", &gcid, sizeof(gcid)); + dt_add_property_cells(dn, "ibm,vas-id", vas->vas_id); + dt_add_property_cells(dn, "ibm,chip-id", chip->id); if (vas->vas_irq) { dt_add_property_cells(dn, "interrupts", vas->vas_irq, 0); dt_add_property_cells(dn, "interrupt-parent", |