diff options
Diffstat (limited to 'drivers/net/e1000/e1000_main.c')
-rw-r--r-- | drivers/net/e1000/e1000_main.c | 174 |
1 files changed, 87 insertions, 87 deletions
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c index 757d02f443a5..59579b1d8843 100644 --- a/drivers/net/e1000/e1000_main.c +++ b/drivers/net/e1000/e1000_main.c | |||
@@ -127,7 +127,7 @@ int e1000_up(struct e1000_adapter *adapter); | |||
127 | void e1000_down(struct e1000_adapter *adapter); | 127 | void e1000_down(struct e1000_adapter *adapter); |
128 | void e1000_reinit_locked(struct e1000_adapter *adapter); | 128 | void e1000_reinit_locked(struct e1000_adapter *adapter); |
129 | void e1000_reset(struct e1000_adapter *adapter); | 129 | void e1000_reset(struct e1000_adapter *adapter); |
130 | int e1000_set_spd_dplx(struct e1000_adapter *adapter, uint16_t spddplx); | 130 | int e1000_set_spd_dplx(struct e1000_adapter *adapter, u16 spddplx); |
131 | int e1000_setup_all_tx_resources(struct e1000_adapter *adapter); | 131 | int e1000_setup_all_tx_resources(struct e1000_adapter *adapter); |
132 | int e1000_setup_all_rx_resources(struct e1000_adapter *adapter); | 132 | int e1000_setup_all_rx_resources(struct e1000_adapter *adapter); |
133 | void e1000_free_all_tx_resources(struct e1000_adapter *adapter); | 133 | void e1000_free_all_tx_resources(struct e1000_adapter *adapter); |
@@ -203,8 +203,8 @@ static int e1000_82547_fifo_workaround(struct e1000_adapter *adapter, | |||
203 | struct sk_buff *skb); | 203 | struct sk_buff *skb); |
204 | 204 | ||
205 | static void e1000_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp); | 205 | static void e1000_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp); |
206 | static void e1000_vlan_rx_add_vid(struct net_device *netdev, uint16_t vid); | 206 | static void e1000_vlan_rx_add_vid(struct net_device *netdev, u16 vid); |
207 | static void e1000_vlan_rx_kill_vid(struct net_device *netdev, uint16_t vid); | 207 | static void e1000_vlan_rx_kill_vid(struct net_device *netdev, u16 vid); |
208 | static void e1000_restore_vlan(struct e1000_adapter *adapter); | 208 | static void e1000_restore_vlan(struct e1000_adapter *adapter); |
209 | 209 | ||
210 | static int e1000_suspend(struct pci_dev *pdev, pm_message_t state); | 210 | static int e1000_suspend(struct pci_dev *pdev, pm_message_t state); |
@@ -368,8 +368,8 @@ static void | |||
368 | e1000_update_mng_vlan(struct e1000_adapter *adapter) | 368 | e1000_update_mng_vlan(struct e1000_adapter *adapter) |
369 | { | 369 | { |
370 | struct net_device *netdev = adapter->netdev; | 370 | struct net_device *netdev = adapter->netdev; |
371 | uint16_t vid = adapter->hw.mng_cookie.vlan_id; | 371 | u16 vid = adapter->hw.mng_cookie.vlan_id; |
372 | uint16_t old_vid = adapter->mng_vlan_id; | 372 | u16 old_vid = adapter->mng_vlan_id; |
373 | if (adapter->vlgrp) { | 373 | if (adapter->vlgrp) { |
374 | if (!vlan_group_get_device(adapter->vlgrp, vid)) { | 374 | if (!vlan_group_get_device(adapter->vlgrp, vid)) { |
375 | if (adapter->hw.mng_cookie.status & | 375 | if (adapter->hw.mng_cookie.status & |
@@ -379,7 +379,7 @@ e1000_update_mng_vlan(struct e1000_adapter *adapter) | |||
379 | } else | 379 | } else |
380 | adapter->mng_vlan_id = E1000_MNG_VLAN_NONE; | 380 | adapter->mng_vlan_id = E1000_MNG_VLAN_NONE; |
381 | 381 | ||
382 | if ((old_vid != (uint16_t)E1000_MNG_VLAN_NONE) && | 382 | if ((old_vid != (u16)E1000_MNG_VLAN_NONE) && |
383 | (vid != old_vid) && | 383 | (vid != old_vid) && |
384 | !vlan_group_get_device(adapter->vlgrp, old_vid)) | 384 | !vlan_group_get_device(adapter->vlgrp, old_vid)) |
385 | e1000_vlan_rx_kill_vid(netdev, old_vid); | 385 | e1000_vlan_rx_kill_vid(netdev, old_vid); |
@@ -402,8 +402,8 @@ e1000_update_mng_vlan(struct e1000_adapter *adapter) | |||
402 | static void | 402 | static void |
403 | e1000_release_hw_control(struct e1000_adapter *adapter) | 403 | e1000_release_hw_control(struct e1000_adapter *adapter) |
404 | { | 404 | { |
405 | uint32_t ctrl_ext; | 405 | u32 ctrl_ext; |
406 | uint32_t swsm; | 406 | u32 swsm; |
407 | 407 | ||
408 | /* Let firmware taken over control of h/w */ | 408 | /* Let firmware taken over control of h/w */ |
409 | switch (adapter->hw.mac_type) { | 409 | switch (adapter->hw.mac_type) { |
@@ -439,8 +439,8 @@ e1000_release_hw_control(struct e1000_adapter *adapter) | |||
439 | static void | 439 | static void |
440 | e1000_get_hw_control(struct e1000_adapter *adapter) | 440 | e1000_get_hw_control(struct e1000_adapter *adapter) |
441 | { | 441 | { |
442 | uint32_t ctrl_ext; | 442 | u32 ctrl_ext; |
443 | uint32_t swsm; | 443 | u32 swsm; |
444 | 444 | ||
445 | /* Let firmware know the driver has taken over */ | 445 | /* Let firmware know the driver has taken over */ |
446 | switch (adapter->hw.mac_type) { | 446 | switch (adapter->hw.mac_type) { |
@@ -466,7 +466,7 @@ static void | |||
466 | e1000_init_manageability(struct e1000_adapter *adapter) | 466 | e1000_init_manageability(struct e1000_adapter *adapter) |
467 | { | 467 | { |
468 | if (adapter->en_mng_pt) { | 468 | if (adapter->en_mng_pt) { |
469 | uint32_t manc = E1000_READ_REG(&adapter->hw, MANC); | 469 | u32 manc = E1000_READ_REG(&adapter->hw, MANC); |
470 | 470 | ||
471 | /* disable hardware interception of ARP */ | 471 | /* disable hardware interception of ARP */ |
472 | manc &= ~(E1000_MANC_ARP_EN); | 472 | manc &= ~(E1000_MANC_ARP_EN); |
@@ -475,7 +475,7 @@ e1000_init_manageability(struct e1000_adapter *adapter) | |||
475 | /* this will probably generate destination unreachable messages | 475 | /* this will probably generate destination unreachable messages |
476 | * from the host OS, but the packets will be handled on SMBUS */ | 476 | * from the host OS, but the packets will be handled on SMBUS */ |
477 | if (adapter->hw.has_manc2h) { | 477 | if (adapter->hw.has_manc2h) { |
478 | uint32_t manc2h = E1000_READ_REG(&adapter->hw, MANC2H); | 478 | u32 manc2h = E1000_READ_REG(&adapter->hw, MANC2H); |
479 | 479 | ||
480 | manc |= E1000_MANC_EN_MNG2HOST; | 480 | manc |= E1000_MANC_EN_MNG2HOST; |
481 | #define E1000_MNG2HOST_PORT_623 (1 << 5) | 481 | #define E1000_MNG2HOST_PORT_623 (1 << 5) |
@@ -493,7 +493,7 @@ static void | |||
493 | e1000_release_manageability(struct e1000_adapter *adapter) | 493 | e1000_release_manageability(struct e1000_adapter *adapter) |
494 | { | 494 | { |
495 | if (adapter->en_mng_pt) { | 495 | if (adapter->en_mng_pt) { |
496 | uint32_t manc = E1000_READ_REG(&adapter->hw, MANC); | 496 | u32 manc = E1000_READ_REG(&adapter->hw, MANC); |
497 | 497 | ||
498 | /* re-enable hardware interception of ARP */ | 498 | /* re-enable hardware interception of ARP */ |
499 | manc |= E1000_MANC_ARP_EN; | 499 | manc |= E1000_MANC_ARP_EN; |
@@ -566,7 +566,7 @@ int e1000_up(struct e1000_adapter *adapter) | |||
566 | 566 | ||
567 | void e1000_power_up_phy(struct e1000_adapter *adapter) | 567 | void e1000_power_up_phy(struct e1000_adapter *adapter) |
568 | { | 568 | { |
569 | uint16_t mii_reg = 0; | 569 | u16 mii_reg = 0; |
570 | 570 | ||
571 | /* Just clear the power down bit to wake the phy back up */ | 571 | /* Just clear the power down bit to wake the phy back up */ |
572 | if (adapter->hw.media_type == e1000_media_type_copper) { | 572 | if (adapter->hw.media_type == e1000_media_type_copper) { |
@@ -587,7 +587,7 @@ static void e1000_power_down_phy(struct e1000_adapter *adapter) | |||
587 | * (c) SoL/IDER session is active */ | 587 | * (c) SoL/IDER session is active */ |
588 | if (!adapter->wol && adapter->hw.mac_type >= e1000_82540 && | 588 | if (!adapter->wol && adapter->hw.mac_type >= e1000_82540 && |
589 | adapter->hw.media_type == e1000_media_type_copper) { | 589 | adapter->hw.media_type == e1000_media_type_copper) { |
590 | uint16_t mii_reg = 0; | 590 | u16 mii_reg = 0; |
591 | 591 | ||
592 | switch (adapter->hw.mac_type) { | 592 | switch (adapter->hw.mac_type) { |
593 | case e1000_82540: | 593 | case e1000_82540: |
@@ -667,8 +667,8 @@ e1000_reinit_locked(struct e1000_adapter *adapter) | |||
667 | void | 667 | void |
668 | e1000_reset(struct e1000_adapter *adapter) | 668 | e1000_reset(struct e1000_adapter *adapter) |
669 | { | 669 | { |
670 | uint32_t pba = 0, tx_space, min_tx_space, min_rx_space; | 670 | u32 pba = 0, tx_space, min_tx_space, min_rx_space; |
671 | uint16_t fc_high_water_mark = E1000_FC_HIGH_DIFF; | 671 | u16 fc_high_water_mark = E1000_FC_HIGH_DIFF; |
672 | bool legacy_pba_adjust = false; | 672 | bool legacy_pba_adjust = false; |
673 | 673 | ||
674 | /* Repartition Pba for greater than 9k mtu | 674 | /* Repartition Pba for greater than 9k mtu |
@@ -815,7 +815,7 @@ e1000_reset(struct e1000_adapter *adapter) | |||
815 | adapter->hw.mac_type <= e1000_82547_rev_2 && | 815 | adapter->hw.mac_type <= e1000_82547_rev_2 && |
816 | adapter->hw.autoneg == 1 && | 816 | adapter->hw.autoneg == 1 && |
817 | adapter->hw.autoneg_advertised == ADVERTISE_1000_FULL) { | 817 | adapter->hw.autoneg_advertised == ADVERTISE_1000_FULL) { |
818 | uint32_t ctrl = E1000_READ_REG(&adapter->hw, CTRL); | 818 | u32 ctrl = E1000_READ_REG(&adapter->hw, CTRL); |
819 | /* clear phy power management bit if we are in gig only mode, | 819 | /* clear phy power management bit if we are in gig only mode, |
820 | * which if enabled will attempt negotiation to 100Mb, which | 820 | * which if enabled will attempt negotiation to 100Mb, which |
821 | * can cause a loss of link at power off or driver unload */ | 821 | * can cause a loss of link at power off or driver unload */ |
@@ -832,7 +832,7 @@ e1000_reset(struct e1000_adapter *adapter) | |||
832 | if (!adapter->smart_power_down && | 832 | if (!adapter->smart_power_down && |
833 | (adapter->hw.mac_type == e1000_82571 || | 833 | (adapter->hw.mac_type == e1000_82571 || |
834 | adapter->hw.mac_type == e1000_82572)) { | 834 | adapter->hw.mac_type == e1000_82572)) { |
835 | uint16_t phy_data = 0; | 835 | u16 phy_data = 0; |
836 | /* speed up time to link by disabling smart power down, ignore | 836 | /* speed up time to link by disabling smart power down, ignore |
837 | * the return value of this function because there is nothing | 837 | * the return value of this function because there is nothing |
838 | * different we would do if it failed */ | 838 | * different we would do if it failed */ |
@@ -926,8 +926,8 @@ e1000_probe(struct pci_dev *pdev, | |||
926 | static int cards_found = 0; | 926 | static int cards_found = 0; |
927 | static int global_quad_port_a = 0; /* global ksp3 port a indication */ | 927 | static int global_quad_port_a = 0; /* global ksp3 port a indication */ |
928 | int i, err, pci_using_dac; | 928 | int i, err, pci_using_dac; |
929 | uint16_t eeprom_data = 0; | 929 | u16 eeprom_data = 0; |
930 | uint16_t eeprom_apme_mask = E1000_EEPROM_APME; | 930 | u16 eeprom_apme_mask = E1000_EEPROM_APME; |
931 | DECLARE_MAC_BUF(mac); | 931 | DECLARE_MAC_BUF(mac); |
932 | 932 | ||
933 | if ((err = pci_enable_device(pdev))) | 933 | if ((err = pci_enable_device(pdev))) |
@@ -1702,10 +1702,10 @@ e1000_setup_all_tx_resources(struct e1000_adapter *adapter) | |||
1702 | static void | 1702 | static void |
1703 | e1000_configure_tx(struct e1000_adapter *adapter) | 1703 | e1000_configure_tx(struct e1000_adapter *adapter) |
1704 | { | 1704 | { |
1705 | uint64_t tdba; | 1705 | u64 tdba; |
1706 | struct e1000_hw *hw = &adapter->hw; | 1706 | struct e1000_hw *hw = &adapter->hw; |
1707 | uint32_t tdlen, tctl, tipg, tarc; | 1707 | u32 tdlen, tctl, tipg, tarc; |
1708 | uint32_t ipgr1, ipgr2; | 1708 | u32 ipgr1, ipgr2; |
1709 | 1709 | ||
1710 | /* Setup the HW Tx Head and Tail descriptor pointers */ | 1710 | /* Setup the HW Tx Head and Tail descriptor pointers */ |
1711 | 1711 | ||
@@ -1947,10 +1947,10 @@ e1000_setup_all_rx_resources(struct e1000_adapter *adapter) | |||
1947 | static void | 1947 | static void |
1948 | e1000_setup_rctl(struct e1000_adapter *adapter) | 1948 | e1000_setup_rctl(struct e1000_adapter *adapter) |
1949 | { | 1949 | { |
1950 | uint32_t rctl, rfctl; | 1950 | u32 rctl, rfctl; |
1951 | uint32_t psrctl = 0; | 1951 | u32 psrctl = 0; |
1952 | #ifndef CONFIG_E1000_DISABLE_PACKET_SPLIT | 1952 | #ifndef CONFIG_E1000_DISABLE_PACKET_SPLIT |
1953 | uint32_t pages = 0; | 1953 | u32 pages = 0; |
1954 | #endif | 1954 | #endif |
1955 | 1955 | ||
1956 | rctl = E1000_READ_REG(&adapter->hw, RCTL); | 1956 | rctl = E1000_READ_REG(&adapter->hw, RCTL); |
@@ -2065,9 +2065,9 @@ e1000_setup_rctl(struct e1000_adapter *adapter) | |||
2065 | static void | 2065 | static void |
2066 | e1000_configure_rx(struct e1000_adapter *adapter) | 2066 | e1000_configure_rx(struct e1000_adapter *adapter) |
2067 | { | 2067 | { |
2068 | uint64_t rdba; | 2068 | u64 rdba; |
2069 | struct e1000_hw *hw = &adapter->hw; | 2069 | struct e1000_hw *hw = &adapter->hw; |
2070 | uint32_t rdlen, rctl, rxcsum, ctrl_ext; | 2070 | u32 rdlen, rctl, rxcsum, ctrl_ext; |
2071 | 2071 | ||
2072 | if (adapter->rx_ps_pages) { | 2072 | if (adapter->rx_ps_pages) { |
2073 | /* this is a 32 byte descriptor */ | 2073 | /* this is a 32 byte descriptor */ |
@@ -2387,7 +2387,7 @@ static void | |||
2387 | e1000_enter_82542_rst(struct e1000_adapter *adapter) | 2387 | e1000_enter_82542_rst(struct e1000_adapter *adapter) |
2388 | { | 2388 | { |
2389 | struct net_device *netdev = adapter->netdev; | 2389 | struct net_device *netdev = adapter->netdev; |
2390 | uint32_t rctl; | 2390 | u32 rctl; |
2391 | 2391 | ||
2392 | e1000_pci_clear_mwi(&adapter->hw); | 2392 | e1000_pci_clear_mwi(&adapter->hw); |
2393 | 2393 | ||
@@ -2405,7 +2405,7 @@ static void | |||
2405 | e1000_leave_82542_rst(struct e1000_adapter *adapter) | 2405 | e1000_leave_82542_rst(struct e1000_adapter *adapter) |
2406 | { | 2406 | { |
2407 | struct net_device *netdev = adapter->netdev; | 2407 | struct net_device *netdev = adapter->netdev; |
2408 | uint32_t rctl; | 2408 | u32 rctl; |
2409 | 2409 | ||
2410 | rctl = E1000_READ_REG(&adapter->hw, RCTL); | 2410 | rctl = E1000_READ_REG(&adapter->hw, RCTL); |
2411 | rctl &= ~E1000_RCTL_RST; | 2411 | rctl &= ~E1000_RCTL_RST; |
@@ -2490,8 +2490,8 @@ e1000_set_rx_mode(struct net_device *netdev) | |||
2490 | struct e1000_hw *hw = &adapter->hw; | 2490 | struct e1000_hw *hw = &adapter->hw; |
2491 | struct dev_addr_list *uc_ptr; | 2491 | struct dev_addr_list *uc_ptr; |
2492 | struct dev_addr_list *mc_ptr; | 2492 | struct dev_addr_list *mc_ptr; |
2493 | uint32_t rctl; | 2493 | u32 rctl; |
2494 | uint32_t hash_value; | 2494 | u32 hash_value; |
2495 | int i, rar_entries = E1000_RAR_ENTRIES; | 2495 | int i, rar_entries = E1000_RAR_ENTRIES; |
2496 | int mta_reg_count = (hw->mac_type == e1000_ich8lan) ? | 2496 | int mta_reg_count = (hw->mac_type == e1000_ich8lan) ? |
2497 | E1000_NUM_MTA_REGISTERS_ICH8LAN : | 2497 | E1000_NUM_MTA_REGISTERS_ICH8LAN : |
@@ -2595,7 +2595,7 @@ e1000_82547_tx_fifo_stall(unsigned long data) | |||
2595 | { | 2595 | { |
2596 | struct e1000_adapter *adapter = (struct e1000_adapter *) data; | 2596 | struct e1000_adapter *adapter = (struct e1000_adapter *) data; |
2597 | struct net_device *netdev = adapter->netdev; | 2597 | struct net_device *netdev = adapter->netdev; |
2598 | uint32_t tctl; | 2598 | u32 tctl; |
2599 | 2599 | ||
2600 | if (atomic_read(&adapter->tx_fifo_stall)) { | 2600 | if (atomic_read(&adapter->tx_fifo_stall)) { |
2601 | if ((E1000_READ_REG(&adapter->hw, TDT) == | 2601 | if ((E1000_READ_REG(&adapter->hw, TDT) == |
@@ -2637,8 +2637,8 @@ e1000_watchdog(unsigned long data) | |||
2637 | struct e1000_adapter *adapter = (struct e1000_adapter *) data; | 2637 | struct e1000_adapter *adapter = (struct e1000_adapter *) data; |
2638 | struct net_device *netdev = adapter->netdev; | 2638 | struct net_device *netdev = adapter->netdev; |
2639 | struct e1000_tx_ring *txdr = adapter->tx_ring; | 2639 | struct e1000_tx_ring *txdr = adapter->tx_ring; |
2640 | uint32_t link, tctl; | 2640 | u32 link, tctl; |
2641 | int32_t ret_val; | 2641 | s32 ret_val; |
2642 | 2642 | ||
2643 | ret_val = e1000_check_for_link(&adapter->hw); | 2643 | ret_val = e1000_check_for_link(&adapter->hw); |
2644 | if ((ret_val == E1000_ERR_PHY) && | 2644 | if ((ret_val == E1000_ERR_PHY) && |
@@ -2663,7 +2663,7 @@ e1000_watchdog(unsigned long data) | |||
2663 | 2663 | ||
2664 | if (link) { | 2664 | if (link) { |
2665 | if (!netif_carrier_ok(netdev)) { | 2665 | if (!netif_carrier_ok(netdev)) { |
2666 | uint32_t ctrl; | 2666 | u32 ctrl; |
2667 | bool txb2b = true; | 2667 | bool txb2b = true; |
2668 | e1000_get_speed_and_duplex(&adapter->hw, | 2668 | e1000_get_speed_and_duplex(&adapter->hw, |
2669 | &adapter->link_speed, | 2669 | &adapter->link_speed, |
@@ -2700,7 +2700,7 @@ e1000_watchdog(unsigned long data) | |||
2700 | if ((adapter->hw.mac_type == e1000_82571 || | 2700 | if ((adapter->hw.mac_type == e1000_82571 || |
2701 | adapter->hw.mac_type == e1000_82572) && | 2701 | adapter->hw.mac_type == e1000_82572) && |
2702 | !txb2b) { | 2702 | !txb2b) { |
2703 | uint32_t tarc0; | 2703 | u32 tarc0; |
2704 | tarc0 = E1000_READ_REG(&adapter->hw, TARC0); | 2704 | tarc0 = E1000_READ_REG(&adapter->hw, TARC0); |
2705 | tarc0 &= ~(1 << 21); | 2705 | tarc0 &= ~(1 << 21); |
2706 | E1000_WRITE_REG(&adapter->hw, TARC0, tarc0); | 2706 | E1000_WRITE_REG(&adapter->hw, TARC0, tarc0); |
@@ -2742,7 +2742,7 @@ e1000_watchdog(unsigned long data) | |||
2742 | /* make sure the receive unit is started */ | 2742 | /* make sure the receive unit is started */ |
2743 | if (adapter->hw.rx_needs_kicking) { | 2743 | if (adapter->hw.rx_needs_kicking) { |
2744 | struct e1000_hw *hw = &adapter->hw; | 2744 | struct e1000_hw *hw = &adapter->hw; |
2745 | uint32_t rctl = E1000_READ_REG(hw, RCTL); | 2745 | u32 rctl = E1000_READ_REG(hw, RCTL); |
2746 | E1000_WRITE_REG(hw, RCTL, rctl | E1000_RCTL_EN); | 2746 | E1000_WRITE_REG(hw, RCTL, rctl | E1000_RCTL_EN); |
2747 | } | 2747 | } |
2748 | } | 2748 | } |
@@ -2832,7 +2832,7 @@ enum latency_range { | |||
2832 | * @bytes: the number of bytes during this measurement interval | 2832 | * @bytes: the number of bytes during this measurement interval |
2833 | **/ | 2833 | **/ |
2834 | static unsigned int e1000_update_itr(struct e1000_adapter *adapter, | 2834 | static unsigned int e1000_update_itr(struct e1000_adapter *adapter, |
2835 | uint16_t itr_setting, | 2835 | u16 itr_setting, |
2836 | int packets, | 2836 | int packets, |
2837 | int bytes) | 2837 | int bytes) |
2838 | { | 2838 | { |
@@ -2884,8 +2884,8 @@ update_itr_done: | |||
2884 | static void e1000_set_itr(struct e1000_adapter *adapter) | 2884 | static void e1000_set_itr(struct e1000_adapter *adapter) |
2885 | { | 2885 | { |
2886 | struct e1000_hw *hw = &adapter->hw; | 2886 | struct e1000_hw *hw = &adapter->hw; |
2887 | uint16_t current_itr; | 2887 | u16 current_itr; |
2888 | uint32_t new_itr = adapter->itr; | 2888 | u32 new_itr = adapter->itr; |
2889 | 2889 | ||
2890 | if (unlikely(hw->mac_type < e1000_82540)) | 2890 | if (unlikely(hw->mac_type < e1000_82540)) |
2891 | return; | 2891 | return; |
@@ -2959,9 +2959,9 @@ e1000_tso(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring, | |||
2959 | struct e1000_context_desc *context_desc; | 2959 | struct e1000_context_desc *context_desc; |
2960 | struct e1000_buffer *buffer_info; | 2960 | struct e1000_buffer *buffer_info; |
2961 | unsigned int i; | 2961 | unsigned int i; |
2962 | uint32_t cmd_length = 0; | 2962 | u32 cmd_length = 0; |
2963 | uint16_t ipcse = 0, tucse, mss; | 2963 | u16 ipcse = 0, tucse, mss; |
2964 | uint8_t ipcss, ipcso, tucss, tucso, hdr_len; | 2964 | u8 ipcss, ipcso, tucss, tucso, hdr_len; |
2965 | int err; | 2965 | int err; |
2966 | 2966 | ||
2967 | if (skb_is_gso(skb)) { | 2967 | if (skb_is_gso(skb)) { |
@@ -3032,7 +3032,7 @@ e1000_tx_csum(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring, | |||
3032 | struct e1000_context_desc *context_desc; | 3032 | struct e1000_context_desc *context_desc; |
3033 | struct e1000_buffer *buffer_info; | 3033 | struct e1000_buffer *buffer_info; |
3034 | unsigned int i; | 3034 | unsigned int i; |
3035 | uint8_t css; | 3035 | u8 css; |
3036 | 3036 | ||
3037 | if (likely(skb->ip_summed == CHECKSUM_PARTIAL)) { | 3037 | if (likely(skb->ip_summed == CHECKSUM_PARTIAL)) { |
3038 | css = skb_transport_offset(skb); | 3038 | css = skb_transport_offset(skb); |
@@ -3177,7 +3177,7 @@ e1000_tx_queue(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring, | |||
3177 | { | 3177 | { |
3178 | struct e1000_tx_desc *tx_desc = NULL; | 3178 | struct e1000_tx_desc *tx_desc = NULL; |
3179 | struct e1000_buffer *buffer_info; | 3179 | struct e1000_buffer *buffer_info; |
3180 | uint32_t txd_upper = 0, txd_lower = E1000_TXD_CMD_IFCS; | 3180 | u32 txd_upper = 0, txd_lower = E1000_TXD_CMD_IFCS; |
3181 | unsigned int i; | 3181 | unsigned int i; |
3182 | 3182 | ||
3183 | if (likely(tx_flags & E1000_TX_FLAGS_TSO)) { | 3183 | if (likely(tx_flags & E1000_TX_FLAGS_TSO)) { |
@@ -3241,8 +3241,8 @@ e1000_tx_queue(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring, | |||
3241 | static int | 3241 | static int |
3242 | e1000_82547_fifo_workaround(struct e1000_adapter *adapter, struct sk_buff *skb) | 3242 | e1000_82547_fifo_workaround(struct e1000_adapter *adapter, struct sk_buff *skb) |
3243 | { | 3243 | { |
3244 | uint32_t fifo_space = adapter->tx_fifo_size - adapter->tx_fifo_head; | 3244 | u32 fifo_space = adapter->tx_fifo_size - adapter->tx_fifo_head; |
3245 | uint32_t skb_fifo_len = skb->len + E1000_FIFO_HDR; | 3245 | u32 skb_fifo_len = skb->len + E1000_FIFO_HDR; |
3246 | 3246 | ||
3247 | skb_fifo_len = ALIGN(skb_fifo_len, E1000_FIFO_HDR); | 3247 | skb_fifo_len = ALIGN(skb_fifo_len, E1000_FIFO_HDR); |
3248 | 3248 | ||
@@ -3269,7 +3269,7 @@ static int | |||
3269 | e1000_transfer_dhcp_info(struct e1000_adapter *adapter, struct sk_buff *skb) | 3269 | e1000_transfer_dhcp_info(struct e1000_adapter *adapter, struct sk_buff *skb) |
3270 | { | 3270 | { |
3271 | struct e1000_hw *hw = &adapter->hw; | 3271 | struct e1000_hw *hw = &adapter->hw; |
3272 | uint16_t length, offset; | 3272 | u16 length, offset; |
3273 | if (vlan_tx_tag_present(skb)) { | 3273 | if (vlan_tx_tag_present(skb)) { |
3274 | if (!((vlan_tx_tag_get(skb) == adapter->hw.mng_cookie.vlan_id) && | 3274 | if (!((vlan_tx_tag_get(skb) == adapter->hw.mng_cookie.vlan_id) && |
3275 | ( adapter->hw.mng_cookie.status & | 3275 | ( adapter->hw.mng_cookie.status & |
@@ -3280,17 +3280,17 @@ e1000_transfer_dhcp_info(struct e1000_adapter *adapter, struct sk_buff *skb) | |||
3280 | struct ethhdr *eth = (struct ethhdr *) skb->data; | 3280 | struct ethhdr *eth = (struct ethhdr *) skb->data; |
3281 | if ((htons(ETH_P_IP) == eth->h_proto)) { | 3281 | if ((htons(ETH_P_IP) == eth->h_proto)) { |
3282 | const struct iphdr *ip = | 3282 | const struct iphdr *ip = |
3283 | (struct iphdr *)((uint8_t *)skb->data+14); | 3283 | (struct iphdr *)((u8 *)skb->data+14); |
3284 | if (IPPROTO_UDP == ip->protocol) { | 3284 | if (IPPROTO_UDP == ip->protocol) { |
3285 | struct udphdr *udp = | 3285 | struct udphdr *udp = |
3286 | (struct udphdr *)((uint8_t *)ip + | 3286 | (struct udphdr *)((u8 *)ip + |
3287 | (ip->ihl << 2)); | 3287 | (ip->ihl << 2)); |
3288 | if (ntohs(udp->dest) == 67) { | 3288 | if (ntohs(udp->dest) == 67) { |
3289 | offset = (uint8_t *)udp + 8 - skb->data; | 3289 | offset = (u8 *)udp + 8 - skb->data; |
3290 | length = skb->len - offset; | 3290 | length = skb->len - offset; |
3291 | 3291 | ||
3292 | return e1000_mng_write_dhcp_info(hw, | 3292 | return e1000_mng_write_dhcp_info(hw, |
3293 | (uint8_t *)udp + 8, | 3293 | (u8 *)udp + 8, |
3294 | length); | 3294 | length); |
3295 | } | 3295 | } |
3296 | } | 3296 | } |
@@ -3370,7 +3370,7 @@ e1000_xmit_frame(struct sk_buff *skb, struct net_device *netdev) | |||
3370 | * overrun the FIFO, adjust the max buffer len if mss | 3370 | * overrun the FIFO, adjust the max buffer len if mss |
3371 | * drops. */ | 3371 | * drops. */ |
3372 | if (mss) { | 3372 | if (mss) { |
3373 | uint8_t hdr_len; | 3373 | u8 hdr_len; |
3374 | max_per_txd = min(mss << 2, max_per_txd); | 3374 | max_per_txd = min(mss << 2, max_per_txd); |
3375 | max_txd_pwr = fls(max_per_txd) - 1; | 3375 | max_txd_pwr = fls(max_per_txd) - 1; |
3376 | 3376 | ||
@@ -3557,7 +3557,7 @@ e1000_change_mtu(struct net_device *netdev, int new_mtu) | |||
3557 | { | 3557 | { |
3558 | struct e1000_adapter *adapter = netdev_priv(netdev); | 3558 | struct e1000_adapter *adapter = netdev_priv(netdev); |
3559 | int max_frame = new_mtu + ENET_HEADER_SIZE + ETHERNET_FCS_SIZE; | 3559 | int max_frame = new_mtu + ENET_HEADER_SIZE + ETHERNET_FCS_SIZE; |
3560 | uint16_t eeprom_data = 0; | 3560 | u16 eeprom_data = 0; |
3561 | 3561 | ||
3562 | if ((max_frame < MINIMUM_ETHERNET_FRAME_SIZE) || | 3562 | if ((max_frame < MINIMUM_ETHERNET_FRAME_SIZE) || |
3563 | (max_frame > MAX_JUMBO_FRAME_SIZE)) { | 3563 | (max_frame > MAX_JUMBO_FRAME_SIZE)) { |
@@ -3652,7 +3652,7 @@ e1000_update_stats(struct e1000_adapter *adapter) | |||
3652 | struct e1000_hw *hw = &adapter->hw; | 3652 | struct e1000_hw *hw = &adapter->hw; |
3653 | struct pci_dev *pdev = adapter->pdev; | 3653 | struct pci_dev *pdev = adapter->pdev; |
3654 | unsigned long flags; | 3654 | unsigned long flags; |
3655 | uint16_t phy_tmp; | 3655 | u16 phy_tmp; |
3656 | 3656 | ||
3657 | #define PHY_IDLE_ERROR_COUNT_MASK 0x00FF | 3657 | #define PHY_IDLE_ERROR_COUNT_MASK 0x00FF |
3658 | 3658 | ||
@@ -3829,7 +3829,7 @@ e1000_intr_msi(int irq, void *data) | |||
3829 | #ifndef CONFIG_E1000_NAPI | 3829 | #ifndef CONFIG_E1000_NAPI |
3830 | int i; | 3830 | int i; |
3831 | #endif | 3831 | #endif |
3832 | uint32_t icr = E1000_READ_REG(hw, ICR); | 3832 | u32 icr = E1000_READ_REG(hw, ICR); |
3833 | 3833 | ||
3834 | /* in NAPI mode read ICR disables interrupts using IAM */ | 3834 | /* in NAPI mode read ICR disables interrupts using IAM */ |
3835 | 3835 | ||
@@ -3841,7 +3841,7 @@ e1000_intr_msi(int irq, void *data) | |||
3841 | if (netif_carrier_ok(netdev) && | 3841 | if (netif_carrier_ok(netdev) && |
3842 | (adapter->hw.mac_type == e1000_80003es2lan)) { | 3842 | (adapter->hw.mac_type == e1000_80003es2lan)) { |
3843 | /* disable receives */ | 3843 | /* disable receives */ |
3844 | uint32_t rctl = E1000_READ_REG(hw, RCTL); | 3844 | u32 rctl = E1000_READ_REG(hw, RCTL); |
3845 | E1000_WRITE_REG(hw, RCTL, rctl & ~E1000_RCTL_EN); | 3845 | E1000_WRITE_REG(hw, RCTL, rctl & ~E1000_RCTL_EN); |
3846 | } | 3846 | } |
3847 | /* guard against interrupt when we're going down */ | 3847 | /* guard against interrupt when we're going down */ |
@@ -3888,7 +3888,7 @@ e1000_intr(int irq, void *data) | |||
3888 | struct net_device *netdev = data; | 3888 | struct net_device *netdev = data; |
3889 | struct e1000_adapter *adapter = netdev_priv(netdev); | 3889 | struct e1000_adapter *adapter = netdev_priv(netdev); |
3890 | struct e1000_hw *hw = &adapter->hw; | 3890 | struct e1000_hw *hw = &adapter->hw; |
3891 | uint32_t rctl, icr = E1000_READ_REG(hw, ICR); | 3891 | u32 rctl, icr = E1000_READ_REG(hw, ICR); |
3892 | #ifndef CONFIG_E1000_NAPI | 3892 | #ifndef CONFIG_E1000_NAPI |
3893 | int i; | 3893 | int i; |
3894 | #endif | 3894 | #endif |
@@ -4139,11 +4139,11 @@ e1000_clean_tx_irq(struct e1000_adapter *adapter, | |||
4139 | 4139 | ||
4140 | static void | 4140 | static void |
4141 | e1000_rx_checksum(struct e1000_adapter *adapter, | 4141 | e1000_rx_checksum(struct e1000_adapter *adapter, |
4142 | uint32_t status_err, uint32_t csum, | 4142 | u32 status_err, u32 csum, |
4143 | struct sk_buff *skb) | 4143 | struct sk_buff *skb) |
4144 | { | 4144 | { |
4145 | uint16_t status = (uint16_t)status_err; | 4145 | u16 status = (u16)status_err; |
4146 | uint8_t errors = (uint8_t)(status_err >> 24); | 4146 | u8 errors = (u8)(status_err >> 24); |
4147 | skb->ip_summed = CHECKSUM_NONE; | 4147 | skb->ip_summed = CHECKSUM_NONE; |
4148 | 4148 | ||
4149 | /* 82543 or newer only */ | 4149 | /* 82543 or newer only */ |
@@ -4200,8 +4200,8 @@ e1000_clean_rx_irq(struct e1000_adapter *adapter, | |||
4200 | struct e1000_rx_desc *rx_desc, *next_rxd; | 4200 | struct e1000_rx_desc *rx_desc, *next_rxd; |
4201 | struct e1000_buffer *buffer_info, *next_buffer; | 4201 | struct e1000_buffer *buffer_info, *next_buffer; |
4202 | unsigned long flags; | 4202 | unsigned long flags; |
4203 | uint32_t length; | 4203 | u32 length; |
4204 | uint8_t last_byte; | 4204 | u8 last_byte; |
4205 | unsigned int i; | 4205 | unsigned int i; |
4206 | int cleaned_count = 0; | 4206 | int cleaned_count = 0; |
4207 | bool cleaned = false; | 4207 | bool cleaned = false; |
@@ -4301,8 +4301,8 @@ e1000_clean_rx_irq(struct e1000_adapter *adapter, | |||
4301 | 4301 | ||
4302 | /* Receive Checksum Offload */ | 4302 | /* Receive Checksum Offload */ |
4303 | e1000_rx_checksum(adapter, | 4303 | e1000_rx_checksum(adapter, |
4304 | (uint32_t)(status) | | 4304 | (u32)(status) | |
4305 | ((uint32_t)(rx_desc->errors) << 24), | 4305 | ((u32)(rx_desc->errors) << 24), |
4306 | le16_to_cpu(rx_desc->csum), skb); | 4306 | le16_to_cpu(rx_desc->csum), skb); |
4307 | 4307 | ||
4308 | skb->protocol = eth_type_trans(skb, netdev); | 4308 | skb->protocol = eth_type_trans(skb, netdev); |
@@ -4376,7 +4376,7 @@ e1000_clean_rx_irq_ps(struct e1000_adapter *adapter, | |||
4376 | struct e1000_ps_page_dma *ps_page_dma; | 4376 | struct e1000_ps_page_dma *ps_page_dma; |
4377 | struct sk_buff *skb; | 4377 | struct sk_buff *skb; |
4378 | unsigned int i, j; | 4378 | unsigned int i, j; |
4379 | uint32_t length, staterr; | 4379 | u32 length, staterr; |
4380 | int cleaned_count = 0; | 4380 | int cleaned_count = 0; |
4381 | bool cleaned = false; | 4381 | bool cleaned = false; |
4382 | unsigned int total_rx_bytes=0, total_rx_packets=0; | 4382 | unsigned int total_rx_bytes=0, total_rx_packets=0; |
@@ -4759,8 +4759,8 @@ no_buffers: | |||
4759 | static void | 4759 | static void |
4760 | e1000_smartspeed(struct e1000_adapter *adapter) | 4760 | e1000_smartspeed(struct e1000_adapter *adapter) |
4761 | { | 4761 | { |
4762 | uint16_t phy_status; | 4762 | u16 phy_status; |
4763 | uint16_t phy_ctrl; | 4763 | u16 phy_ctrl; |
4764 | 4764 | ||
4765 | if ((adapter->hw.phy_type != e1000_phy_igp) || !adapter->hw.autoneg || | 4765 | if ((adapter->hw.phy_type != e1000_phy_igp) || !adapter->hw.autoneg || |
4766 | !(adapter->hw.autoneg_advertised & ADVERTISE_1000_FULL)) | 4766 | !(adapter->hw.autoneg_advertised & ADVERTISE_1000_FULL)) |
@@ -4839,8 +4839,8 @@ e1000_mii_ioctl(struct net_device *netdev, struct ifreq *ifr, int cmd) | |||
4839 | struct e1000_adapter *adapter = netdev_priv(netdev); | 4839 | struct e1000_adapter *adapter = netdev_priv(netdev); |
4840 | struct mii_ioctl_data *data = if_mii(ifr); | 4840 | struct mii_ioctl_data *data = if_mii(ifr); |
4841 | int retval; | 4841 | int retval; |
4842 | uint16_t mii_reg; | 4842 | u16 mii_reg; |
4843 | uint16_t spddplx; | 4843 | u16 spddplx; |
4844 | unsigned long flags; | 4844 | unsigned long flags; |
4845 | 4845 | ||
4846 | if (adapter->hw.media_type != e1000_media_type_copper) | 4846 | if (adapter->hw.media_type != e1000_media_type_copper) |
@@ -4959,11 +4959,11 @@ e1000_pcix_set_mmrbc(struct e1000_hw *hw, int mmrbc) | |||
4959 | pcix_set_mmrbc(adapter->pdev, mmrbc); | 4959 | pcix_set_mmrbc(adapter->pdev, mmrbc); |
4960 | } | 4960 | } |
4961 | 4961 | ||
4962 | int32_t | 4962 | s32 |
4963 | e1000_read_pcie_cap_reg(struct e1000_hw *hw, uint32_t reg, uint16_t *value) | 4963 | e1000_read_pcie_cap_reg(struct e1000_hw *hw, u32 reg, u16 *value) |
4964 | { | 4964 | { |
4965 | struct e1000_adapter *adapter = hw->back; | 4965 | struct e1000_adapter *adapter = hw->back; |
4966 | uint16_t cap_offset; | 4966 | u16 cap_offset; |
4967 | 4967 | ||
4968 | cap_offset = pci_find_capability(adapter->pdev, PCI_CAP_ID_EXP); | 4968 | cap_offset = pci_find_capability(adapter->pdev, PCI_CAP_ID_EXP); |
4969 | if (!cap_offset) | 4969 | if (!cap_offset) |
@@ -4975,7 +4975,7 @@ e1000_read_pcie_cap_reg(struct e1000_hw *hw, uint32_t reg, uint16_t *value) | |||
4975 | } | 4975 | } |
4976 | 4976 | ||
4977 | void | 4977 | void |
4978 | e1000_io_write(struct e1000_hw *hw, unsigned long port, uint32_t value) | 4978 | e1000_io_write(struct e1000_hw *hw, unsigned long port, u32 value) |
4979 | { | 4979 | { |
4980 | outl(value, port); | 4980 | outl(value, port); |
4981 | } | 4981 | } |
@@ -4984,7 +4984,7 @@ static void | |||
4984 | e1000_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp) | 4984 | e1000_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp) |
4985 | { | 4985 | { |
4986 | struct e1000_adapter *adapter = netdev_priv(netdev); | 4986 | struct e1000_adapter *adapter = netdev_priv(netdev); |
4987 | uint32_t ctrl, rctl; | 4987 | u32 ctrl, rctl; |
4988 | 4988 | ||
4989 | if (!test_bit(__E1000_DOWN, &adapter->flags)) | 4989 | if (!test_bit(__E1000_DOWN, &adapter->flags)) |
4990 | e1000_irq_disable(adapter); | 4990 | e1000_irq_disable(adapter); |
@@ -5016,7 +5016,7 @@ e1000_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp) | |||
5016 | rctl &= ~E1000_RCTL_VFE; | 5016 | rctl &= ~E1000_RCTL_VFE; |
5017 | E1000_WRITE_REG(&adapter->hw, RCTL, rctl); | 5017 | E1000_WRITE_REG(&adapter->hw, RCTL, rctl); |
5018 | if (adapter->mng_vlan_id != | 5018 | if (adapter->mng_vlan_id != |
5019 | (uint16_t)E1000_MNG_VLAN_NONE) { | 5019 | (u16)E1000_MNG_VLAN_NONE) { |
5020 | e1000_vlan_rx_kill_vid(netdev, | 5020 | e1000_vlan_rx_kill_vid(netdev, |
5021 | adapter->mng_vlan_id); | 5021 | adapter->mng_vlan_id); |
5022 | adapter->mng_vlan_id = E1000_MNG_VLAN_NONE; | 5022 | adapter->mng_vlan_id = E1000_MNG_VLAN_NONE; |
@@ -5029,10 +5029,10 @@ e1000_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp) | |||
5029 | } | 5029 | } |
5030 | 5030 | ||
5031 | static void | 5031 | static void |
5032 | e1000_vlan_rx_add_vid(struct net_device *netdev, uint16_t vid) | 5032 | e1000_vlan_rx_add_vid(struct net_device *netdev, u16 vid) |
5033 | { | 5033 | { |
5034 | struct e1000_adapter *adapter = netdev_priv(netdev); | 5034 | struct e1000_adapter *adapter = netdev_priv(netdev); |
5035 | uint32_t vfta, index; | 5035 | u32 vfta, index; |
5036 | 5036 | ||
5037 | if ((adapter->hw.mng_cookie.status & | 5037 | if ((adapter->hw.mng_cookie.status & |
5038 | E1000_MNG_DHCP_COOKIE_STATUS_VLAN_SUPPORT) && | 5038 | E1000_MNG_DHCP_COOKIE_STATUS_VLAN_SUPPORT) && |
@@ -5046,10 +5046,10 @@ e1000_vlan_rx_add_vid(struct net_device *netdev, uint16_t vid) | |||
5046 | } | 5046 | } |
5047 | 5047 | ||
5048 | static void | 5048 | static void |
5049 | e1000_vlan_rx_kill_vid(struct net_device *netdev, uint16_t vid) | 5049 | e1000_vlan_rx_kill_vid(struct net_device *netdev, u16 vid) |
5050 | { | 5050 | { |
5051 | struct e1000_adapter *adapter = netdev_priv(netdev); | 5051 | struct e1000_adapter *adapter = netdev_priv(netdev); |
5052 | uint32_t vfta, index; | 5052 | u32 vfta, index; |
5053 | 5053 | ||
5054 | if (!test_bit(__E1000_DOWN, &adapter->flags)) | 5054 | if (!test_bit(__E1000_DOWN, &adapter->flags)) |
5055 | e1000_irq_disable(adapter); | 5055 | e1000_irq_disable(adapter); |
@@ -5078,7 +5078,7 @@ e1000_restore_vlan(struct e1000_adapter *adapter) | |||
5078 | e1000_vlan_rx_register(adapter->netdev, adapter->vlgrp); | 5078 | e1000_vlan_rx_register(adapter->netdev, adapter->vlgrp); |
5079 | 5079 | ||
5080 | if (adapter->vlgrp) { | 5080 | if (adapter->vlgrp) { |
5081 | uint16_t vid; | 5081 | u16 vid; |
5082 | for (vid = 0; vid < VLAN_GROUP_ARRAY_LEN; vid++) { | 5082 | for (vid = 0; vid < VLAN_GROUP_ARRAY_LEN; vid++) { |
5083 | if (!vlan_group_get_device(adapter->vlgrp, vid)) | 5083 | if (!vlan_group_get_device(adapter->vlgrp, vid)) |
5084 | continue; | 5084 | continue; |
@@ -5088,7 +5088,7 @@ e1000_restore_vlan(struct e1000_adapter *adapter) | |||
5088 | } | 5088 | } |
5089 | 5089 | ||
5090 | int | 5090 | int |
5091 | e1000_set_spd_dplx(struct e1000_adapter *adapter, uint16_t spddplx) | 5091 | e1000_set_spd_dplx(struct e1000_adapter *adapter, u16 spddplx) |
5092 | { | 5092 | { |
5093 | adapter->hw.autoneg = 0; | 5093 | adapter->hw.autoneg = 0; |
5094 | 5094 | ||
@@ -5129,8 +5129,8 @@ e1000_suspend(struct pci_dev *pdev, pm_message_t state) | |||
5129 | { | 5129 | { |
5130 | struct net_device *netdev = pci_get_drvdata(pdev); | 5130 | struct net_device *netdev = pci_get_drvdata(pdev); |
5131 | struct e1000_adapter *adapter = netdev_priv(netdev); | 5131 | struct e1000_adapter *adapter = netdev_priv(netdev); |
5132 | uint32_t ctrl, ctrl_ext, rctl, status; | 5132 | u32 ctrl, ctrl_ext, rctl, status; |
5133 | uint32_t wufc = adapter->wol; | 5133 | u32 wufc = adapter->wol; |
5134 | #ifdef CONFIG_PM | 5134 | #ifdef CONFIG_PM |
5135 | int retval = 0; | 5135 | int retval = 0; |
5136 | #endif | 5136 | #endif |
@@ -5227,7 +5227,7 @@ e1000_resume(struct pci_dev *pdev) | |||
5227 | { | 5227 | { |
5228 | struct net_device *netdev = pci_get_drvdata(pdev); | 5228 | struct net_device *netdev = pci_get_drvdata(pdev); |
5229 | struct e1000_adapter *adapter = netdev_priv(netdev); | 5229 | struct e1000_adapter *adapter = netdev_priv(netdev); |
5230 | uint32_t err; | 5230 | u32 err; |
5231 | 5231 | ||
5232 | pci_set_power_state(pdev, PCI_D0); | 5232 | pci_set_power_state(pdev, PCI_D0); |
5233 | pci_restore_state(pdev); | 5233 | pci_restore_state(pdev); |