diff options
author | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-11-09 17:51:27 +1100 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-11-09 17:51:27 +1100 |
commit | 5c3e642911ed217bc476478694281a89fe8ef73c (patch) | |
tree | b28c5f8de83a3b2daad507dd2289db7b8a8d06b3 | |
parent | d6e3293cb1d794bf118aab334bb250ed12236956 (diff) | |
download | skiboot-5c3e642911ed217bc476478694281a89fe8ef73c.zip skiboot-5c3e642911ed217bc476478694281a89fe8ef73c.tar.gz skiboot-5c3e642911ed217bc476478694281a89fe8ef73c.tar.bz2 |
sparse: fix incorrect type warnings in hdata/fsp.c
No changes in resulting code as skiboot is BE, but does silence
the sparse warnings.
hdata/fsp.c:67:9: warning: incorrect type in initializer (different base types)
hdata/fsp.c:67:9: expected unsigned int
hdata/fsp.c:67:9: got restricted beint16_t const [usertype] hw_version
hdata/fsp.c:68:9: warning: incorrect type in initializer (different base types)
hdata/fsp.c:68:9: expected unsigned int
hdata/fsp.c:68:9: got restricted beint16_t const [usertype] sw_version
hdata/fsp.c:103:46: warning: incorrect type in argument 1 (different base types)
hdata/fsp.c:103:46: expected unsigned int [unsigned] [usertype] proc_chip_id
hdata/fsp.c:103:46: got restricted beint32_t const [usertype] proc_chip_id
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r-- | hdata/fsp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/hdata/fsp.c b/hdata/fsp.c index 595e1f8..9ea5137 100644 --- a/hdata/fsp.c +++ b/hdata/fsp.c @@ -64,8 +64,8 @@ static struct dt_node *fsp_create_node(const void *spss, int i, "ibm,fsp2"); dt_add_property_cells(node, "reg-offset", 0xb0011000); } - dt_add_property_cells(node, "hw-version", sp_impl->hw_version); - dt_add_property_cells(node, "sw-version", sp_impl->sw_version); + dt_add_property_cells(node, "hw-version", be16_to_cpu(sp_impl->hw_version)); + dt_add_property_cells(node, "sw-version", be16_to_cpu(sp_impl->sw_version)); if (be16_to_cpu(sp_impl->func_flags) & SPSS_SP_IMPL_FLAGS_PRIMARY) dt_add_property(node, "primary", NULL, 0); @@ -100,7 +100,7 @@ static uint32_t fsp_create_link(const struct spss_iopath *iopath, int index, prlog(PR_DEBUG, "FSP #%d: IO PATH %d is %s PSI Link, GXHB at %llx\n", fsp_index, index, ststr, (long long)iopath->psi.gxhb_base); - chip_id = pcid_to_chip_id(iopath->psi.proc_chip_id); + chip_id = pcid_to_chip_id(be32_to_cpu(iopath->psi.proc_chip_id)); node = dt_find_compatible_node_on_chip(dt_root, NULL, "ibm,psihb-x", chip_id); if (!node) { |