diff options
author | Michael Neuling <mikey@neuling.org> | 2017-07-12 12:06:45 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2017-07-13 10:19:45 +1000 |
commit | a78732d14ce62d30ea20f4de39f688f3f0e99612 (patch) | |
tree | fb59ed0ba44a6164915c2f34395daafc135033af /hdata/iohub.c | |
parent | d63ed063f5dcb443be3226d2c7a48f2f4326e717 (diff) | |
download | skiboot-a78732d14ce62d30ea20f4de39f688f3f0e99612.zip skiboot-a78732d14ce62d30ea20f4de39f688f3f0e99612.tar.gz skiboot-a78732d14ce62d30ea20f4de39f688f3f0e99612.tar.bz2 |
hdata: Fix phb4 lane-eq property generation
The lane-eq data we get from hdat is all 7s but what we end up in the
device tree is:
xscom@603fc00000000/pbcq@4010c00/stack@0/ibm,lane-eq
00000000 31c339e0 00000000 0000000c
00000000 00000000 00000000 00000000
00000000 31c30000 77777777 77777777
77777777 77777777 77777777 77777777
This fixes grabbing the properties from hdat and fixes the call to put
them in the device tree.
Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hdata/iohub.c')
-rw-r--r-- | hdata/iohub.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/hdata/iohub.c b/hdata/iohub.c index c0b9bf8..de163da 100644 --- a/hdata/iohub.c +++ b/hdata/iohub.c @@ -273,12 +273,13 @@ static struct dt_node *add_pec_stack(const struct cechub_io_hub *hub, dt_add_property_string(stack, "status", "disabled"); for (i = 0; i < 4; i++) /* gen 3 eq settings */ - eq[i] = be64_to_cpu(hub->phb4_lane_eq[phb_index][i]); + eq[i] = be64_to_cpu(hub->phb_lane_eq[phb_index][i]); - for (i = 4; i < 8; i++) /* gen 4 eq settings */ - eq[i] = be64_to_cpu(hub->phb4_lane_eq[phb_index][i]); + for (i = 0; i < 4; i++) /* gen 4 eq settings */ + eq[i+4] = be64_to_cpu(hub->phb4_lane_eq[phb_index][i]); - __dt_add_property_u64s(stack, "ibm,lane-eq", 8, eq); + dt_add_property_u64s(stack, "ibm,lane-eq", eq[0], eq[1], eq[2], eq[3], + eq[4], eq[5], eq[6], eq[7]); return stack; } |