@@ -247,11 +247,19 @@ static void rxclass_print_nfc_rule(struct ethtool_rx_flow_spec *fsp)
rxclass_print_nfc_spec_ext(fsp);
- if (fsp->ring_cookie != RX_CLS_FLOW_DISC)
- fprintf(stdout, "\tAction: Direct to queue %llu\n",
- fsp->ring_cookie);
- else
+ if (fsp->ring_cookie != RX_CLS_FLOW_DISC) {
+ u64 vf = ethtool_get_flow_spec_ring_vf(fsp->ring_cookie);
+ u64 queue = ethtool_get_flow_spec_ring(fsp->ring_cookie);
+
+ if (vf)
+ fprintf(stdout, "\tAction: Direct to queue %llu\n",
+ queue);
+ else
+ fprintf(stdout, "\tAction: Direct to VF %llu queue %llu\n",
+ vf, queue);
+ } else {
fprintf(stdout, "\tAction: Drop\n");
+ }
fprintf(stdout, "\n");
}
Recent kernels have made the ring_cookie store both the Queue index as well as a VF identifier. This allows for drivers to direct traffic to specific VF queues, without having the user have to understand the physical queue layout. Add support to display this notation so that users do not have to manually parse the value. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> --- rxclass.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)