X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=lib%2Flibrte_pmd_e1000%2Fe1000%2Fe1000_vf.c;h=778561e73ed7768e7abc00a4e0090106bf6f05de;hb=66e1591687ac;hp=86c67a6342294a4e3efe60218072b497fb47e480;hpb=8a5eeb9c056f350e71067bf1373bd203231fe2b0;p=dpdk.git diff --git a/lib/librte_pmd_e1000/e1000/e1000_vf.c b/lib/librte_pmd_e1000/e1000/e1000_vf.c index 86c67a6342..778561e73e 100644 --- a/lib/librte_pmd_e1000/e1000/e1000_vf.c +++ b/lib/librte_pmd_e1000/e1000/e1000_vf.c @@ -1,6 +1,6 @@ /******************************************************************************* -Copyright (c) 2001-2012, Intel Corporation +Copyright (c) 2001-2014, Intel Corporation All rights reserved. Redistribution and use in source and binary forms, with or without @@ -35,21 +35,21 @@ POSSIBILITY OF SUCH DAMAGE. #include "e1000_api.h" -STATIC s32 e1000_init_phy_params_vf(struct e1000_hw *hw); -STATIC s32 e1000_init_nvm_params_vf(struct e1000_hw *hw); -STATIC void e1000_release_vf(struct e1000_hw *hw); -STATIC s32 e1000_acquire_vf(struct e1000_hw *hw); -STATIC s32 e1000_setup_link_vf(struct e1000_hw *hw); -STATIC s32 e1000_get_bus_info_pcie_vf(struct e1000_hw *hw); -STATIC s32 e1000_init_mac_params_vf(struct e1000_hw *hw); -STATIC s32 e1000_check_for_link_vf(struct e1000_hw *hw); -STATIC s32 e1000_get_link_up_info_vf(struct e1000_hw *hw, u16 *speed, - u16 *duplex); -STATIC s32 e1000_init_hw_vf(struct e1000_hw *hw); -STATIC s32 e1000_reset_hw_vf(struct e1000_hw *hw); -STATIC void e1000_update_mc_addr_list_vf(struct e1000_hw *hw, u8 *, u32); -STATIC void e1000_rar_set_vf(struct e1000_hw *, u8 *, u32); -STATIC s32 e1000_read_mac_addr_vf(struct e1000_hw *); +STATIC s32 e1000_init_phy_params_vf(struct e1000_hw *hw); +STATIC s32 e1000_init_nvm_params_vf(struct e1000_hw *hw); +STATIC void e1000_release_vf(struct e1000_hw *hw); +STATIC s32 e1000_acquire_vf(struct e1000_hw *hw); +STATIC s32 e1000_setup_link_vf(struct e1000_hw *hw); +STATIC s32 e1000_get_bus_info_pcie_vf(struct e1000_hw *hw); +STATIC s32 e1000_init_mac_params_vf(struct e1000_hw *hw); +STATIC s32 e1000_check_for_link_vf(struct e1000_hw *hw); +STATIC s32 e1000_get_link_up_info_vf(struct e1000_hw *hw, u16 *speed, + u16 *duplex); +STATIC s32 e1000_init_hw_vf(struct e1000_hw *hw); +STATIC s32 e1000_reset_hw_vf(struct e1000_hw *hw); +STATIC void e1000_update_mc_addr_list_vf(struct e1000_hw *hw, u8 *, u32); +STATIC void e1000_rar_set_vf(struct e1000_hw *, u8 *, u32); +STATIC s32 e1000_read_mac_addr_vf(struct e1000_hw *); /** * e1000_init_phy_params_vf - Inits PHY params @@ -158,8 +158,9 @@ void e1000_init_function_pointers_vf(struct e1000_hw *hw) * In addition, the MAC registers to access PHY/NVM don't exist so we don't * even want any SW to attempt to use them. **/ -STATIC s32 e1000_acquire_vf(struct e1000_hw *hw) +STATIC s32 e1000_acquire_vf(struct e1000_hw E1000_UNUSEDARG *hw) { + UNREFERENCED_1PARAMETER(hw); return -E1000_ERR_PHY; } @@ -171,8 +172,9 @@ STATIC s32 e1000_acquire_vf(struct e1000_hw *hw) * In addition, the MAC registers to access PHY/NVM don't exist so we don't * even want any SW to attempt to use them. **/ -STATIC void e1000_release_vf(struct e1000_hw *hw) +STATIC void e1000_release_vf(struct e1000_hw E1000_UNUSEDARG *hw) { + UNREFERENCED_1PARAMETER(hw); return; } @@ -182,9 +184,10 @@ STATIC void e1000_release_vf(struct e1000_hw *hw) * * Virtual functions cannot change link. **/ -STATIC s32 e1000_setup_link_vf(struct e1000_hw *hw) +STATIC s32 e1000_setup_link_vf(struct e1000_hw E1000_UNUSEDARG *hw) { DEBUGFUNC("e1000_setup_link_vf"); + UNREFERENCED_1PARAMETER(hw); return E1000_SUCCESS; } @@ -218,7 +221,7 @@ STATIC s32 e1000_get_bus_info_pcie_vf(struct e1000_hw *hw) * the status register's data which is often stale and inaccurate. **/ STATIC s32 e1000_get_link_up_info_vf(struct e1000_hw *hw, u16 *speed, - u16 *duplex) + u16 *duplex) { s32 status; @@ -287,7 +290,7 @@ STATIC s32 e1000_reset_hw_vf(struct e1000_hw *hw) ret_val = mbx->ops.read_posted(hw, msgbuf, 3, 0); if (!ret_val) { if (msgbuf[0] == (E1000_VF_RESET | - E1000_VT_MSGTYPE_ACK)) + E1000_VT_MSGTYPE_ACK)) memcpy(hw->mac.perm_addr, addr, 6); else ret_val = -E1000_ERR_MAC_INIT; @@ -319,13 +322,15 @@ STATIC s32 e1000_init_hw_vf(struct e1000_hw *hw) * @addr: pointer to the receive address * @index receive address array register **/ -STATIC void e1000_rar_set_vf(struct e1000_hw *hw, u8 * addr, u32 index) +STATIC void e1000_rar_set_vf(struct e1000_hw *hw, u8 *addr, + u32 E1000_UNUSEDARG index) { struct e1000_mbx_info *mbx = &hw->mbx; u32 msgbuf[3]; u8 *msg_addr = (u8 *)(&msgbuf[1]); s32 ret_val; + UNREFERENCED_1PARAMETER(index); memset(msgbuf, 0, 12); msgbuf[0] = E1000_VF_SET_MAC_ADDR; memcpy(msg_addr, addr, 6); @@ -368,12 +373,12 @@ STATIC u32 e1000_hash_mc_addr_vf(struct e1000_hw *hw, u8 *mc_addr) bit_shift++; hash_value = hash_mask & (((mc_addr[4] >> (8 - bit_shift)) | - (((u16) mc_addr[5]) << bit_shift))); + (((u16) mc_addr[5]) << bit_shift))); return hash_value; } -static void e1000_write_msg_read_ack(struct e1000_hw *hw, +STATIC void e1000_write_msg_read_ack(struct e1000_hw *hw, u32 *msg, u16 size) { struct e1000_mbx_info *mbx = &hw->mbx; @@ -394,7 +399,7 @@ static void e1000_write_msg_read_ack(struct e1000_hw *hw, * The caller must have a packed mc_addr_list of multicast addresses. **/ void e1000_update_mc_addr_list_vf(struct e1000_hw *hw, - u8 *mc_addr_list, u32 mc_addr_count) + u8 *mc_addr_list, u32 mc_addr_count) { u32 msgbuf[E1000_VFMAILBOX_SIZE]; u16 *hash_list = (u16 *)&msgbuf[1];