[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <9abbe24a-395f-0e89-e090-b29da0e71514@nvidia.com>
Date: Thu, 27 Apr 2023 08:52:42 +0300
From: Paul Blakey <paulb@...dia.com>
To: Vlad Buslov <vladbu@...dia.com>, davem@...emloft.net,
kuba@...nel.org
Cc: netdev@...r.kernel.org, jhs@...atatu.com, xiyou.wangcong@...il.com,
jiri@...nulli.us, marcelo.leitner@...il.com,
simon.horman@...igine.com
Subject: Re: [PATCH net 2/2] net/sched: flower: fix error handler on replace
On 26/04/2023 15:14, Vlad Buslov wrote:
> When replacing a filter (i.e. 'fold' pointer is not NULL) the insertion of
> new filter to idr is postponed until later in code since handle is already
> provided by the user. However, the error handling code in fl_change()
> always assumes that the new filter had been inserted into idr. If error
> handler is reached when replacing existing filter it may remove it from idr
> therefore making it unreachable for delete or dump afterwards. Fix the
> issue by verifying that 'fold' argument wasn't provided by caller before
> calling idr_remove().
>
> Fixes: 08a0063df3ae ("net/sched: flower: Move filter handle initialization earlier")
> Signed-off-by: Vlad Buslov <vladbu@...dia.com>
Reviewed-by: Paul Blakey <paulb@...dia.com>
Powered by blists - more mailing lists