diff mbox

[stable,07/14] sparse: fix conversion of hdat slca_index

Message ID 1453348281-16085-8-git-send-email-stewart@linux.vnet.ibm.com
State Accepted
Headers show

Commit Message

Stewart Smith Jan. 21, 2016, 3:51 a.m. UTC
commit 020a741ae22dd70a027918dbb738cb16fed3bb57 upstream

No code changes as skiboot is BE.

hdata/vpd.c:559:38: warning: incorrect type in argument 1 (different base types)
hdata/vpd.c:559:38:    expected unsigned short [unsigned] [usertype] slca_index
hdata/vpd.c:559:38:    got restricted beint16_t const [usertype] slca_index

Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
---
 hdata/vpd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/hdata/vpd.c b/hdata/vpd.c
index 754e5f6751e7..d9ee77c6335b 100644
--- a/hdata/vpd.c
+++ b/hdata/vpd.c
@@ -557,7 +557,7 @@  struct dt_node *dt_add_vpd_node(const struct HDIF_common_hdr *hdr,
 		first = false;
 	}
 
-	entry = slca_get_entry(fru_id->slca_index);
+	entry = slca_get_entry(be16_to_cpu(fru_id->slca_index));
 	if (!entry)
 		return NULL;