linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] zd1211rw: make CR_INTERRUPT cast explicit
@ 2010-07-21 15:08 John W. Linville
  2010-07-21 16:36 ` Pavel Roskin
  0 siblings, 1 reply; 4+ messages in thread
From: John W. Linville @ 2010-07-21 15:08 UTC (permalink / raw)
  To: linux-wireless; +Cc: Daniel Drake, Ulrich Kunitz, John W. Linville

  CHECK   drivers/net/wireless/zd1211rw/zd_usb.c
drivers/net/wireless/zd1211rw/zd_usb.c:376:24: warning: implicit cast from nocast type

The value comparison is intentional, so forcing the cast seems warranted
in order to silence the sparse warning.

Signed-off-by: John W. Linville <linville@tuxdriver.com>
---
 drivers/net/wireless/zd1211rw/zd_usb.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/zd1211rw/zd_usb.c b/drivers/net/wireless/zd1211rw/zd_usb.c
index 818e148..acbf4d9 100644
--- a/drivers/net/wireless/zd1211rw/zd_usb.c
+++ b/drivers/net/wireless/zd1211rw/zd_usb.c
@@ -373,7 +373,7 @@ static inline void handle_regs_int(struct urb *urb)
 	spin_lock(&intr->lock);
 
 	int_num = le16_to_cpu(*(__le16 *)(urb->transfer_buffer+2));
-	if (int_num == CR_INTERRUPT) {
+	if (int_num == (u16 __force) CR_INTERRUPT) {
 		struct zd_mac *mac = zd_hw_mac(zd_usb_to_hw(urb->context));
 		memcpy(&mac->intr_buffer, urb->transfer_buffer,
 				USB_MAX_EP_INT_BUFFER);
-- 
1.7.1.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-07-23 22:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-21 15:08 [PATCH] zd1211rw: make CR_INTERRUPT cast explicit John W. Linville
2010-07-21 16:36 ` Pavel Roskin
2010-07-22 19:03   ` John W. Linville
2010-07-23 22:55     ` Pavel Roskin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).