diff options
author | Colin Foster <[email protected]> | 2022-02-10 07:04:51 -0800 |
---|---|---|
committer | Jakub Kicinski <[email protected]> | 2022-02-10 11:44:41 -0800 |
commit | 7fbf6795d127a3b1bb39b0e42579904cf6db1624 (patch) | |
tree | d0cb98a9fa64a98280eeea6e5c9456ae29900f63 /tools/testing/selftests/bpf/progs/test_autoload.c | |
parent | c4416f5c2eb3ed48dfba265e628a6e52da962f03 (diff) |
net: mscc: ocelot: fix mutex lock error during ethtool stats read
An ongoing workqueue populates the stats buffer. At the same time, a user
might query the statistics. While writing to the buffer is mutex-locked,
reading from the buffer wasn't. This could lead to buggy reads by ethtool.
This patch fixes the former blamed commit, but the bug was introduced in
the latter.
Signed-off-by: Colin Foster <[email protected]>
Fixes: 1e1caa9735f90 ("ocelot: Clean up stats update deferred work")
Fixes: a556c76adc052 ("net: mscc: Add initial Ocelot switch support")
Reported-by: Vladimir Oltean <[email protected]>
Reviewed-by: Vladimir Oltean <[email protected]>
Link: https://lore.kernel.org/all/[email protected]/
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/progs/test_autoload.c')
0 files changed, 0 insertions, 0 deletions