diff options
author | Shiraz Saleem <shiraz.saleem@intel.com> | 2021-10-19 01:16:03 +0200 |
---|---|---|
committer | Tony Nguyen <anthony.l.nguyen@intel.com> | 2021-11-22 17:42:15 +0100 |
commit | 774a90c1e1a340ebad7b1d8783356bed490ca02f (patch) | |
tree | 466a7e72b6f77921150fc8d1497592b3467b8a0e /drivers/infiniband/hw/irdma/main.c | |
parent | net/ice: Add support for enable_iwarp and enable_roce devlink param (diff) | |
download | linux-774a90c1e1a340ebad7b1d8783356bed490ca02f.tar.xz linux-774a90c1e1a340ebad7b1d8783356bed490ca02f.zip |
RDMA/irdma: Set protocol based on PF rdma_mode flag
Set the RDMA protocol to use at driver bind time based on the ice PF's
rdma_mode flag.
Signed-off-by: Shiraz Saleem <shiraz.saleem@intel.com>
Tested-by: Leszek Kaliszczuk <leszek.kaliszczuk@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Diffstat (limited to 'drivers/infiniband/hw/irdma/main.c')
-rw-r--r-- | drivers/infiniband/hw/irdma/main.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/irdma/main.c b/drivers/infiniband/hw/irdma/main.c index 51a41359e0b4..3fda7b78a9af 100644 --- a/drivers/infiniband/hw/irdma/main.c +++ b/drivers/infiniband/hw/irdma/main.c @@ -228,7 +228,8 @@ static void irdma_fill_device_info(struct irdma_device *iwdev, struct ice_pf *pf rf->msix_count = pf->num_rdma_msix; rf->msix_entries = &pf->msix_entries[pf->rdma_base_vector]; rf->default_vsi.vsi_idx = vsi->vsi_num; - rf->protocol_used = IRDMA_ROCE_PROTOCOL_ONLY; + rf->protocol_used = pf->rdma_mode & IIDC_RDMA_PROTOCOL_ROCEV2 ? + IRDMA_ROCE_PROTOCOL_ONLY : IRDMA_IWARP_PROTOCOL_ONLY; rf->rdma_ver = IRDMA_GEN_2; rf->rsrc_profile = IRDMA_HMC_PROFILE_DEFAULT; rf->rst_to = IRDMA_RST_TIMEOUT_HZ; |