Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

RDMA/mlx5: Init dest_type when create flow

When using action drop dest_type was never assigned to any value. Add
initialization of dest_type to -1 since 0 is valid.

Fixes: f29de9eee782 ("RDMA/mlx5: Add support for drop action in DV steering")
Link: https://lore.kernel.org/r/20200707110259.882276-1-leon@kernel.org
Signed-off-by: Daria Velikovsky <daria@mellanox.com>
Reviewed-by: Maor Gottlieb <maorg@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>

authored by

Daria Velikovsky and committed by
Jason Gunthorpe
0829d2da 420bd9e2

+1 -1
+1 -1
drivers/infiniband/hw/mlx5/fs.c
··· 1903 1903 struct mlx5_flow_context flow_context = {.flow_tag = 1904 1904 MLX5_FS_DEFAULT_FLOW_TAG}; 1905 1905 u32 *offset_attr, offset = 0, counter_id = 0; 1906 - int dest_id, dest_type, inlen, len, ret, i; 1906 + int dest_id, dest_type = -1, inlen, len, ret, i; 1907 1907 struct mlx5_ib_flow_handler *flow_handler; 1908 1908 struct mlx5_ib_flow_matcher *fs_matcher; 1909 1909 struct ib_uobject **arr_flow_actions;