Repository navigation
Commit e3931a5
committed
vhost: fix panic on update_config call when device is not active
There is a window in time when the vhost device is not yet initialized
by the guest, but the user already sends the request to update its
config. Though this is an unlikely scenario, fix it by actually checking
the `active_state` instead of asserting on it.
Signed-off-by: Egor Lazarchuk <yegorlz@amazon.co.uk>1 parent 59141ff commit e3931a5
2 files changed
Lines changed: 10 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
267 | 267 | | |
268 | 268 | | |
269 | 269 | | |
270 | | - | |
271 | | - | |
272 | | - | |
273 | | - | |
274 | | - | |
275 | | - | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
276 | 275 | | |
277 | 276 | | |
278 | 277 | | |
| |||
732 | 731 | | |
733 | 732 | | |
734 | 733 | | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
735 | 737 | | |
736 | 738 | | |
737 | 739 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
23 | 25 | | |
24 | 26 | | |
25 | 27 | | |
| |||
0 commit comments