Commit e99bdd39 authored by Carolyn Wyborny's avatar Carolyn Wyborny Committed by Jeff Kirsher

i40e: Update flow director error messages to reduce user confusion

This patch changes the wording of the flow director add/remove and
asynchronous failure messages to include fd_id to try and add some
way to track the operations on a given fd_id.  Its not perfect, but
its better than what we had as PCTYPE can apply to several different
filter requests.

This patch also removes a redundant message when filter
addition fails due to full condition.

Change-ID: Icf58b0603d4f162d9fc542f11a74866a907049f2
Signed-off-by: default avatarCarolyn Wyborny <carolyn.wyborny@intel.com>
Tested-by: default avatarJim Young <jamesx.m.young@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent a3d12146
...@@ -224,15 +224,14 @@ static int i40e_add_del_fdir_udpv4(struct i40e_vsi *vsi, ...@@ -224,15 +224,14 @@ static int i40e_add_del_fdir_udpv4(struct i40e_vsi *vsi,
ret = i40e_program_fdir_filter(fd_data, raw_packet, pf, add); ret = i40e_program_fdir_filter(fd_data, raw_packet, pf, add);
if (ret) { if (ret) {
dev_info(&pf->pdev->dev, dev_info(&pf->pdev->dev,
"Filter command send failed for PCTYPE %d (ret = %d)\n", "PCTYPE:%d, Filter command send failed for fd_id:%d (ret = %d)\n",
fd_data->pctype, ret); fd_data->pctype, fd_data->fd_id, ret);
err = true; err = true;
} else { } else {
dev_info(&pf->pdev->dev, dev_info(&pf->pdev->dev,
"Filter OK for PCTYPE %d (ret = %d)\n", "PCTYPE:%d, Filter send OK for fd_id:%d\n",
fd_data->pctype, ret); fd_data->pctype, fd_data->fd_id);
} }
return err ? -EOPNOTSUPP : 0; return err ? -EOPNOTSUPP : 0;
} }
...@@ -287,12 +286,13 @@ static int i40e_add_del_fdir_tcpv4(struct i40e_vsi *vsi, ...@@ -287,12 +286,13 @@ static int i40e_add_del_fdir_tcpv4(struct i40e_vsi *vsi,
if (ret) { if (ret) {
dev_info(&pf->pdev->dev, dev_info(&pf->pdev->dev,
"Filter command send failed for PCTYPE %d (ret = %d)\n", "PCTYPE:%d, Filter command send failed for fd_id:%d (ret = %d)\n",
fd_data->pctype, ret); fd_data->pctype, fd_data->fd_id, ret);
err = true; err = true;
} else { } else {
dev_info(&pf->pdev->dev, "Filter OK for PCTYPE %d (ret = %d)\n", dev_info(&pf->pdev->dev,
fd_data->pctype, ret); "PCTYPE:%d, Filter send OK for fd_id:%d\n",
fd_data->pctype, fd_data->fd_id);
} }
return err ? -EOPNOTSUPP : 0; return err ? -EOPNOTSUPP : 0;
...@@ -355,13 +355,13 @@ static int i40e_add_del_fdir_ipv4(struct i40e_vsi *vsi, ...@@ -355,13 +355,13 @@ static int i40e_add_del_fdir_ipv4(struct i40e_vsi *vsi,
if (ret) { if (ret) {
dev_info(&pf->pdev->dev, dev_info(&pf->pdev->dev,
"Filter command send failed for PCTYPE %d (ret = %d)\n", "PCTYPE:%d, Filter command send failed for fd_id:%d (ret = %d)\n",
fd_data->pctype, ret); fd_data->pctype, fd_data->fd_id, ret);
err = true; err = true;
} else { } else {
dev_info(&pf->pdev->dev, dev_info(&pf->pdev->dev,
"Filter OK for PCTYPE %d (ret = %d)\n", "PCTYPE:%d, Filter send OK for fd_id:%d\n",
fd_data->pctype, ret); fd_data->pctype, fd_data->fd_id);
} }
} }
...@@ -443,8 +443,6 @@ static void i40e_fd_handle_status(struct i40e_ring *rx_ring, ...@@ -443,8 +443,6 @@ static void i40e_fd_handle_status(struct i40e_ring *rx_ring,
I40E_RX_PROG_STATUS_DESC_QW1_ERROR_SHIFT; I40E_RX_PROG_STATUS_DESC_QW1_ERROR_SHIFT;
if (error == (0x1 << I40E_RX_PROG_STATUS_DESC_FD_TBL_FULL_SHIFT)) { if (error == (0x1 << I40E_RX_PROG_STATUS_DESC_FD_TBL_FULL_SHIFT)) {
dev_warn(&pdev->dev, "ntuple filter loc = %d, could not be added\n",
rx_desc->wb.qword0.hi_dword.fd_id);
/* filter programming failed most likely due to table full */ /* filter programming failed most likely due to table full */
fcnt_prog = i40e_get_cur_guaranteed_fd_count(pf); fcnt_prog = i40e_get_cur_guaranteed_fd_count(pf);
...@@ -471,12 +469,13 @@ static void i40e_fd_handle_status(struct i40e_ring *rx_ring, ...@@ -471,12 +469,13 @@ static void i40e_fd_handle_status(struct i40e_ring *rx_ring,
pf->flags |= I40E_FLAG_FDIR_REQUIRES_REINIT; pf->flags |= I40E_FLAG_FDIR_REQUIRES_REINIT;
} }
} else { } else {
dev_info(&pdev->dev, "FD filter programming error\n"); dev_info(&pdev->dev,
"FD filter programming failed due to incorrect filter parameters\n");
} }
} else if (error == } else if (error ==
(0x1 << I40E_RX_PROG_STATUS_DESC_NO_FD_ENTRY_SHIFT)) { (0x1 << I40E_RX_PROG_STATUS_DESC_NO_FD_ENTRY_SHIFT)) {
if (I40E_DEBUG_FD & pf->hw.debug_mask) if (I40E_DEBUG_FD & pf->hw.debug_mask)
dev_info(&pdev->dev, "ntuple filter loc = %d, could not be removed\n", dev_info(&pdev->dev, "ntuple filter fd_id = %d, could not be removed\n",
rx_desc->wb.qword0.hi_dword.fd_id); rx_desc->wb.qword0.hi_dword.fd_id);
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment