diff options
author | Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com> | 2020-05-04 01:56:44 -0700 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2020-05-09 16:18:36 -0600 |
commit | 7e764179c86784594d54764556c4d3973645e6a5 (patch) | |
tree | 87c687425c15f0667a543c4f360aecdcbbf04744 /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | 45e2f3c2d2f5f39b47745cba41e9e2b0c58d7d94 (diff) |
nvmet: use type-name map for address family
Right now nvmet_addr_adrfam_[store|show]() uses switch and if else
ladder for address family to string and reverse mapping which also
repeats the strings in show and store function.
With addition of generic nvmet_type_name_map structure we can now get rid
of the switch and if else ladder and string duplication.
Also, we add a newline in before found label in nvmet_addr_trtype_store()
which keeps goto label code consistent with
nvmet_allowed_hosts_drop_link(), nvmet_port_subsys_drop_link() and
nvmet_ana_group_ana_state_store().
Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions