diff options
author | 2020-03-27 11:55:23 +0300 | |
---|---|---|
committer | 2020-03-27 15:06:43 -0700 | |
commit | e1da9618b785366bed7d175ab6599f897119b87b (patch) | |
tree | 2b72149ef7d94f450c57d56202d89542c2dbdca1 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | mlxsw: spectrum: Remove unused RIF and FID families (diff) | |
download | wireguard-linux-e1da9618b785366bed7d175ab6599f897119b87b.tar.xz wireguard-linux-e1da9618b785366bed7d175ab6599f897119b87b.zip |
mlxsw: core_acl: Avoid defining static variable in header file
The static array 'mlxsw_afk_element_infos' in 'core_acl_flex_keys.h' is
copied to each file that includes the header, but not all use it. This
results in the following warnings when compiling with W=1:
drivers/net/ethernet/mellanox/mlxsw//core_acl_flex_keys.h:76:44:
warning: ‘mlxsw_afk_element_infos’ defined but not used
[-Wunused-const-variable=]
One way to suppress the warning is to mark the array with
'__maybe_unused', but another option is to remove it from the header
file entirely.
Change 'struct mlxsw_afk_element_inst' to store the key to the array
('element') instead of the array value keyed by 'element'. Adjust the
different users accordingly.
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions