]> git.baikalelectronics.ru Git - kernel.git/commit
amt: use READ_ONCE() in amt module
authorTaehee Yoo <ap420073@gmail.com>
Sun, 17 Jul 2022 16:09:05 +0000 (16:09 +0000)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 19 Jul 2022 10:37:02 +0000 (12:37 +0200)
commitcb186ccb716ad44983d20755f70ceb5698512946
tree737f628a1b97aa91a61be68c10865d9b454ca384
parent839271738e842d21ea0aa4d4947b84929edf6083
amt: use READ_ONCE() in amt module

There are some data races in the amt module.
amt->ready4, amt->ready6, and amt->status can be accessed concurrently
without locks.
So, it uses READ_ONCE() and WRITE_ONCE().

Fixes: 565d46b7231c ("amt: add data plane of amt interface")
Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/amt.c