Deleted Added
full compact
ixgbe_api.c (190873) ixgbe_api.c (194875)
1/******************************************************************************
2
3 Copyright (c) 2001-2009, 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-2009, 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/ixgbe/ixgbe_api.c 190873 2009-04-10 00:22:48Z jfv $*/
33/*$FreeBSD: head/sys/dev/ixgbe/ixgbe_api.c 194875 2009-06-24 18:27:07Z jfv $*/
34
35#include "ixgbe_api.h"
36#include "ixgbe_common.h"
37
38extern s32 ixgbe_init_ops_82598(struct ixgbe_hw *hw);
39extern s32 ixgbe_init_ops_82599(struct ixgbe_hw *hw);
40
41/**

--- 56 unchanged lines hidden (view full) ---

98 case IXGBE_DEV_ID_82598_CX4_DUAL_PORT:
99 case IXGBE_DEV_ID_82598_DA_DUAL_PORT:
100 case IXGBE_DEV_ID_82598_SR_DUAL_PORT_EM:
101 case IXGBE_DEV_ID_82598EB_XF_LR:
102 case IXGBE_DEV_ID_82598EB_SFP_LOM:
103 hw->mac.type = ixgbe_mac_82598EB;
104 break;
105 case IXGBE_DEV_ID_82599_KX4:
34
35#include "ixgbe_api.h"
36#include "ixgbe_common.h"
37
38extern s32 ixgbe_init_ops_82598(struct ixgbe_hw *hw);
39extern s32 ixgbe_init_ops_82599(struct ixgbe_hw *hw);
40
41/**

--- 56 unchanged lines hidden (view full) ---

98 case IXGBE_DEV_ID_82598_CX4_DUAL_PORT:
99 case IXGBE_DEV_ID_82598_DA_DUAL_PORT:
100 case IXGBE_DEV_ID_82598_SR_DUAL_PORT_EM:
101 case IXGBE_DEV_ID_82598EB_XF_LR:
102 case IXGBE_DEV_ID_82598EB_SFP_LOM:
103 hw->mac.type = ixgbe_mac_82598EB;
104 break;
105 case IXGBE_DEV_ID_82599_KX4:
106 case IXGBE_DEV_ID_82599_XAUI_LOM:
106 case IXGBE_DEV_ID_82599_SFP:
107 case IXGBE_DEV_ID_82599_CX4:
108 hw->mac.type = ixgbe_mac_82599EB;
109 break;
110 default:
111 ret_val = IXGBE_ERR_DEVICE_NOT_SUPPORTED;
112 break;
113 }

--- 816 unchanged lines hidden (view full) ---

930 *
931 * Enables the Rx DMA unit of the device.
932 **/
933s32 ixgbe_enable_rx_dma(struct ixgbe_hw *hw, u32 regval)
934{
935 return ixgbe_call_func(hw, hw->mac.ops.enable_rx_dma,
936 (hw, regval), IXGBE_NOT_IMPLEMENTED);
937}
107 case IXGBE_DEV_ID_82599_SFP:
108 case IXGBE_DEV_ID_82599_CX4:
109 hw->mac.type = ixgbe_mac_82599EB;
110 break;
111 default:
112 ret_val = IXGBE_ERR_DEVICE_NOT_SUPPORTED;
113 break;
114 }

--- 816 unchanged lines hidden (view full) ---

931 *
932 * Enables the Rx DMA unit of the device.
933 **/
934s32 ixgbe_enable_rx_dma(struct ixgbe_hw *hw, u32 regval)
935{
936 return ixgbe_call_func(hw, hw->mac.ops.enable_rx_dma,
937 (hw, regval), IXGBE_NOT_IMPLEMENTED);
938}
939
940/**
941 * ixgbe_acquire_swfw_semaphore - Acquire SWFW semaphore
942 * @hw: pointer to hardware structure
943 * @mask: Mask to specify which semaphore to acquire
944 *
945 * Acquires the SWFW semaphore through SW_FW_SYNC register for the specified
946 * function (CSR, PHY0, PHY1, EEPROM, Flash)
947 **/
948s32 ixgbe_acquire_swfw_semaphore(struct ixgbe_hw *hw, u16 mask)
949{
950 return ixgbe_call_func(hw, hw->mac.ops.acquire_swfw_sync,
951 (hw, mask), IXGBE_NOT_IMPLEMENTED);
952}
953
954/**
955 * ixgbe_release_swfw_semaphore - Release SWFW semaphore
956 * @hw: pointer to hardware structure
957 * @mask: Mask to specify which semaphore to release
958 *
959 * Releases the SWFW semaphore through SW_FW_SYNC register for the specified
960 * function (CSR, PHY0, PHY1, EEPROM, Flash)
961 **/
962void ixgbe_release_swfw_semaphore(struct ixgbe_hw *hw, u16 mask)
963{
964 if (hw->mac.ops.release_swfw_sync)
965 hw->mac.ops.release_swfw_sync(hw, mask);
966}
967