On Tue, Sep 29, 2020 at 11:15:49AM +0100, Alex Dewar wrote:
> If the call to mlx5_fc_create() fails, then shared_counter will be freed
> before its member, shared_counter->counter, is accessed to retrieve the
> error code. Fix by using an intermediate variable.
>
> Addresses-Coverity: CID 1497153: Memory - illegal accesses (USE_AFTER_FREE)
> Fixes: 1edae2335adf ("net/mlx5e: CT: Use the same counter for both
> directions")
> Signed-off-by: Alex Dewar <[email protected]>
> ---
> v2:
> - Add Fixes tag (Leon)
> - Use ERR_CAST (Leon)
>
> Hi Leon,
>
> I've made the suggested changes. Let me know if there's anything else
> you need :)
Hi Alex,
Saeed already picked Dan's patch.
https://lore.kernel.org/linux-rdma/[email protected]/T/#t
>
> There is also this patch in the series which doesn't seem to have been
> reviewed yet:
> https://lore.kernel.org/lkml/[email protected]/
Ariel is handling this internally.
https://lore.kernel.org/linux-rdma/[email protected]/T/#t
Thanks