Commit e1915a67 authored by Denis Efremov's avatar Denis Efremov Committed by Saeed Mahameed
Browse files

net/mlx5e: Use kfree() to free fd->g in accel_fs_tcp_create_groups()



Memory ft->g in accel_fs_tcp_create_groups() is allocaed with kcalloc().
It's excessive to free ft->g with kvfree(). Use kfree() instead.

Signed-off-by: default avatarDenis Efremov <efremov@linux.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
parent 22db4c24
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -191,7 +191,7 @@ static int accel_fs_tcp_create_groups(struct mlx5e_flow_table *ft,
	ft->g = kcalloc(MLX5E_ACCEL_FS_TCP_NUM_GROUPS, sizeof(*ft->g), GFP_KERNEL);
	in = kvzalloc(inlen, GFP_KERNEL);
	if  (!in || !ft->g) {
		kvfree(ft->g);
		kfree(ft->g);
		kvfree(in);
		return -ENOMEM;
	}