Module Name:    src
Committed By:   pgoyette
Date:           Tue Aug 23 12:33:50 UTC 2011

Modified Files:
        src/sys/dev/usb: if_rum.c

Log Message:
In preparation for building this as a module, clean-up some gcc
-Wsign-compare issues so it will build with WARNS=4


To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 src/sys/dev/usb/if_rum.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/usb/if_rum.c
diff -u src/sys/dev/usb/if_rum.c:1.36 src/sys/dev/usb/if_rum.c:1.37
--- src/sys/dev/usb/if_rum.c:1.36	Tue Feb 22 00:58:08 2011
+++ src/sys/dev/usb/if_rum.c	Tue Aug 23 12:33:50 2011
@@ -1,5 +1,5 @@
 /*	$OpenBSD: if_rum.c,v 1.40 2006/09/18 16:20:20 damien Exp $	*/
-/*	$NetBSD: if_rum.c,v 1.36 2011/02/22 00:58:08 jmcneill Exp $	*/
+/*	$NetBSD: if_rum.c,v 1.37 2011/08/23 12:33:50 pgoyette Exp $	*/
 
 /*-
  * Copyright (c) 2005-2007 Damien Bergamini <[email protected]>
@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_rum.c,v 1.36 2011/02/22 00:58:08 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_rum.c,v 1.37 2011/08/23 12:33:50 pgoyette Exp $");
 
 
 #include <sys/param.h>
@@ -843,7 +843,8 @@
 
 	usbd_get_xfer_status(xfer, NULL, NULL, &len, NULL);
 
-	if (len < RT2573_RX_DESC_SIZE + sizeof (struct ieee80211_frame_min)) {
+	if (len < (int)(RT2573_RX_DESC_SIZE +
+		        sizeof(struct ieee80211_frame_min))) {
 		DPRINTF(("%s: xfer too short %d\n", device_xname(sc->sc_dev),
 		    len));
 		ifp->if_ierrors++;
@@ -1303,7 +1304,7 @@
 				break;
 			}
 			IFQ_DEQUEUE(&ifp->if_snd, m0);
-			if (m0->m_len < sizeof(struct ether_header) &&
+			if (m0->m_len < (int)sizeof(struct ether_header) &&
 			    !(m0 = m_pullup(m0, sizeof(struct ether_header))))
 				continue;
 
@@ -1929,7 +1930,7 @@
 rum_bbp_init(struct rum_softc *sc)
 {
 #define N(a)	(sizeof (a) / sizeof ((a)[0]))
-	int i, ntries;
+	unsigned int i, ntries;
 	uint8_t val;
 
 	/* wait for BBP to be ready */
@@ -1969,7 +1970,7 @@
 	struct rum_rx_data *data;
 	uint32_t tmp;
 	usbd_status error = 0;
-	int i, ntries;
+	unsigned int i, ntries;
 
 	if ((sc->sc_flags & RT2573_FWLOADED) == 0) {
 		if (rum_attachhook(sc))

Reply via email to