Selaa lähdekoodia

Warnings purge of drivers (continued)

tags/v0.9.3
Marty Connor 17 vuotta sitten
vanhempi
commit
1af1668c95

+ 3
- 3
src/drivers/net/amd8111e.c Näytä tiedosto

@@ -135,7 +135,6 @@ static void amd8111e_restart(struct amd8111e_priv *lp);
135 135
 static void amd8111e_init_hw_default(struct amd8111e_priv *lp)
136 136
 {
137 137
 	unsigned int reg_val;
138
-	unsigned int logic_filter[2] = {0,};
139 138
 	void *mmio = lp->mmio;
140 139
 
141 140
         /* stop the chip */
@@ -198,7 +197,8 @@ static void amd8111e_init_hw_default(struct amd8111e_priv *lp)
198 197
 	writew(MIB_CLEAR, mmio + MIB_ADDR);
199 198
 
200 199
 	/* Clear LARF */
201
-	amd8111e_writeq(*(u64*)logic_filter, mmio + LADRF);
200
+	writel( 0, mmio + LADRF);
201
+	writel( 0, mmio + LADRF + 4);
202 202
 
203 203
 	/* SRAM_SIZE register */
204 204
 	reg_val = readl(mmio + SRAM_SIZE);
@@ -342,7 +342,7 @@ static void amd8111e_probe_ext_phy(struct amd8111e_priv *lp)
342 342
 
343 343
 	if (lp->ext_phy_id)
344 344
 		printf("Found MII PHY ID 0x%08x at address 0x%02x\n",
345
-			lp->ext_phy_id, lp->ext_phy_addr);
345
+		       (unsigned int) lp->ext_phy_id, lp->ext_phy_addr);
346 346
 	else
347 347
 		printf("Couldn't detect MII PHY, assuming address 0x01\n");
348 348
 }

+ 7
- 5
src/drivers/net/bnx2.c Näytä tiedosto

@@ -22,12 +22,14 @@
22 22
 #include "bnx2.h"
23 23
 #include "bnx2_fw.h"
24 24
 
25
+#if 0
25 26
 /* Dummy defines for error handling */
26 27
 #define EBUSY  1
27 28
 #define ENODEV 2
28 29
 #define EINVAL 3
29 30
 #define ENOMEM 4
30 31
 #define EIO    5
32
+#endif
31 33
 
32 34
 /* The bnx2 seems to be picky about the alignment of the receive buffers
33 35
  * and possibly the status block.
@@ -1165,7 +1167,7 @@ bnx2_fw_sync(struct bnx2 *bp, u32 msg_data, int silent)
1165 1167
 	/* If we timed out, inform the firmware that this is the case. */
