From: Nikolay Aleksandrov
Date: Tue, 29 Oct 2019 13:45:52 +0200
> We'd like to have a well-defined behaviour when changing fdb flags. The
> problem is that we've added new fields which are changed from all
> contexts without any locking. We are aware of the bit test/change races
> and these are
No need to have separate arguments for each flag, just set the flags to
whatever was passed to fdb_create() before the fdb is published.
Signed-off-by: Nikolay Aleksandrov
---
net/bridge/br_fdb.c | 18 +++---
1 file changed, 7 insertions(+), 11 deletions(-)
diff --git
Convert the offloaded field to a flag and use bitops.
Signed-off-by: Nikolay Aleksandrov
---
net/bridge/br_fdb.c | 9 -
net/bridge/br_private.h | 2 +-
net/bridge/br_switchdev.c | 6 --
3 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/net/bridge/br_fdb.c
Straight-forward convert of the is_sticky field to bitops.
Signed-off-by: Nikolay Aleksandrov
---
net/bridge/br_fdb.c | 12 ++--
net/bridge/br_private.h | 4 ++--
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/net/bridge/br_fdb.c b/net/bridge/br_fdb.c
index
Convert the added_by_external_learn field to a flag and use bitops.
Signed-off-by: Nikolay Aleksandrov
---
net/bridge/br_fdb.c | 19 +--
net/bridge/br_private.h | 4 ++--
2 files changed, 11 insertions(+), 12 deletions(-)
diff --git a/net/bridge/br_fdb.c
The patch adds a new fdb flags field in the hole between the two cache
lines and uses it to convert is_local to bitops.
Signed-off-by: Nikolay Aleksandrov
---
net/bridge/br_fdb.c | 32 +++-
net/bridge/br_input.c | 2 +-
net/bridge/br_private.h | 9 +++--
Convert the is_static to bitops, make use of the combined
test_and_set/clear_bit to simplify expressions in fdb_add_entry.
Signed-off-by: Nikolay Aleksandrov
---
net/bridge/br_fdb.c | 40 +++-
net/bridge/br_private.h | 4 ++--
2 files changed, 21
Hi,
We'd like to have a well-defined behaviour when changing fdb flags. The
problem is that we've added new fields which are changed from all
contexts without any locking. We are aware of the bit test/change races
and these are fine (we can remove them later), but it is considered
undefined