summaryrefslogtreecommitdiffstats
path: root/drivers/staging/greybus/manifest.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@google.com>2016-02-02 21:31:19 -0800
committerGreg Kroah-Hartman <gregkh@google.com>2016-02-03 10:38:54 -0800
commitd1a9c0560a4ffc05c31a042dff380ddf1ea721b0 (patch)
tree87e879204c056cead10f4cfff16c6d0c11ef2700 /drivers/staging/greybus/manifest.c
parentec413566e819ad19be929ab38d2b5911cbf096c2 (diff)
downloadlinux-d1a9c0560a4ffc05c31a042dff380ddf1ea721b0.tar.bz2
greybus: fix sparse warning in manifest.c
The cport id field is a le16, so treat it as such when comparing it to something else. Signed-off-by: Greg Kroah-Hartman <gregkh@google.com> Reviewed-by: Johan Hovold <johan@hovoldconsulting.com> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/manifest.c')
-rw-r--r--drivers/staging/greybus/manifest.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/greybus/manifest.c b/drivers/staging/greybus/manifest.c
index 5ca36c9001be..4e3c4cab0fc4 100644
--- a/drivers/staging/greybus/manifest.c
+++ b/drivers/staging/greybus/manifest.c
@@ -256,7 +256,7 @@ static u32 gb_manifest_parse_cports(struct gb_bundle *bundle)
*/
list_for_each_entry(tmp, &list, links) {
desc_cport = tmp->data;
- if (cport_id == desc_cport->id) {
+ if (cport_id == le16_to_cpu(desc_cport->id)) {
dev_err(&bundle->dev,
"duplicate CPort %u found\n",
cport_id);