e1000_82543.c (287990) | e1000_82543.c (295323) |
---|---|
1/****************************************************************************** 2 3 Copyright (c) 2001-2015, Intel Corporation 4 All rights reserved. 5 6 Redistribution and use in source and binary forms, with or without 7 modification, are permitted provided that the following conditions are met: 8 --- 16 unchanged lines hidden (view full) --- 25 CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 26 SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 27 INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 28 CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 29 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 30 POSSIBILITY OF SUCH DAMAGE. 31 32******************************************************************************/ | 1/****************************************************************************** 2 3 Copyright (c) 2001-2015, Intel Corporation 4 All rights reserved. 5 6 Redistribution and use in source and binary forms, with or without 7 modification, are permitted provided that the following conditions are met: 8 --- 16 unchanged lines hidden (view full) --- 25 CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 26 SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 27 INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 28 CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 29 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 30 POSSIBILITY OF SUCH DAMAGE. 31 32******************************************************************************/ |
33/*$FreeBSD: head/sys/dev/e1000/e1000_82543.c 287990 2015-09-19 18:22:59Z sbruno $*/ | 33/*$FreeBSD: head/sys/dev/e1000/e1000_82543.c 295323 2016-02-05 17:14:37Z erj $*/ |
34 35/* 36 * 82543GC Gigabit Ethernet Controller (Fiber) 37 * 82543GC Gigabit Ethernet Controller (Copper) 38 * 82544EI Gigabit Ethernet Controller (Copper) 39 * 82544EI Gigabit Ethernet Controller (Fiber) 40 * 82544GC Gigabit Ethernet Controller (Copper) 41 * 82544GC Gigabit Ethernet Controller (LOM) --- 853 unchanged lines hidden (view full) --- 895/** 896 * e1000_reset_hw_82543 - Reset hardware 897 * @hw: pointer to the HW structure 898 * 899 * This resets the hardware into a known state. 900 **/ 901static s32 e1000_reset_hw_82543(struct e1000_hw *hw) 902{ | 34 35/* 36 * 82543GC Gigabit Ethernet Controller (Fiber) 37 * 82543GC Gigabit Ethernet Controller (Copper) 38 * 82544EI Gigabit Ethernet Controller (Copper) 39 * 82544EI Gigabit Ethernet Controller (Fiber) 40 * 82544GC Gigabit Ethernet Controller (Copper) 41 * 82544GC Gigabit Ethernet Controller (LOM) --- 853 unchanged lines hidden (view full) --- 895/** 896 * e1000_reset_hw_82543 - Reset hardware 897 * @hw: pointer to the HW structure 898 * 899 * This resets the hardware into a known state. 900 **/ 901static s32 e1000_reset_hw_82543(struct e1000_hw *hw) 902{ |
903 u32 ctrl, icr; | 903 u32 ctrl; |
904 s32 ret_val = E1000_SUCCESS; 905 906 DEBUGFUNC("e1000_reset_hw_82543"); 907 908 DEBUGOUT("Masking off all interrupts\n"); 909 E1000_WRITE_REG(hw, E1000_IMC, 0xffffffff); 910 911 E1000_WRITE_REG(hw, E1000_RCTL, 0); --- 25 unchanged lines hidden (view full) --- 937 * After MAC reset, force reload of NVM to restore power-on 938 * settings to device. 939 */ 940 hw->nvm.ops.reload(hw); 941 msec_delay(2); 942 943 /* Masking off and clearing any pending interrupts */ 944 E1000_WRITE_REG(hw, E1000_IMC, 0xffffffff); | 904 s32 ret_val = E1000_SUCCESS; 905 906 DEBUGFUNC("e1000_reset_hw_82543"); 907 908 DEBUGOUT("Masking off all interrupts\n"); 909 E1000_WRITE_REG(hw, E1000_IMC, 0xffffffff); 910 911 E1000_WRITE_REG(hw, E1000_RCTL, 0); --- 25 unchanged lines hidden (view full) --- 937 * After MAC reset, force reload of NVM to restore power-on 938 * settings to device. 939 */ 940 hw->nvm.ops.reload(hw); 941 msec_delay(2); 942 943 /* Masking off and clearing any pending interrupts */ 944 E1000_WRITE_REG(hw, E1000_IMC, 0xffffffff); |
945 icr = E1000_READ_REG(hw, E1000_ICR); | 945 E1000_READ_REG(hw, E1000_ICR); |
946 947 return ret_val; 948} 949 950/** 951 * e1000_init_hw_82543 - Initialize hardware 952 * @hw: pointer to the HW structure 953 * --- 643 unchanged lines hidden --- | 946 947 return ret_val; 948} 949 950/** 951 * e1000_init_hw_82543 - Initialize hardware 952 * @hw: pointer to the HW structure 953 * --- 643 unchanged lines hidden --- |