summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-sqlite.py
diff options
context:
space:
mode:
authorIvan Vecera <ivecera@redhat.com>2023-10-13 19:07:52 +0200
committerDavid S. Miller <davem@davemloft.net>2023-10-15 14:33:41 +0100
commit7aabde397683263fd8aa146f97cc0846372e0719 (patch)
tree670420867e771fdab9c60c79d6648e0378794950 /tools/perf/scripts/python/export-to-sqlite.py
parent9e479d64dc58f11792f638ea2e8eff3304edaabf (diff)
i40e: Split and refactor i40e_nvm_version_str()
The function formats NVM version string according adapter's EETrackID value. If this value OEM specific (0xffffffff) then the reported version is with format: "<gen>.<snap>.<release>" and in other case "<nvm_maj>.<nvm_min> <eetrackid> <cvid_maj>.<cvid_bld>.<cvid_min>" These versions are reported in the subsequent patch in this series that implements devlink .info_get but separately. So split the function into separate ones, refactor it to use them and remove ugly static string buffer. Additionally convert NVM/OEM version mask macros to use GENMASK and use FIELD_GET/FIELD_PREP for them in i40e_nvm_version_str() and i40e_get_oem_version(). This makes code more readable and allows us to remove related shift macros. Signed-off-by: Ivan Vecera <ivecera@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions