In the Linux kernel, the following vulnerability has been resolved:
media: v4l2-mem2mem: add lock to protect parameter num_rdy
Getting below error when using KCSAN to check the driver. Adding lock to protect parameter num_rdy when getting the value with function: v4l2_m2m_num_src_bufs_ready/v4l2_m2m_num_dst_bufs_ready.
kworker/u16:3: [name:report&]BUG: KCSAN: data-race in v4l2_m2m_buf_queue kworker/u16:3: [name:report&]
kworker/u16:3: [name:report&]read-write to 0xffffff8105f35b94 of 1 bytes by task 20865 on cpu 7: kworker/u16:3: v4l2_m2m_buf_queue+0xd8/0x10c
| Software | From | Fixed in |
|---|---|---|
| linux / linux_kernel | 2.6.39 | 4.14.324 |
| linux / linux_kernel | 4.15 | 4.19.293 |
| linux / linux_kernel | 4.20 | 5.4.255 |
| linux / linux_kernel | 5.5 | 5.10.192 |
| linux / linux_kernel | 5.11 | 5.15.128 |
| linux / linux_kernel | 5.16 | 6.1.47 |
| linux / linux_kernel | 6.2 | 6.4.12 |