net/ngbe: support flow control
[dpdk.git] / drivers / net / ngbe / base / ngbe_dummy.h
index 59c8097..0baabcb 100644 (file)
@@ -33,6 +33,11 @@ static inline s32 ngbe_rom_init_params_dummy(struct ngbe_hw *TUP0)
 {
        return NGBE_ERR_OPS_DUMMY;
 }
+static inline s32 ngbe_rom_read32_dummy(struct ngbe_hw *TUP0, u32 TUP1,
+                                       u32 *TUP2)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
 static inline s32 ngbe_rom_validate_checksum_dummy(struct ngbe_hw *TUP0,
                                        u16 *TUP1)
 {
@@ -122,10 +127,44 @@ static inline s32 ngbe_mac_init_rx_addrs_dummy(struct ngbe_hw *TUP0)
 {
        return NGBE_ERR_OPS_DUMMY;
 }
+static inline s32 ngbe_mac_update_mc_addr_list_dummy(struct ngbe_hw *TUP0,
+                       u8 *TUP1, u32 TUP2, ngbe_mc_addr_itr TUP3, bool TUP4)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
 static inline s32 ngbe_mac_clear_vfta_dummy(struct ngbe_hw *TUP0)
 {
        return NGBE_ERR_OPS_DUMMY;
 }
+static inline s32 ngbe_mac_set_vfta_dummy(struct ngbe_hw *TUP0, u32 TUP1,
+                                       u32 TUP2, bool TUP3, bool TUP4)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_mac_set_vlvf_dummy(struct ngbe_hw *TUP0, u32 TUP1,
+                       u32 TUP2, bool TUP3, u32 *TUP4, u32 TUP5, bool TUP6)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline void ngbe_mac_set_mac_anti_spoofing_dummy(struct ngbe_hw *TUP0,
+                                       bool TUP1, int TUP2)
+{
+}
+static inline void ngbe_mac_set_vlan_anti_spoofing_dummy(struct ngbe_hw *TUP0,
+                                       bool TUP1, int TUP2)
+{
+}
+static inline s32 ngbe_mac_fc_enable_dummy(struct ngbe_hw *TUP0)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_mac_setup_fc_dummy(struct ngbe_hw *TUP0)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline void ngbe_mac_fc_autoneg_dummy(struct ngbe_hw *TUP0)
+{
+}
 static inline s32 ngbe_mac_init_thermal_ssth_dummy(struct ngbe_hw *TUP0)
 {
        return NGBE_ERR_OPS_DUMMY;
@@ -177,10 +216,53 @@ static inline s32 ngbe_phy_check_link_dummy(struct ngbe_hw *TUP0, u32 *TUP1,
 {
        return NGBE_ERR_OPS_DUMMY;
 }
+static inline s32 ngbe_get_phy_advertised_pause_dummy(struct ngbe_hw *TUP0,
+                                       u8 *TUP1)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_get_phy_lp_advertised_pause_dummy(struct ngbe_hw *TUP0,
+                                       u8 *TUP1)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_set_phy_pause_adv_dummy(struct ngbe_hw *TUP0, u16 TUP1)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+
+/* struct ngbe_mbx_operations */
+static inline void ngbe_mbx_init_params_dummy(struct ngbe_hw *TUP0)
+{
+}
+static inline s32 ngbe_mbx_read_dummy(struct ngbe_hw *TUP0, u32 *TUP1,
+                                       u16 TUP2, u16 TUP3)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_mbx_write_dummy(struct ngbe_hw *TUP0, u32 *TUP1,
+                                       u16 TUP2, u16 TUP3)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_mbx_check_for_msg_dummy(struct ngbe_hw *TUP0, u16 TUP1)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_mbx_check_for_ack_dummy(struct ngbe_hw *TUP0, u16 TUP1)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+static inline s32 ngbe_mbx_check_for_rst_dummy(struct ngbe_hw *TUP0, u16 TUP1)
+{
+       return NGBE_ERR_OPS_DUMMY;
+}
+
 static inline void ngbe_init_ops_dummy(struct ngbe_hw *hw)
 {
        hw->bus.set_lan_id = ngbe_bus_set_lan_id_dummy;
        hw->rom.init_params = ngbe_rom_init_params_dummy;
+       hw->rom.read32 = ngbe_rom_read32_dummy;
        hw->rom.validate_checksum = ngbe_rom_validate_checksum_dummy;
        hw->mac.init_hw = ngbe_mac_init_hw_dummy;
        hw->mac.reset_hw = ngbe_mac_reset_hw_dummy;
@@ -201,7 +283,15 @@ static inline void ngbe_init_ops_dummy(struct ngbe_hw *hw)
        hw->mac.set_vmdq = ngbe_mac_set_vmdq_dummy;
        hw->mac.clear_vmdq = ngbe_mac_clear_vmdq_dummy;
        hw->mac.init_rx_addrs = ngbe_mac_init_rx_addrs_dummy;
+       hw->mac.update_mc_addr_list = ngbe_mac_update_mc_addr_list_dummy;
        hw->mac.clear_vfta = ngbe_mac_clear_vfta_dummy;
+       hw->mac.set_vfta = ngbe_mac_set_vfta_dummy;
+       hw->mac.set_vlvf = ngbe_mac_set_vlvf_dummy;
+       hw->mac.set_mac_anti_spoofing = ngbe_mac_set_mac_anti_spoofing_dummy;
+       hw->mac.set_vlan_anti_spoofing = ngbe_mac_set_vlan_anti_spoofing_dummy;
+       hw->mac.fc_enable = ngbe_mac_fc_enable_dummy;
+       hw->mac.setup_fc = ngbe_mac_setup_fc_dummy;
+       hw->mac.fc_autoneg = ngbe_mac_fc_autoneg_dummy;
        hw->mac.init_thermal_sensor_thresh = ngbe_mac_init_thermal_ssth_dummy;
        hw->mac.check_overtemp = ngbe_mac_check_overtemp_dummy;
        hw->phy.identify = ngbe_phy_identify_dummy;
@@ -213,6 +303,15 @@ static inline void ngbe_init_ops_dummy(struct ngbe_hw *hw)
        hw->phy.write_reg_unlocked = ngbe_phy_write_reg_unlocked_dummy;
        hw->phy.setup_link = ngbe_phy_setup_link_dummy;
        hw->phy.check_link = ngbe_phy_check_link_dummy;
+       hw->phy.get_adv_pause = ngbe_get_phy_advertised_pause_dummy;
+       hw->phy.get_lp_adv_pause = ngbe_get_phy_lp_advertised_pause_dummy;
+       hw->phy.set_pause_adv = ngbe_set_phy_pause_adv_dummy;
+       hw->mbx.init_params = ngbe_mbx_init_params_dummy;
+       hw->mbx.read = ngbe_mbx_read_dummy;
+       hw->mbx.write = ngbe_mbx_write_dummy;
+       hw->mbx.check_for_msg = ngbe_mbx_check_for_msg_dummy;
+       hw->mbx.check_for_ack = ngbe_mbx_check_for_ack_dummy;
+       hw->mbx.check_for_rst = ngbe_mbx_check_for_rst_dummy;
 }
 
 #endif /* _NGBE_TYPE_DUMMY_H_ */