Commit 9c5d291
virtio_console: fix misc probe bugs
BugLink: https://bugs.launchpad.net/bugs/2097301
[ Upstream commit b9efbe2 ]
This fixes the following issue discovered by code review:
after vqs have been created, a buggy device can send an interrupt.
A control vq callback will then try to schedule control_work which has
not been initialized yet. Similarly for config interrupt. Further, in
and out vq callbacks invoke find_port_by_vq which attempts to take
ports_lock which also has not been initialized.
To fix, init all locks and work before creating vqs.
Message-ID: <ad982e975a6160ad110c623c016041311ca15b4f.1726511547.git.mst@redhat.com>
Fixes: 17634ba ("virtio: console: Add a new MULTIPORT feature, support for generic ports")
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Manuel Diewald <manuel.diewald@canonical.com>
Signed-off-by: Koichiro Den <koichiro.den@canonical.com>1 parent e511df6 commit 9c5d291
1 file changed
+10
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2016 | 2016 | | |
2017 | 2017 | | |
2018 | 2018 | | |
2019 | | - | |
2020 | | - | |
2021 | | - | |
2022 | | - | |
2023 | | - | |
2024 | | - | |
2025 | 2019 | | |
2026 | 2020 | | |
2027 | 2021 | | |
2028 | 2022 | | |
2029 | | - | |
2030 | | - | |
2031 | 2023 | | |
2032 | 2024 | | |
2033 | 2025 | | |
2034 | 2026 | | |
2035 | 2027 | | |
2036 | 2028 | | |
| 2029 | + | |
2037 | 2030 | | |
| 2031 | + | |
| 2032 | + | |
| 2033 | + | |
| 2034 | + | |
| 2035 | + | |
| 2036 | + | |
| 2037 | + | |
| 2038 | + | |
| 2039 | + | |
2038 | 2040 | | |
2039 | 2041 | | |
2040 | 2042 | | |
| |||
0 commit comments