OSDN Git Service

staging: typec: fix endianness mismatch identified by sparse
authorGabriel L. Somlo <gsomlo@gmail.com>
Mon, 18 Dec 2017 21:55:24 +0000 (16:55 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 19 Dec 2017 10:57:37 +0000 (11:57 +0100)
commit81948cbcf12cb16a6f5fad9c86233a596e2f47ab
tree2295b48b7d8710ba14bc7a64a2c0694f26f9947f
parent7f9d04bc568d22e573a10e2a0a316599942786f7
staging: typec: fix endianness mismatch identified by sparse

Eliminate the following sparse warnings:

tcpci.c:291:38: warning: incorrect type in argument 1 (different base types)
tcpci.c:291:38:    expected unsigned short [unsigned] [usertype] header
tcpci.c:291:38:    got restricted __le16 const [usertype] header
tcpci.c:296:16: warning: incorrect type in assignment (different base types)
tcpci.c:296:16:    expected unsigned int [unsigned] header
tcpci.c:296:16:    got restricted __le16
tcpci.c:394:28: warning: incorrect type in assignment (different base types)
tcpci.c:394:28:    expected restricted __le16 [usertype] header
tcpci.c:394:28:    got unsigned int [unsigned] [addressable] reg

Signed-off-by: Gabriel Somlo <gsomlo@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/typec/tcpci.c