From f28fdbcd96dadf5f4e3c9509b9d7abe053a87b24 Mon Sep 17 00:00:00 2001 From: Stewart Smith Date: Thu, 28 Sep 2017 16:39:50 +1000 Subject: hdata/spira: be32_to_cpu() doesn't work on 8bits Sparse warning: hdata/spira.c:1458:41: warning: incorrect type in argument 1 (different base types) expected restricted beint32_t [usertype] be_val got unsigned char const [unsigned] [usertype] link_speed Signed-off-by: Stewart Smith Reviewed-by: Oliver O'Halloran Signed-off-by: Stewart Smith --- hdata/spira.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'hdata') diff --git a/hdata/spira.c b/hdata/spira.c index 7e88348..a142188 100644 --- a/hdata/spira.c +++ b/hdata/spira.c @@ -1455,7 +1455,7 @@ static void add_npu(struct dt_node *xscom, const struct HDIF_array_hdr *links, if (size <= 0x24) continue; - switch (be32_to_cpu(link->link_speed)) { + switch (link->link_speed) { case 0: /* 20Gbps */ speed = 20000000000ul; nvlink_speed = 0x3; -- cgit v1.1