Commit eab2b40
committed
fix(mmio): avoid locking multiple times in same code branch
MMIO transport layer holds a Mutex to the VirtIO device. Within the
logic that handles the handshake between the driver and the device,
there were cases where we would take and release the lock multiple times
within the same code branch.
Change this to only take the lock once.
Signed-off-by: Babis Chalios <[email protected]>1 parent 6cf32b9 commit eab2b40
1 file changed
+15
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
179 | 179 | | |
180 | 180 | | |
181 | 181 | | |
182 | | - | |
| 182 | + | |
| 183 | + | |
183 | 184 | | |
184 | 185 | | |
185 | | - | |
186 | | - | |
187 | | - | |
| 186 | + | |
| 187 | + | |
188 | 188 | | |
189 | 189 | | |
190 | 190 | | |
| |||
201 | 201 | | |
202 | 202 | | |
203 | 203 | | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
211 | 214 | | |
| 215 | + | |
212 | 216 | | |
213 | | - | |
214 | 217 | | |
215 | 218 | | |
216 | 219 | | |
| |||
0 commit comments