net/mlx5: Fix uninitialized variable warning

Add variable initialization to eliminate the warning
"variable may be used uninitialized".

Fixes: 5f29458b77d5 ("net/mlx5e: Support dump callback in TX reporter")
Signed-off-by: Moshe Tal <moshet@mellanox.com>
Reviewed-by: Aya Levin <ayal@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
This commit is contained in:
Moshe Tal 2020-07-16 14:59:30 +03:00 committed by Saeed Mahameed
parent ed6d9b0228
commit 19f5b63bc9

View File

@ -242,8 +242,8 @@ static int mlx5e_health_rsc_fmsg_binary(struct devlink_fmsg *fmsg,
{
u32 data_size;
int err = 0;
u32 offset;
int err;
for (offset = 0; offset < value_len; offset += data_size) {
data_size = value_len - offset;