1166 1168
 	if ((val & BNX2_FW_MSG_ACK) != (msg_data & BNX2_DRV_MSG_SEQ)) {
1167 1169
 		if (!silent)
1168
-			printf("fw sync timeout, reset code = %x\n", msg_data);
1170
+		  printf("fw sync timeout, reset code = %x\n", (unsigned int) msg_data);
1169 1171
 
1170 1172
 		msg_data &= ~BNX2_DRV_MSG_CODE;
1171 1173
 		msg_data |= BNX2_DRV_MSG_CODE_FW_TIMEOUT;
@@ -2033,7 +2035,7 @@ static void
2033 2035
 bnx2_init_rx_ring(struct bnx2 *bp)
2034 2036
 {
2035 2037
 	struct rx_bd *rxbd;
2036
-	int i;
2038
+	unsigned int i;
2037 2039
 	u16 prod, ring_prod;
2038 2040
 	u32 val;
2039 2041
 
@@ -2066,7 +2068,7 @@ bnx2_init_rx_ring(struct bnx2 *bp)
2066 2068
 	val = bp->rx_desc_mapping & 0xffffffff;
2067 2069
 	CTX_WR(bp, GET_CID_ADDR(RX_CID), BNX2_L2CTX_NX_BDHADDR_LO, val);
2068 2070
 
2069
-	for (i = 0; i < bp->rx_ring_size; i++) {
2071
+	for (i = 0; (int) i < bp->rx_ring_size; i++) {
2070 2072
 		rxbd = &bp->rx_desc_ring[RX_RING_IDX(ring_prod)];
2071 2073
 		rxbd->rx_bd_haddr_hi = 0;
2072 2074
 		rxbd->rx_bd_haddr_lo = virt_to_bus(&bnx2_bss.rx_buf[ring_prod][0]);
@@ -2635,8 +2637,8 @@ bnx2_probe(struct nic *nic, struct pci_device *pdev)
2635 2637
 	memcpy(nic->node_addr, bp->mac_addr, ETH_ALEN);
2636 2638
 	printf("Ethernet addr: %s\n", eth_ntoa( nic->node_addr ) );
2637 2639
 	printf("Broadcom NetXtreme II (%c%d) PCI%s %s %dMHz\n",
2638
-		((CHIP_ID(bp) & 0xf000) >> 12) + 'A',
2639
-		((CHIP_ID(bp) & 0x0ff0) >> 4),
2640
+	        (int) ((CHIP_ID(bp) & 0xf000) >> 12) + 'A',
2641
+	        (int) ((CHIP_ID(bp) & 0x0ff0) >> 4),
2640 2642
 		((bp->flags & PCIX_FLAG) ? "-X" : ""),
2641 2643
 		((bp->flags & PCI_32BIT_FLAG) ? "32-bit" : "64-bit"),
2642 2644
 		bp->bus_speed_mhz);

+ 1
- 1
src/drivers/net/bnx2.h Näytä tiedosto

@@ -4091,7 +4091,7 @@ struct flash_spec {
4091 4091
 	u32 page_size;
4092 4092
 	u32 addr_mask;
4093 4093
 	u32 total_size;
4094
-	u8  *name;
4094
+	char  *name;
4095 4095
 };
4096 4096
 
4097 4097
 struct bnx2 {

+ 4
- 1
src/drivers/net/depca.c Näytä tiedosto

@@ -1,5 +1,6 @@
1
-#warning "depca.c almost certainly won't work"
1
+#warning "depca.c almost certainly won't work."
2 2
 
3
+#if 0
3 4
 /* Not fixed for relocation yet. Probably won't work relocated above 16MB */
4 5
 #ifdef ALLMULTI
5 6
 #error multicast support is not yet implemented
@@ -791,3 +792,5 @@ DRIVER ( "depce", nic_driver, isa_driver, depca_driver,
791 792
 	 depca_probe, depca_disable );
792 793
 
793 794
 ISA_ROM ( "depca", "Digital DE100 and DE200" );
795
+
796
+#endif

+ 1
- 1
src/drivers/net/dmfe.c Näytä tiedosto

@@ -1022,7 +1022,7 @@ static u16 phy_read_1bit(unsigned long ioaddr)
1022 1022
 
1023 1023
 static void dmfe_parse_srom(struct nic *nic)
1024 1024
 {
1025
-	char *srom = db->srom;
1025
+	unsigned char *srom = db->srom;
1026 1026
 	int dmfe_mode, tmp_reg;
1027 1027
 
1028 1028
 	/* Init CR15 */

+ 7
- 6
src/drivers/net/eepro.c Näytä tiedosto

@@ -265,11 +265,12 @@ static unsigned eeprom_reg = EEPROM_REG_PRO;
265 265
 #define eepro_full_reset(ioaddr)	outb(RESET_CMD, ioaddr); udelay(255);
266 266
 
267 267
 /* do a nice reset */
268
-#define eepro_sel_reset(ioaddr) 	{ \
269
-					outb(SEL_RESET_CMD, ioaddr); \
270
-					SLOW_DOWN; \
271
-					SLOW_DOWN; \
272
-					}
268
+#define eepro_sel_reset(ioaddr) \
269
+  do {  \
270
+    outb ( SEL_RESET_CMD, ioaddr ); \
271
+    (void) SLOW_DOWN; \
272
+    (void) SLOW_DOWN; \
273
+  } while (0)
273 274
 
274 275
 /* clear all interrupts */
275 276
 #define	eepro_clear_int(ioaddr)	outb(ALL_MASK, ioaddr + STATUS_REG)
@@ -332,7 +333,7 @@ static void eepro_reset(struct nic *nic)
332 333
 	/* Intialise XMT */
333 334
 	outw((XMT_LOWER_LIMIT << 8), nic->ioaddr + xmt_bar);
334 335
 	eepro_sel_reset(nic->ioaddr);
335
-	tx_start = tx_end = (XMT_LOWER_LIMIT << 8);
336
+	tx_start = tx_end = (unsigned int) (XMT_LOWER_LIMIT << 8);
336 337
 	tx_last = 0;
337 338
 	eepro_en_rx(nic->ioaddr);
338 339
 }

+ 3
- 3
src/drivers/net/mtd80x.c Näytä tiedosto

@@ -534,7 +534,7 @@ static int mtd_poll(struct nic *nic, __unused int retrieve)
534 534
     if (rx_status & ErrorSummary)
535 535
     { /* there was a fatal error */
536 536
         printf( "%s: Receive error, Rx status %8.8x, Error(s) %s%s%s\n",
537
-                mtdx.nic_name, rx_status ,
537
+                mtdx.nic_name, (unsigned int) rx_status,
538 538
                 (rx_status & (LONG | RUNT)) ? "length_error ":"",
539 539
                 (rx_status & RXER) ? "frame_error ":"",
540 540
                 (rx_status & CRC) ? "crc_error ":"" );
@@ -550,7 +550,7 @@ static int mtd_poll(struct nic *nic, __unused int retrieve)
550 550
         short pkt_len = ((rx_status & FLNGMASK) >> FLNGShift) - 4;
551 551
 
552 552
         DBG ( " netdev_rx() normal Rx pkt length %d"
553
- 	      " status %x.\n", pkt_len, rx_status );
553
+ 	      " status %x.\n", pkt_len, (unsigned int) rx_status );
554 554
 
555 555
         nic->packetlen = pkt_len;
556 556
         memcpy(nic->packet, mtdx.cur_rx->skbuff, pkt_len);
@@ -619,7 +619,7 @@ static void mtd_transmit(
619 619
         DBG ( "TX Time Out" );
620 620
     } else if( tx_status & (CSL | LC | EC | UDF | HF)){
621 621
         printf( "Transmit error: %8.8x %s %s %s %s %s\n",
622
-                tx_status,
622
+                (unsigned int) tx_status,
623 623
                 tx_status & EC ? "abort" : "",
624 624
                 tx_status & CSL ? "carrier" : "",
625 625
                 tx_status & LC ? "late" : "",

+ 7
- 6
src/drivers/net/natsemi.c Näytä tiedosto

@@ -536,7 +536,8 @@ natsemi_init_rxd(struct nic *nic __unused)
536 536
         rxd[i].bufptr = virt_to_bus(&rxb[i*RX_BUF_SIZE]);
537 537
         if (natsemi_debug > 1)
538 538
             printf("natsemi_init_rxd: rxd[%d]=%p link=%X cmdsts=%X bufptr=%4.4x\n", 
539
-                   i, &rxd[i], rxd[i].link, rxd[i].cmdsts, rxd[i].bufptr);
539
+                   i, &rxd[i], (unsigned int) rxd[i].link, (unsigned int) rxd[i].cmdsts, 
540
+		   (unsigned int) rxd[i].bufptr);
540 541
     }
541 542
 
542 543
     /* load Receive Descriptor Register */
@@ -648,11 +649,11 @@ natsemi_transmit(struct nic  *nic,
648 649
         /* wait */ ;
649 650
 
650 651
     if (currticks() >= to) {
651
-        printf("natsemi_transmit: TX Timeout! Tx status %X.\n", tx_status);
652
+        printf("natsemi_transmit: TX Timeout! Tx status %X.\n", (unsigned int) tx_status);
652 653
     }
653 654
 
654 655
     if (!(tx_status & 0x08000000)) {
655
-	printf("natsemi_transmit: Transmit error, Tx status %X.\n", tx_status);
656
+	printf("natsemi_transmit: Transmit error, Tx status %X.\n", (unsigned int) tx_status);
656 657
     }
657 658
 }
658 659
 
@@ -677,7 +678,7 @@ natsemi_poll(struct nic *nic, int retrieve)
677 678
     int retstat = 0;
678 679
 
679 680
     if (natsemi_debug > 2)
680
-        printf("natsemi_poll: cur_rx:%d, status:%X\n", cur_rx, rx_status);
681
+        printf("natsemi_poll: cur_rx:%d, status:%X\n", cur_rx, (unsigned int) rx_status);
681 682
 
682 683
     if (!(rx_status & OWN))
683 684
         return retstat;
@@ -686,14 +687,14 @@ natsemi_poll(struct nic *nic, int retrieve)
686 687
 
687 688
     if (natsemi_debug > 1)
688 689
         printf("natsemi_poll: got a packet: cur_rx:%d, status:%X\n",
689
-               cur_rx, rx_status);
690
+               cur_rx, (unsigned int) rx_status);
690 691
 
691 692
     nic->packetlen = (rx_status & DSIZE) - CRC_SIZE;
692 693
 
693 694
     if ((rx_status & (DescMore|DescPktOK|RxTooLong)) != DescPktOK) {
694 695
         /* corrupted packet received */
695 696
         printf("natsemi_poll: Corrupted packet received, buffer status = %X\n",
696
-               rx_status);
697
+               (unsigned int) rx_status);
697 698
         retstat = 0;
698 699
     } else {
699 700
         /* give packet to higher level routine */

+ 3
- 2
src/drivers/net/ns83820.c Näytä tiedosto

@@ -631,9 +631,10 @@ static void ns83820_run_bist(struct nic *nic __unused, const char *name,
631 631
 	}
632 632
 
633 633
 	if (status & fail)
634
-		printf("%s failed! (0x%hX & 0x%hX)\n", name, status, fail);
634
+	  printf("%s failed! (0x%hX & 0x%hX)\n", name, (unsigned int) status, 
635
+		 (unsigned int) fail);
635 636
 	else if (timed_out)
636
-		printf("run_bist %s timed out! (%hX)\n", name, status);
637
+		printf("run_bist %s timed out! (%hX)\n", name, (unsigned int) status);
637 638
 	dprintf(("done %s in %d loops\n", name, loops));
638 639
 }
639 640
 

+ 9
- 8
src/drivers/net/ns8390.c Näytä tiedosto

@@ -449,11 +449,11 @@ static void ns8390_transmit(
449 449
 		/* Programmed I/O */
450 450
 		unsigned short type;
451 451
 		type = (t >> 8) | (t << 8);
452
-		eth_pio_write(d, eth_tx_start<<8, ETH_ALEN);
452
+		eth_pio_write( (unsigned char *) d, eth_tx_start<<8, ETH_ALEN);
453 453
 		eth_pio_write(nic->node_addr, (eth_tx_start<<8)+ETH_ALEN, ETH_ALEN);
454 454
 		/* bcc generates worse code without (const+const) below */
455 455
 		eth_pio_write((unsigned char *)&type, (eth_tx_start<<8)+(ETH_ALEN+ETH_ALEN), 2);
456
-		eth_pio_write(p, (eth_tx_start<<8)+ETH_HLEN, s);
456
+		eth_pio_write( (unsigned char *) p, (eth_tx_start<<8)+ETH_HLEN, s);
457 457
 		s += ETH_HLEN;
458 458
 		if (s < ETH_ZLEN) s = ETH_ZLEN;
459 459
 	}
@@ -533,7 +533,7 @@ static int ns8390_poll(struct nic *nic, int retrieve)
533 533
 #endif
534 534
 	pktoff = next << 8;
535 535
 	if (eth_flags & FLAG_PIO)
536
-		eth_pio_read(pktoff, (char *)&pkthdr, 4);
536
+		eth_pio_read(pktoff, (unsigned char *)&pkthdr, 4);
537 537
 	else
538 538
 		memcpy(&pkthdr, bus_to_virt(eth_rmem + pktoff), 4);
539 539
 	pktoff += sizeof(pkthdr);
@@ -876,9 +876,10 @@ static int eth_probe (struct dev *dev, unsigned short *probe_addrs __unused)
876 876
 	******************************************************************/
877 877
 	unsigned char c;
878 878
 	if (eth_vendor == VENDOR_NONE) {
879
-		char romdata[16], testbuf[32];
879
+		unsigned char romdata[16];
880
+		unsigned char testbuf[32];
880 881
 		int idx;
881
-		static char test[] = "NE*000 memory";
882
+		static unsigned char test[] = "NE*000 memory";
882 883
 		static unsigned short base[] = {
883 884
 #ifdef	NE_SCAN
884 885
 			NE_SCAN,
@@ -896,7 +897,7 @@ static int eth_probe (struct dev *dev, unsigned short *probe_addrs __unused)
896 897
 			eth_rx_start = 32 + D8390_TXBUF_SIZE;
897 898
 			c = inb(eth_asic_base + NE_RESET);
898 899
 			outb(c, eth_asic_base + NE_RESET);
899
-			inb(0x84);
900
+			(void) inb(0x84);
900 901
 			outb(D8390_COMMAND_STP |
901 902
 				D8390_COMMAND_RD2, eth_nic_base + D8390_P0_COMMAND);
902 903
 			outb(D8390_RCR_MON, eth_nic_base + D8390_P0_RCR);
@@ -907,7 +908,7 @@ static int eth_probe (struct dev *dev, unsigned short *probe_addrs __unused)
907 908
 			eth_flags |= FLAG_16BIT;	/* force 16-bit mode */
908 909
 #endif
909 910
 
910
-			eth_pio_write(test, 8192, sizeof(test));
911
+			eth_pio_write( (unsigned char *) test, 8192, sizeof(test));
911 912
 			eth_pio_read(8192, testbuf, sizeof(test));
912 913
 			if (!memcmp(test, testbuf, sizeof(test)))
913 914
 				break;
@@ -919,7 +920,7 @@ static int eth_probe (struct dev *dev, unsigned short *probe_addrs __unused)
919 920
 				D8390_DCR_FT1 | D8390_DCR_LS, eth_nic_base + D8390_P0_DCR);
920 921
 			outb(MEM_16384, eth_nic_base + D8390_P0_PSTART);
921 922
 			outb(MEM_32768, eth_nic_base + D8390_P0_PSTOP);
922
-			eth_pio_write(test, 16384, sizeof(test));
923
+			eth_pio_write( (unsigned char *) test, 16384, sizeof(test));
923 924
 			eth_pio_read(16384, testbuf, sizeof(test));
924 925
 			if (!memcmp(testbuf, test, sizeof(test)))
925 926
 				break;

+ 2
- 2
src/drivers/net/pcnet32.c Näytä tiedosto

@@ -787,7 +787,7 @@ static int pcnet32_probe ( struct nic *nic, struct pci_device *pci ) {
787 787
 		ltint = 1;
788 788
 	}
789 789
 
790
-	DBG ( "%s at %hX,", chipname, ioaddr );
790
+	DBG ( "%s at %hX,", chipname, (unsigned int) ioaddr );
791 791
 
792 792
 	/* read PROM address */
793 793
 	for (i = 0; i < 6; i++)
@@ -799,7 +799,7 @@ static int pcnet32_probe ( struct nic *nic, struct pci_device *pci ) {
799 799
 	}
800 800
 
801 801
 	/* Print out some hardware info */
802
-	DBG ( "%s: IO Addr 0x%hX, MAC Addr %s\n ", chipname, ioaddr,
802
+	DBG ( "%s: IO Addr 0x%hX, MAC Addr %s\n ", chipname, (unsigned int) ioaddr,
803 803
 	      eth_ntoa ( nic->node_addr ) );
804 804
 
805 805
 	/* Set to pci bus master */

+ 11
- 1
src/drivers/net/r8169.c Näytä tiedosto

@@ -74,12 +74,22 @@ static u32 ioaddr;
74 74
 
75 75
 
76 76
 #ifdef RTL8169_DEBUG
77
+
78
+#if 0
77 79
 #define assert(expr) \
78 80
                if(!(expr)) { printk( "Assertion failed! %s,%s,%s,line=%d\n", #expr,__FILE__,__FUNCTION__,__LINE__); }
81
+#endif
82
+
79 83
 #define DBG_PRINTF( fmt, args...)   printk("r8169: " fmt, ## args);
84
+
80 85
 #else
86
+
87
+#if 0
81 88
 #define assert(expr) do {} while (0)
89
+#endif
90
+
82 91
 #define DBG_PRINTF( fmt, args...)   ;
92
+
83 93
 #endif				// end of #ifdef RTL8169_DEBUG
84 94
 
85 95
 /* media options 
@@ -904,7 +914,7 @@ static int r8169_probe ( struct nic *nic, struct pci_device *pci ) {
904 914
 
905 915
 	/* Print out some hardware info */
906 916
 	DBG ( "%s: %s at IOAddr %#hX, ", pci->driver_name, eth_ntoa ( nic->node_addr ),
907
-	       ioaddr );
917
+	      (unsigned int) ioaddr );
908 918
 
909 919
 	/* Config PHY */
910 920
 	rtl8169_hw_PHY_config(nic);

+ 10
- 6
src/drivers/net/sis900.c Näytä tiedosto

@@ -751,7 +751,8 @@ sis900_init_rxd(struct nic *nic __unused)
751 751
         rxd[i].bufptr = virt_to_bus(&rxb[i*RX_BUF_SIZE]);
752 752
         if (sis900_debug > 0)
753 753
             printf("sis900_init_rxd: rxd[%d]=%p link=%X cmdsts=%X bufptr=%X\n", 
754
-                   i, &rxd[i], rxd[i].link, rxd[i].cmdsts, rxd[i].bufptr);
754
+                   i, &rxd[i], (unsigned int) rxd[i].link, (unsigned int) rxd[i].cmdsts,
755
+		   (unsigned int) rxd[i].bufptr);
755 756
     }
756 757
 
757 758
     /* load Receive Descriptor Register */
@@ -1146,12 +1147,14 @@ sis900_transmit(struct nic  *nic,
1146 1147
         /* wait */ ;
1147 1148
 
1148 1149
     if (currticks() >= to) {
1149
-        printf("sis900_transmit: TX Timeout! Tx status %X.\n", tx_status);
1150
+        printf("sis900_transmit: TX Timeout! Tx status %X.\n", 
1151
+	       (unsigned int) tx_status);
1150 1152
     }
1151 1153
     
1152 1154
     if (tx_status & (ABORT | UNDERRUN | OWCOLL)) {
1153 1155
         /* packet unsuccessfully transmited */
1154
-        printf("sis900_transmit: Transmit error, Tx status %X.\n", tx_status);
1156
+        printf("sis900_transmit: Transmit error, Tx status %X.\n", 
1157
+	       (unsigned int) tx_status);
1155 1158
     }
1156 1159
     /* Disable interrupts by clearing the interrupt mask. */
1157 1160
     outl(0, ioaddr + imr);
@@ -1179,14 +1182,15 @@ sis900_poll(struct nic *nic, int retrieve)
1179 1182
     int retstat = 0;
1180 1183
 
1181 1184
     if (sis900_debug > 2)
1182
-        printf("sis900_poll: cur_rx:%d, status:%X\n", cur_rx, rx_status);
1185
+        printf("sis900_poll: cur_rx:%d, status:%X\n", cur_rx, 
1186
+	       (unsigned int) rx_status);
1183 1187
 
1184 1188
     if (!(rx_status & OWN))
1185 1189
         return retstat;
1186 1190
 
1187 1191
     if (sis900_debug > 1)
1188 1192
         printf("sis900_poll: got a packet: cur_rx:%d, status:%X\n",
1189
-               cur_rx, rx_status);
1193
+               cur_rx, (unsigned int) rx_status);
1190 1194
 
1191 1195
     if ( ! retrieve ) return 1;
1192 1196
     
@@ -1195,7 +1199,7 @@ sis900_poll(struct nic *nic, int retrieve)
1195 1199
     if (rx_status & (ABORT|OVERRUN|TOOLONG|RUNT|RXISERR|CRCERR|FAERR)) {
1196 1200
         /* corrupted packet received */
1197 1201
         printf("sis900_poll: Corrupted packet received, buffer status = %X\n",
1198
-               rx_status);
1202
+               (unsigned int) rx_status);
1199 1203
         retstat = 0;
1200 1204
     } else {
1201 1205
         /* give packet to higher level routine */

+ 1
- 1
src/drivers/net/sundance.c Näytä tiedosto

@@ -611,7 +611,7 @@ static int sundance_probe ( struct nic *nic, struct pci_device *pci ) {
611 611
 	DBG ( "Device revision id: %hx\n", sdc->pci_rev_id );
612 612
 
613 613
 	/* Print out some hardware info */
614
-	DBG ( "%s: %s at ioaddr %hX, ", pci->driver_name, nic->node_addr, BASE);
614
+	DBG ( "%s: %s at ioaddr %hX, ", pci->driver_name, nic->node_addr, (unsigned int) BASE);
615 615
 
616 616
 	sdc->mii_preamble_required = 0;
617 617
 	if (1) {

+ 6
- 6
src/drivers/net/tlan.c Näytä tiedosto

@@ -70,7 +70,7 @@ static void TLan_PhyPowerDown(struct nic *nic);
70 70
 static void TLan_PhyPowerUp(struct nic *nic);
71 71
 
72 72
 
73
-static void TLan_SetMac(struct nic *nic __unused, int areg, char *mac);
73
+static void TLan_SetMac(struct nic *nic __unused, int areg, unsigned char *mac);
74 74
 
75 75
 static void TLan_PhyReset(struct nic *nic);
76 76
 static void TLan_PhyStartLink(struct nic *nic);
@@ -515,7 +515,7 @@ static int tlan_poll(struct nic *nic, int retrieve)
515 515
 
516 516
 	nic->packetlen = framesize;
517 517
 
518
-	DBG ( ".%d.", framesize ); 
518
+	DBG ( ".%d.", (unsigned int) framesize ); 
519 519
      
520 520
 	memcpy(nic->packet, rxb +
521 521
 	       (priv->cur_rx * TLAN_MAX_FRAME_SIZE), nic->packetlen);
@@ -591,7 +591,7 @@ static void tlan_transmit(struct nic *nic, const char *d,	/* Destination */
591 591
 
592 592
 	if (tail_list->cStat != TLAN_CSTAT_UNUSED) {
593 593
 		printf("TRANSMIT: %s is busy (Head=%p Tail=%x)\n",
594
-		       priv->nic_name, priv->txList, priv->txTail);
594
+		       priv->nic_name, priv->txList, (unsigned int) priv->txTail);
595 595
 		tx_ring[entry].cStat = TLAN_CSTAT_UNUSED;
596 596
 //		priv->txBusyCount++;
597 597
 		return;
@@ -1300,7 +1300,7 @@ void TLan_MiiWriteReg(struct nic *nic __unused, u16 phy, u16 reg, u16 val)
1300 1300
 *
1301 1301
 **************************************************************/
1302 1302
 
1303
-void TLan_SetMac(struct nic *nic __unused, int areg, char *mac)
1303
+void TLan_SetMac(struct nic *nic __unused, int areg, unsigned char *mac)
1304 1304
 {
1305 1305
 	int i;
1306 1306
 
@@ -1361,8 +1361,8 @@ void TLan_PhyDetect(struct nic *nic)
1361 1361
 		TLan_MiiReadReg(nic, phy, MII_GEN_ID_LO, &lo);
1362 1362
 		if ((control != 0xFFFF) || (hi != 0xFFFF)
1363 1363
 		    || (lo != 0xFFFF)) {
1364
-			printf("PHY found at %hX %hX %hX %hX\n", phy,
1365
-			       control, hi, lo);
1364
+			printf("PHY found at %hX %hX %hX %hX\n", 
1365
+			       (unsigned int) phy, control, hi, lo);
1366 1366
 			if ((priv->phy[1] == TLAN_PHY_NONE)
1367 1367
 			    && (phy != TLAN_PHY_MAX_ADDR)) {
1368 1368
 				priv->phy[1] = phy;

+ 4
- 3
src/drivers/net/tulip.c Näytä tiedosto

@@ -1317,14 +1317,14 @@ static int tulip_probe ( struct nic *nic, struct pci_device *pci ) {
1317 1317
 
1318 1318
     if (inl(ioaddr + CSR5) == 0xFFFFFFFF) {
1319 1319
         printf("%s: The Tulip chip at %X is not functioning.\n",
1320
-               tp->nic_name, ioaddr);
1320
+               tp->nic_name, (unsigned int) ioaddr);
1321 1321
         return 0;
1322 1322
     }
1323 1323
    
1324 1324
     pci_read_config_byte(pci, PCI_REVISION, &chip_rev);
1325 1325
 
1326 1326
     printf("%s: [chip: %s] rev %d at %hX\n", tp->nic_name,
1327
-           tulip_tbl[chip_idx].chip_name, chip_rev, ioaddr);
1327
+           tulip_tbl[chip_idx].chip_name, chip_rev, (unsigned int) ioaddr);
1328 1328
     printf("%s: Vendor=%hX  Device=%hX", tp->nic_name, tp->vendor_id, tp->dev_id);
1329 1329
 
1330 1330
     if (chip_idx == DC21041  &&  inl(ioaddr + CSR9) & 0x8000) {
@@ -1404,7 +1404,8 @@ static int tulip_probe ( struct nic *nic, struct pci_device *pci ) {
1404 1404
     for (i = 0; i < ETH_ALEN; i++)
1405 1405
         last_phys_addr[i] = nic->node_addr[i];
1406 1406
 
1407
-    DBG ( "%s: %s at ioaddr %hX\n", tp->nic_name, eth_ntoa ( nic->node_addr ), ioaddr );
1407
+    DBG ( "%s: %s at ioaddr %hX\n", tp->nic_name, eth_ntoa ( nic->node_addr ), 
1408
+	  (unsigned int) ioaddr );
1408 1409
 
1409 1410
     tp->chip_id = chip_idx;
1410 1411
     tp->revision = chip_rev;

+ 4
- 4
src/drivers/net/via-rhine.c Näytä tiedosto

@@ -890,10 +890,10 @@ MIIDelay (void)
890 890
     int i;
891 891
     for (i = 0; i < 0x7fff; i++)
892 892
     {
893
-	inb (0x61);
894
-	inb (0x61);
895
-	inb (0x61);
896
-	inb (0x61);
893
+        ( void ) inb (0x61);
894
+        ( void ) inb (0x61);
895
+        ( void ) inb (0x61);
896
+        ( void ) inb (0x61);
897 897
     }
898 898
 }
899 899
 

+ 3
- 2
src/drivers/net/w89c840.c Näytä tiedosto

@@ -408,7 +408,7 @@ static int w89c840_poll(struct nic *nic, int retrieve)
408 408
                 if ((status & 0xffff) != 0x7fff) {
409 409
                     printf("winbond-840 : Oversized Ethernet frame spanned "
410 410
                            "multiple buffers, entry %d status %X !\n",
411
-                           w840private.cur_rx, status);
411
+                           w840private.cur_rx, (unsigned int) status);
412 412
                 }
413 413
             } else if (status & 0x8000) {
414 414
                 /* There was a fatal error. */
@@ -568,7 +568,8 @@ static void w89c840_transmit(
568 568
 
569 569
     /* Transmit timed out... */
570 570
 
571
-    printf("winbond-840 : transmission TIMEOUT : status %X\n", w840private.tx_ring[entry].status);
571
+    printf("winbond-840 : transmission TIMEOUT : status %X\n", 
572
+	   (unsigned int) w840private.tx_ring[entry].status);
572 573
 
573 574
     return;
574 575
 }

Loading…
Peruuta
Tallenna