diff options
| author | Vladimir Oltean <[email protected]> | 2021-06-29 14:06:44 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2021-06-29 17:46:22 +0000 |
| commit | 3e19ae7c6fd62978ae518b17ae0e30ab8d17ed07 (patch) | |
| tree | a2a0d43193565df027b20c7b63a36a1ffe8e3a99 /net/unix/af_unix.c | |
| parent | Merge branch 'do_once_lite' (diff) | |
| download | kernel-3e19ae7c6fd62978ae518b17ae0e30ab8d17ed07.tar.gz kernel-3e19ae7c6fd62978ae518b17ae0e30ab8d17ed07.zip | |
net: bridge: use READ_ONCE() and WRITE_ONCE() compiler barriers for fdb->dst
Annotate the writer side of fdb->dst:
- fdb_create()
- br_fdb_update()
- fdb_add_entry()
- br_fdb_external_learn_add()
with WRITE_ONCE() and the reader side:
- br_fdb_test_addr()
- br_fdb_update()
- fdb_fill_info()
- fdb_add_entry()
- fdb_delete_by_addr_and_port()
- br_fdb_external_learn_add()
- br_switchdev_fdb_notify()
with compiler barriers such that the readers do not attempt to reload
fdb->dst multiple times, leading to potentially different destination
ports when the fdb entry is updated concurrently.
This is especially important in read-side sections where fdb->dst is
used more than once, but let's convert all accesses for the sake of
uniformity.
Suggested-by: Nikolay Aleksandrov <[email protected]>
Signed-off-by: Vladimir Oltean <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions
