Skip to content

Commit

Permalink
net/sfc/base: fix manual filter delete in EF10
Browse files Browse the repository at this point in the history
[ upstream commit 977424c ]

When user requests a filter deletion only filter with
manual priority must be deleted. When an automatic filter has
the same specification, it must be skipped.

Fixes: 585c22e ("net/sfc/base: handle manual and auto filter clashes in EF10")

Signed-off-by: Igor Romanov <igor.romanov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
  • Loading branch information
ol-igorrom authored and kevintraynor committed Jun 5, 2020
1 parent b4b8b0a commit 55db8ea
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/sfc/base/ef10_filter.c
Original file line number Diff line number Diff line change
Expand Up @@ -1172,7 +1172,8 @@ ef10_filter_delete(
i = (hash + depth) & (EFX_EF10_FILTER_TBL_ROWS - 1);
saved_spec = ef10_filter_entry_spec(table, i);
if (saved_spec && ef10_filter_equal(spec, saved_spec) &&
ef10_filter_same_dest(spec, saved_spec)) {
ef10_filter_same_dest(spec, saved_spec) &&
saved_spec->efs_priority == EFX_FILTER_PRI_MANUAL) {
break;
}
if (depth == EF10_FILTER_SEARCH_LIMIT) {
Expand Down

0 comments on commit 55db8ea

Please sign in to comment.