Commit 5c875c1a authored by Anirudh Venkataramanan's avatar Anirudh Venkataramanan Committed by Jeff Kirsher

ice: Rework around device/function capabilities

ice_parse_caps is printing capabilities in a different way when
compared to the variable names. This makes it difficult to search for
the right strings in the debug logs. So this patch updates the
print strings to be exactly the same as the fields' name in the
structure.
Signed-off-by: default avatarAnirudh Venkataramanan <anirudh.venkataramanan@intel.com>
Signed-off-by: default avatarTony Nguyen <anthony.l.nguyen@intel.com>
Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent dd47e1fd
...@@ -1551,29 +1551,29 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count, ...@@ -1551,29 +1551,29 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count,
case ICE_AQC_CAPS_VALID_FUNCTIONS: case ICE_AQC_CAPS_VALID_FUNCTIONS:
caps->valid_functions = number; caps->valid_functions = number;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: valid functions = %d\n", prefix, "%s: valid_functions (bitmap) = %d\n", prefix,
caps->valid_functions); caps->valid_functions);
break; break;
case ICE_AQC_CAPS_SRIOV: case ICE_AQC_CAPS_SRIOV:
caps->sr_iov_1_1 = (number == 1); caps->sr_iov_1_1 = (number == 1);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: SR-IOV = %d\n", prefix, "%s: sr_iov_1_1 = %d\n", prefix,
caps->sr_iov_1_1); caps->sr_iov_1_1);
break; break;
case ICE_AQC_CAPS_VF: case ICE_AQC_CAPS_VF:
if (dev_p) { if (dev_p) {
dev_p->num_vfs_exposed = number; dev_p->num_vfs_exposed = number;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: VFs exposed = %d\n", prefix, "%s: num_vfs_exposed = %d\n", prefix,
dev_p->num_vfs_exposed); dev_p->num_vfs_exposed);
} else if (func_p) { } else if (func_p) {
func_p->num_allocd_vfs = number; func_p->num_allocd_vfs = number;
func_p->vf_base_id = logical_id; func_p->vf_base_id = logical_id;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: VFs allocated = %d\n", prefix, "%s: num_allocd_vfs = %d\n", prefix,
func_p->num_allocd_vfs); func_p->num_allocd_vfs);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: VF base_id = %d\n", prefix, "%s: vf_base_id = %d\n", prefix,
func_p->vf_base_id); func_p->vf_base_id);
} }
break; break;
...@@ -1581,17 +1581,17 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count, ...@@ -1581,17 +1581,17 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count,
if (dev_p) { if (dev_p) {
dev_p->num_vsi_allocd_to_host = number; dev_p->num_vsi_allocd_to_host = number;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: num VSI alloc to host = %d\n", "%s: num_vsi_allocd_to_host = %d\n",
prefix, prefix,
dev_p->num_vsi_allocd_to_host); dev_p->num_vsi_allocd_to_host);
} else if (func_p) { } else if (func_p) {
func_p->guar_num_vsi = func_p->guar_num_vsi =
ice_get_num_per_func(hw, ICE_MAX_VSI); ice_get_num_per_func(hw, ICE_MAX_VSI);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: num guaranteed VSI (fw) = %d\n", "%s: guar_num_vsi (fw) = %d\n",
prefix, number); prefix, number);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: num guaranteed VSI = %d\n", "%s: guar_num_vsi = %d\n",
prefix, func_p->guar_num_vsi); prefix, func_p->guar_num_vsi);
} }
break; break;
...@@ -1600,56 +1600,56 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count, ...@@ -1600,56 +1600,56 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count,
caps->active_tc_bitmap = logical_id; caps->active_tc_bitmap = logical_id;
caps->maxtc = phys_id; caps->maxtc = phys_id;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: DCB = %d\n", prefix, caps->dcb); "%s: dcb = %d\n", prefix, caps->dcb);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: active TC bitmap = %d\n", prefix, "%s: active_tc_bitmap = %d\n", prefix,
caps->active_tc_bitmap); caps->active_tc_bitmap);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: TC max = %d\n", prefix, caps->maxtc); "%s: maxtc = %d\n", prefix, caps->maxtc);
break; break;
case ICE_AQC_CAPS_RSS: case ICE_AQC_CAPS_RSS:
caps->rss_table_size = number; caps->rss_table_size = number;
caps->rss_table_entry_width = logical_id; caps->rss_table_entry_width = logical_id;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: RSS table size = %d\n", prefix, "%s: rss_table_size = %d\n", prefix,
caps->rss_table_size); caps->rss_table_size);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: RSS table width = %d\n", prefix, "%s: rss_table_entry_width = %d\n", prefix,
caps->rss_table_entry_width); caps->rss_table_entry_width);
break; break;
case ICE_AQC_CAPS_RXQS: case ICE_AQC_CAPS_RXQS:
caps->num_rxq = number; caps->num_rxq = number;
caps->rxq_first_id = phys_id; caps->rxq_first_id = phys_id;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: num Rx queues = %d\n", prefix, "%s: num_rxq = %d\n", prefix,
caps->num_rxq); caps->num_rxq);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: Rx first queue ID = %d\n", prefix, "%s: rxq_first_id = %d\n", prefix,
caps->rxq_first_id); caps->rxq_first_id);
break; break;
case ICE_AQC_CAPS_TXQS: case ICE_AQC_CAPS_TXQS:
caps->num_txq = number; caps->num_txq = number;
caps->txq_first_id = phys_id; caps->txq_first_id = phys_id;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: num Tx queues = %d\n", prefix, "%s: num_txq = %d\n", prefix,
caps->num_txq); caps->num_txq);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: Tx first queue ID = %d\n", prefix, "%s: txq_first_id = %d\n", prefix,
caps->txq_first_id); caps->txq_first_id);
break; break;
case ICE_AQC_CAPS_MSIX: case ICE_AQC_CAPS_MSIX:
caps->num_msix_vectors = number; caps->num_msix_vectors = number;
caps->msix_vector_first_id = phys_id; caps->msix_vector_first_id = phys_id;
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: MSIX vector count = %d\n", prefix, "%s: num_msix_vectors = %d\n", prefix,
caps->num_msix_vectors); caps->num_msix_vectors);
ice_debug(hw, ICE_DBG_INIT, ice_debug(hw, ICE_DBG_INIT,
"%s: MSIX first vector index = %d\n", prefix, "%s: msix_vector_first_id = %d\n", prefix,
caps->msix_vector_first_id); caps->msix_vector_first_id);
break; break;
case ICE_AQC_CAPS_MAX_MTU: case ICE_AQC_CAPS_MAX_MTU:
caps->max_mtu = number; caps->max_mtu = number;
ice_debug(hw, ICE_DBG_INIT, "%s: max MTU = %d\n", ice_debug(hw, ICE_DBG_INIT, "%s: max_mtu = %d\n",
prefix, caps->max_mtu); prefix, caps->max_mtu);
break; break;
default: default:
......
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