aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ixgb
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ixgb')
-rw-r--r--drivers/net/ixgb/ixgb_main.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/drivers/net/ixgb/ixgb_main.c b/drivers/net/ixgb/ixgb_main.c
index 04cac41f7d5e..652c0eab3a4a 100644
--- a/drivers/net/ixgb/ixgb_main.c
+++ b/drivers/net/ixgb/ixgb_main.c
@@ -363,8 +363,6 @@ ixgb_probe(struct pci_dev *pdev,
363 struct net_device *netdev = NULL; 363 struct net_device *netdev = NULL;
364 struct ixgb_adapter *adapter; 364 struct ixgb_adapter *adapter;
365 static int cards_found = 0; 365 static int cards_found = 0;
366 unsigned long mmio_start;
367 int mmio_len;
368 int pci_using_dac; 366 int pci_using_dac;
369 int i; 367 int i;
370 int err; 368 int err;
@@ -405,11 +403,9 @@ ixgb_probe(struct pci_dev *pdev,
405 adapter->hw.back = adapter; 403 adapter->hw.back = adapter;
406 adapter->msg_enable = netif_msg_init(debug, DEFAULT_DEBUG_LEVEL_SHIFT); 404 adapter->msg_enable = netif_msg_init(debug, DEFAULT_DEBUG_LEVEL_SHIFT);
407 405
408 mmio_start = pci_resource_start(pdev, BAR_0); 406 adapter->hw.hw_addr = ioremap(pci_resource_start(pdev, BAR_0),
409 mmio_len = pci_resource_len(pdev, BAR_0); 407 pci_resource_len(pdev, BAR_0));
410 408 if (!adapter->hw.hw_addr) {
411 adapter->hw.hw_addr = ioremap(mmio_start, mmio_len);
412 if(!adapter->hw.hw_addr) {
413 err = -EIO; 409 err = -EIO;
414 goto err_ioremap; 410 goto err_ioremap;
415 } 411 }
@@ -444,9 +440,6 @@ ixgb_probe(struct pci_dev *pdev,
444#endif 440#endif
445 441
446 strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1); 442 strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1);
447 netdev->mem_start = mmio_start;
448 netdev->mem_end = mmio_start + mmio_len;
449 netdev->base_addr = adapter->hw.io_base;
450 443
451 adapter->bd_number = cards_found; 444 adapter->bd_number = cards_found;
452 adapter->link_speed = 0; 445 adapter->link_speed = 0;