Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1245658

[char-misc-next 5/5] mei: amthif: Do not compare bool to 0/1

From Tomas Winkler <tomas.winkler@intel.com>
Newsgroups linux.kernel
Subject [char-misc-next 5/5] mei: amthif: Do not compare bool to 0/1
Date 2015-10-13 14:10 +0200
Message-ID <qj6yZ-66w-15@gated-at.bofh.it> (permalink)
References <qj6yZ-66w-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Alexander Usyskin <alexander.usyskin@intel.com>

Spotted by coccicheck:
drivers/misc/mei/amthif.c:479:5-26: WARNING: Comparison of bool to 0/1

Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
 drivers/misc/mei/amthif.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/misc/mei/amthif.c b/drivers/misc/mei/amthif.c
index 1e42781592d8..cd0403f09267 100644
--- a/drivers/misc/mei/amthif.c
+++ b/drivers/misc/mei/amthif.c
@@ -458,7 +458,7 @@ void mei_amthif_complete(struct mei_device *dev, struct mei_cl_cb *cb)
 		return;
 	}
 
-	if (dev->iamthif_canceled != 1) {
+	if (!dev->iamthif_canceled) {
 		dev->iamthif_state = MEI_IAMTHIF_READ_COMPLETE;
 		dev->iamthif_stall_timer = 0;
 		list_add_tail(&cb->list, &dev->amthif_rd_complete_list.list);
-- 
2.4.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[char-misc-next 1/5] mei: cancel driver workers only after client devices were removed Tomas Winkler <tomas.winkler@intel.com> - 2015-10-13 14:10 +0200
  [char-misc-next 4/5] mei: bus: fix c&p issue in the kdoc Tomas Winkler <tomas.winkler@intel.com> - 2015-10-13 14:10 +0200
  [char-misc-next 5/5] mei: amthif: Do not compare bool to 0/1 Tomas Winkler <tomas.winkler@intel.com> - 2015-10-13 14:10 +0200
  [char-misc-next 3/5] mei: fix the KDoc formating Tomas Winkler <tomas.winkler@intel.com> - 2015-10-13 14:10 +0200

csiph-web