0001
0002
0003
0004 #ifndef _ENIC_DEV_H_
0005 #define _ENIC_DEV_H_
0006
0007 #include "vnic_dev.h"
0008 #include "vnic_vic.h"
0009
0010
0011
0012
0013
0014 #define ENIC_DEVCMD_PROXY_BY_INDEX(vf, err, enic, vnicdevcmdfn, ...) \
0015 do { \
0016 spin_lock_bh(&enic->devcmd_lock); \
0017 if (enic_is_valid_vf(enic, vf)) { \
0018 vnic_dev_cmd_proxy_by_index_start(enic->vdev, vf); \
0019 err = vnicdevcmdfn(enic->vdev, ##__VA_ARGS__); \
0020 vnic_dev_cmd_proxy_end(enic->vdev); \
0021 } else { \
0022 err = vnicdevcmdfn(enic->vdev, ##__VA_ARGS__); \
0023 } \
0024 spin_unlock_bh(&enic->devcmd_lock); \
0025 } while (0)
0026
0027 int enic_dev_fw_info(struct enic *enic, struct vnic_devcmd_fw_info **fw_info);
0028 int enic_dev_stats_dump(struct enic *enic, struct vnic_stats **vstats);
0029 int enic_dev_add_station_addr(struct enic *enic);
0030 int enic_dev_del_station_addr(struct enic *enic);
0031 int enic_dev_packet_filter(struct enic *enic, int directed, int multicast,
0032 int broadcast, int promisc, int allmulti);
0033 int enic_dev_add_addr(struct enic *enic, const u8 *addr);
0034 int enic_dev_del_addr(struct enic *enic, const u8 *addr);
0035 int enic_vlan_rx_add_vid(struct net_device *netdev, __be16 proto, u16 vid);
0036 int enic_vlan_rx_kill_vid(struct net_device *netdev, __be16 proto, u16 vid);
0037 int enic_dev_notify_unset(struct enic *enic);
0038 int enic_dev_hang_notify(struct enic *enic);
0039 int enic_dev_set_ig_vlan_rewrite_mode(struct enic *enic);
0040 int enic_dev_enable(struct enic *enic);
0041 int enic_dev_disable(struct enic *enic);
0042 int enic_dev_intr_coal_timer_info(struct enic *enic);
0043 int enic_dev_status_to_errno(int devcmd_status);
0044
0045 #endif