Browse Source

Automatically updated using

perl -pi -0777 -e 's/(_probe\s*\(\s*struct\s+dev.*?)(\s*\)\s*{.*?$)\s*struct pci_device.*?=\s*pci_device \( dev \);$/${1}, struct pci_device *pci${2}/ms' *.c

sis900 excluded from update
tags/v0.9.3
Michael Brown 19 years ago
parent
commit
963dbefb51

+ 1
- 2
src/drivers/net/3c595.c View File

@@ -468,9 +468,8 @@ static void t595_irq(struct nic *nic __unused, irq_action_t action __unused)
468 468
 /**************************************************************************
469 469
 ETH_PROBE - Look for an adapter
470 470
 ***************************************************************************/
471
-static int t595_probe ( struct dev *dev ) {
471
+static int t595_probe ( struct dev *dev, struct pci_device *pci ) {
472 472
 	struct nic *nic = nic_device ( dev );
473
-	struct pci_device *pci = pci_device ( dev );
474 473
 	int i;
475 474
 	unsigned short *p;
476 475
 

+ 1
- 2
src/drivers/net/3c90x.c View File

@@ -690,9 +690,8 @@ static void a3c90x_irq(struct nic *nic __unused, irq_action_t action __unused)
690 690
  *** initialization.  If this routine is called, the pci functions did find the
691 691
  *** card.  We just have to init it here.
692 692
  ***/
693
-static int a3c90x_probe ( struct dev *dev ) {
693
+static int a3c90x_probe ( struct dev *dev, struct pci_device *pci ) {
694 694
     struct nic *nic = nic_device ( dev );
695
-    struct pci_device *pci = pci_device ( dev );
696 695
     int i, c;
697 696
     unsigned short eeprom[0x21];
698 697
     unsigned int cfg;

+ 1
- 2
src/drivers/net/davicom.c View File

@@ -178,7 +178,7 @@ static void davicom_media_chk(struct nic *);
178 178
 /*********************************************************************/
179 179
 /* Utility Routines                                                  */
180 180
 /*********************************************************************/
181
-static inline void whereami(const char *str)
181
+static inline void whereami(const char *str, struct pci_device *pci)
182 182
 {
183 183
   printf("%s\n", str);
184 184
   /* sleep(2); */
@@ -657,7 +657,6 @@ static void davicom_irq(struct nic *nic __unused, irq_action_t action __unused)
657 657
 /*********************************************************************/
658 658
 static int davicom_probe ( struct dev *dev ) {
659 659
   struct nic *nic = nic_device ( dev );
660
-  struct pci_device *pci = pci_device ( dev );
661 660
   unsigned int i;
662 661
 
663 662
   whereami("davicom_probe\n");

+ 1
- 2
src/drivers/net/dmfe.c View File

@@ -459,9 +459,8 @@ PROBE - Look for an adapter, this routine's visible to the outside
459 459
 
460 460
 #define board_found 1
461 461
 #define valid_link 0
462
-static int dmfe_probe ( struct dev *dev ) {
462
+static int dmfe_probe ( struct dev *dev, struct pci_device *pci ) {
463 463
 	struct nic *nic = nic_device ( dev );
464
-	struct pci_device *pci = pci_device ( dev );
465 464
 	uint32_t dev_rev, pci_pmr;
466 465
 	int i;
467 466
 

+ 1
- 2
src/drivers/net/e1000.c View File

@@ -3582,9 +3582,8 @@ static void e1000_irq(struct nic *nic __unused, irq_action_t action)
3582 3582
 PROBE - Look for an adapter, this routine's visible to the outside
3583 3583
 You should omit the last argument struct pci_device * for a non-PCI NIC
3584 3584
 ***************************************************************************/
3585
-static int e1000_probe ( struct dev *dev ) {
3585
+static int e1000_probe ( struct dev *dev, struct pci_device *pci ) {
3586 3586
 	struct nic *nic = nic_device ( dev );
3587
-	struct pci_device *p = pci_device ( dev );
3588 3587
 	unsigned long mmio_start, mmio_len;
3589 3588
 	int ret_val, i;
3590 3589
 

+ 1
- 2
src/drivers/net/eepro100.c View File

@@ -603,9 +603,8 @@ static void eepro100_disable ( struct nic *nic __unused ) {
603 603
  *            leaves the 82557 initialized, and ready to recieve packets.
604 604
  */
605 605
 
606
-static int eepro100_probe ( struct dev *dev ) {
606
+static int eepro100_probe ( struct dev *dev, struct pci_device *pci ) {
607 607
 	struct nic *nic = nic_device ( dev );
608
-	struct pci_device *p = pci_device ( dev );
609 608
 	unsigned short sum = 0;
610 609
 	int i;
611 610
 	int read_cmd, ee_size;

+ 1
- 2
src/drivers/net/epic100.c View File

@@ -99,9 +99,8 @@ static unsigned char		tx_packet[PKT_BUF_SZ * TX_RING_SIZE];
99 99
 
100 100
 
101 101
 static int
102
-epic100_probe ( struct dev *dev ) {
102
+epic100_probe ( struct dev *dev, struct pci_device *pci ) {
103 103
     struct nic *nic = nic_device ( dev );
104
-    struct pci_device *pci = pci_device ( dev );
105 104
     int i;
106 105
     unsigned short* ap;
107 106
     unsigned int phy, phy_idx;

+ 1
- 2
src/drivers/net/forcedeth.c View File

@@ -941,9 +941,8 @@ PROBE - Look for an adapter, this routine's visible to the outside
941 941
 #define IORESOURCE_MEM 0x00000200
942 942
 #define board_found 1
943 943
 #define valid_link 0
944
-static int forcedeth_probe ( struct dev *dev ) {
944
+static int forcedeth_probe ( struct dev *dev, struct pci_device *pci ) {
945 945
 	struct nic *nic = nic_device ( dev );
946
-	struct pci_device *pci = pci_device ( dev );
947 946
 	unsigned long addr;
948 947
 	int sz;
949 948
 	u8 *base;

+ 1
- 2
src/drivers/net/mtd80x.c View File

@@ -674,9 +674,8 @@ static struct pci_driver mtd80x_driver =
674 674
 PROBE - Look for an adapter, this routine's visible to the outside
675 675
 ***************************************************************************/
676 676
 
677
-static int mtd_probe ( struct dev *dev ) {
677
+static int mtd_probe ( struct dev *dev, struct pci_device *pci ) {
678 678
     struct nic *nic = nic_device ( dev );
679
-    struct pci_device *pci = pci_device ( dev );
680 679
     int i;
681 680
 
682 681
     if ( ! find_pci_device ( pci, &mtd80x_driver ) )

+ 1
- 3
src/drivers/net/natsemi.c View File

@@ -243,11 +243,9 @@ static void natsemi_irq(struct nic *nic, irq_action_t action);
243 243
  */
244 244
 
245 245
 static int
246
-natsemi_probe ( struct dev *dev ) {
246
+natsemi_probe ( struct dev *dev, struct pci_device *pci ) {
247 247
 
248 248
     struct nic *nic = nic_device ( dev );
249
-
250
-    struct pci_device *pci = pci_device ( dev );
251 249
     int i;
252 250
     int prev_eedata;
253 251
     u32 tmp;

+ 1
- 2
src/drivers/net/ns83820.c View File

@@ -825,9 +825,8 @@ PROBE - Look for an adapter, this routine's visible to the outside
825 825
 
826 826
 #define board_found 1
827 827
 #define valid_link 0
828
-static int ns83820_probe ( struct dev *dev ) {
828
+static int ns83820_probe ( struct dev *dev, struct pci_device *pci ) {
829 829
 	struct nic *nic = nic_device ( dev );
830
-	struct pci_device *pci = pci_device ( dev );
831 830
 	int sz;
832 831
 	long addr;
833 832
 	int using_dac = 0;

+ 1
- 2
src/drivers/net/pcnet32.c View File

@@ -666,9 +666,8 @@ static void pcnet32_irq(struct nic *nic __unused, irq_action_t action __unused)
666 666
 PROBE - Look for an adapter, this routine's visible to the outside
667 667
 You should omit the last argument struct pci_device * for a non-PCI NIC
668 668
 ***************************************************************************/
669
-static int pcnet32_probe ( struct dev *dev ) {
669
+static int pcnet32_probe ( struct dev *dev, struct pci_device *pci ) {
670 670
 	struct nic *nic = nic_device ( dev );
671
-	struct pci_device *pci = pci_device ( dev );
672 671
 	int i, media;
673 672
 	int fdx, mii, fset, dxsuflo, ltint;
674 673
 	int chip_version;

+ 1
- 2
src/drivers/net/prism2_pci.c View File

@@ -26,9 +26,8 @@ PCI_ROM(0x1260, 0x3873, "dwl520",	"DLink DWL-520"),
26 26
 static struct pci_driver prism2_pci_driver =
27 27
 	PCI_DRIVER ( "Prism2_PCI", prism2_pci_nics, PCI_NO_CLASS );
28 28
 
29
-static int prism2_pci_probe ( struct dev *dev ) {
29
+static int prism2_pci_probe ( struct dev *dev, struct pci_device *pci ) {
30 30
   struct nic *nic = nic_device ( dev );
31
-  struct pci_device *pci = pci_device ( dev );
32 31
   hfa384x_t *hw = &hw_global;
33 32
   uint32_t membase = 0; /* Prism2.5 Memory Base */
34 33
 

+ 1
- 2
src/drivers/net/prism2_plx.c View File

@@ -92,9 +92,8 @@ static int prism2_find_plx ( hfa384x_t *hw, struct pci_device *p )
92 92
   return found;
93 93
 }
94 94
 
95
-static int prism2_plx_probe ( struct dev *dev ) {
95
+static int prism2_plx_probe ( struct dev *dev, struct pci_device *pci ) {
96 96
   struct nic *nic = nic_device ( dev );
97
-  struct pci_device *pci = pci_device ( dev );
98 97
   hfa384x_t *hw = &hw_global;
99 98
 
100 99
   if ( ! find_pci_device ( pci, &prism2_plx_driver ) )

+ 1
- 2
src/drivers/net/r8169.c View File

@@ -723,9 +723,8 @@ PROBE - Look for an adapter, this routine's visible to the outside
723 723
 
724 724
 #define board_found 1
725 725
 #define valid_link 0
726
-static int r8169_probe ( struct dev *dev ) {
726
+static int r8169_probe ( struct dev *dev, struct pci_device *pci ) {
727 727
 	struct nic *nic = nic_device ( dev );
728
-	struct pci_device *pci = pci_device ( dev );
729 728
 	static int board_idx = -1;
730 729
 	static int printed_version = 0;
731 730
 	int i, rc;

+ 1
- 2
src/drivers/net/rtl8139.c View File

@@ -183,9 +183,8 @@ static void rtl_irq(struct nic *nic, irq_action_t action);
183 183
 static struct nic_operations rtl_operations;
184 184
 static struct pci_driver rtl8139_driver;
185 185
 
186
-static int rtl8139_probe ( struct dev *dev ) {
186
+static int rtl8139_probe ( struct dev *dev, struct pci_device *pci ) {
187 187
 	struct nic *nic = nic_device ( dev );
188
-	struct pci_device *pci = pci_device ( dev );
189 188
 	int i;
190 189
 	int speed10, fullduplex;
191 190
 	int addr_len;

+ 1
- 3
src/drivers/net/skel.c View File

@@ -133,12 +133,10 @@ PROBE - Look for an adapter, this routine's visible to the outside
133 133
 
134 134
 #define board_found 1
135 135
 #define valid_link 0
136
-static int skel_probe ( struct dev *dev ) {
136
+static int skel_probe ( struct dev *dev, struct pci_device *pci ) {
137 137
 
138 138
 	struct nic *nic = nic_device ( dev );
139 139
 
140
-	struct pci_device *pci = pci_device ( dev );
141
-
142 140
 	if (board_found && valid_link)
143 141
 	{
144 142
 		/* store NIC parameters */

+ 1
- 2
src/drivers/net/sundance.c View File

@@ -583,9 +583,8 @@ static struct pci_driver sundance_driver;
583 583
 /**************************************************************************
584 584
 PROBE - Look for an adapter, this routine's visible to the outside
585 585
 ***************************************************************************/
586
-static int sundance_probe ( struct dev *dev ) {
586
+static int sundance_probe ( struct dev *dev, struct pci_device *pci ) {
587 587
 	struct nic *nic = nic_device ( dev );
588
-	struct pci_device *pci = pci_device ( dev );
589 588
 	u8 ee_data[EEPROM_SIZE];
590 589
 	u16 mii_ctl;
591 590
 	int i;

+ 1
- 2
src/drivers/net/tg3.c View File

@@ -3264,9 +3264,8 @@ static struct pci_driver tg3_driver =
3264 3264
 PROBE - Look for an adapter, this routine's visible to the outside
3265 3265
 You should omit the last argument struct pci_device * for a non-PCI NIC
3266 3266
 ***************************************************************************/
3267
-static int tg3_probe ( struct dev *dev ) {
3267
+static int tg3_probe ( struct dev *dev, struct pci_device *pci ) {
3268 3268
 	struct nic *nic = nic_device ( dev );
3269
-	struct pci_device *pdev = pci_device ( dev );
3270 3269
 	struct tg3 *tp = &tg3;
3271 3270
 	unsigned long tg3reg_base, tg3reg_len;
3272 3271
 	int i, err, pm_cap;

+ 1
- 2
src/drivers/net/tlan.c View File

@@ -781,9 +781,8 @@ PROBE - Look for an adapter, this routine's visible to the outside
781 781
 
782 782
 #define board_found 1
783 783
 #define valid_link 0
784
-static int tlan_probe ( struct dev *dev ) {
784
+static int tlan_probe ( struct dev *dev, struct pci_device *pci ) {
785 785
 	struct nic *nic = nic_device ( dev );
786
-	struct pci_device *pci = pci_device ( dev );
787 786
 	u16 data = 0;
788 787
 	int err;
789 788
 	int i;

+ 1
- 2
src/drivers/net/tulip.c View File

@@ -516,7 +516,7 @@ static void tulip_more(void);
516 516
 /*********************************************************************/
517 517
 
518 518
 #ifdef TULIP_DEBUG_WHERE
519
-static void whereami (const char *str)
519
+static void whereami (const char *str, struct pci_device *pci)
520 520
 {
521 521
     printf("%s: %s\n", tp->nic_name, str);
522 522
     /* sleep(2); */
@@ -1227,7 +1227,6 @@ static struct pci_driver tulip_driver;
1227 1227
 /*********************************************************************/
1228 1228
 static int tulip_probe ( struct dev *dev ) {
1229 1229
     struct nic *nic = nic_device ( dev );
1230
-    struct pci_device *pci = pci_device ( dev );
1231 1230
     u32 i;
1232 1231
     u8  chip_rev;
1233 1232
     u8 ee_data[EEPROM_SIZE];

+ 1
- 2
src/drivers/net/via-rhine.c View File

@@ -954,9 +954,8 @@ static struct nic_operations rhine_operations;
954 954
 static struct pci_driver rhine_driver;
955 955
 
956 956
 static int
957
-rhine_probe ( struct dev *dev ) {
957
+rhine_probe ( struct dev *dev, struct pci_device *pci ) {
958 958
     struct nic *nic = nic_device ( dev );
959
-    struct pci_device *pci = pci_device ( dev );
960 959
     struct rhine_private *tp = (struct rhine_private *) nic->priv_data;
961 960
 
962 961
     if ( ! find_pci_device ( pci, &rhine_driver ) )

+ 1
- 2
src/drivers/net/w89c840.c View File

@@ -623,9 +623,8 @@ static struct pci_driver w89c840_driver =
623 623
 /**************************************************************************
624 624
 w89c840_probe - Look for an adapter, this routine's visible to the outside
625 625
 ***************************************************************************/
626
-static int w89c840_probe ( struct dev *dev ) {
626
+static int w89c840_probe ( struct dev *dev, struct pci_device *pci ) {
627 627
     struct nic *nic = nic_device ( dev );
628
-    struct pci_device *p = pci_device ( dev );
629 628
 
630 629
     if ( ! find_pci_device ( p, &w89c840_driver ) )
631 630
 	    return 0;

Loading…
Cancel
Save