diff options
author | Jacob Keller <jacob.e.keller@intel.com> | 2018-07-31 03:41:41 -0700 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2018-08-07 08:19:09 -0700 |
commit | 1510ae0be2a4d4630823752235c41f8a0e06f37a (patch) | |
tree | 661889d322df8b6a84aaa3cfbb82f833c2e9f5d9 /scripts/decodecode | |
parent | 1ac2ee231f922d46cc7bb4c9f02eeb841b3e4b47 (diff) |
i40e: convert VEB TC stats to use an i40e_stats array
The VEB TC stats are currently implemented with separate parsing,
instead of using the i40e_stats array and associated helper functions.
This is likely because the stats rely on embedding the TC number into
the stat name.
Update i40e_add_stat_strings to take variadic arguments, and use these
to vsnprintf the i40e_stats string as a string containing format
specifiers.
Create a stats array for the VEB TC related stats,
i40e_gstrings_veb_tc_stats, and use this along with the helper functions
to remove the specialized boiler plate code.
Always call i40e_add_ethtool_stats for both this array and the general
VEB stats array. This ensures that we zero out any memory in case it was
not zero-allocated for us.
This ultimately results in less boiler plate code for the
i40e_get_stat_strings and i40e_get_ethtool_stats.
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'scripts/decodecode')
0 files changed, 0 insertions, 0 deletions