Sun, May 27, 2018 at 11:17:26PM CEST, vla...@mellanox.com wrote:
>Return from action init function with reference to action taken,
>even when overwriting existing action.
>
>Action init API initializes its fourth argument (pointer to pointer to tc
>action) to either existing action with same index or newly created action.
>In case of existing index(and bind argument is zero), init function returns
>without incrementing action reference counter. Caller of action init then
>proceeds working with action, without actually holding reference to it.
>This means that action could be deleted concurrently.
>
>Change action init behavior to always take reference to action before
>returning successfully, in order to protect from concurrent deletion.
>
>Signed-off-by: Vlad Buslov <vla...@mellanox.com>

Signed-off-by: Jiri Pirko <j...@mellanox.com>

Reply via email to