diff options
author | Anirudh Venkataramanan <anirudh.venkataramanan@intel.com> | 2018-09-19 17:42:57 -0700 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2018-10-03 07:42:30 -0700 |
commit | 007676b4ac920d4ceb4e4aa8aa668ac32d4764ad (patch) | |
tree | f36d3326526bb6b453d794cce2aab9066e5cf65c /drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h | |
parent | 8ede01785f32269ef4766cf17a535e70ee3c1541 (diff) |
ice: Add support for VF reset events
Post VF initialization, there are a couple of different ways in which a
VF reset can be triggered. One is when the underlying PF itself goes
through a reset and other is via a VFLR interrupt. ice_reset_vf introduced
in this patch handles both these cases.
Also introduced in this patch is a helper function ice_aq_send_msg_to_vf
to send messages to VF over the mailbox queue. The PF uses this to send
reset notifications to VFs.
Signed-off-by: Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h')
-rw-r--r-- | drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h b/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h index 85c263a7494c..0043061b37e0 100644 --- a/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h +++ b/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.h @@ -51,11 +51,15 @@ struct ice_vf { }; #ifdef CONFIG_PCI_IOV +void ice_process_vflr_event(struct ice_pf *pf); int ice_sriov_configure(struct pci_dev *pdev, int num_vfs); void ice_free_vfs(struct ice_pf *pf); +void ice_vc_notify_reset(struct ice_pf *pf); bool ice_reset_all_vfs(struct ice_pf *pf, bool is_vflr); #else /* CONFIG_PCI_IOV */ +#define ice_process_vflr_event(pf) do {} while (0) #define ice_free_vfs(pf) do {} while (0) +#define ice_vc_notify_reset(pf) do {} while (0) static inline bool ice_reset_all_vfs(struct ice_pf __always_unused *pf, |