@@ -339,7 +339,7 @@ impl Balloon {
339
339
340
340
// Acknowledge the receipt of the descriptor.
341
341
// 0 is number of bytes the device has written to memory.
342
- queue. add_used ( head. index , 0 ) . map_err ( BalloonError :: Queue ) ?;
342
+ queue. add_used ( head. index , 0 ) ?;
343
343
needs_interrupt = true ;
344
344
}
345
345
@@ -376,7 +376,7 @@ impl Balloon {
376
376
let mut needs_interrupt = false ;
377
377
378
378
while let Some ( head) = queue. pop ( ) {
379
- queue. add_used ( head. index , 0 ) . map_err ( BalloonError :: Queue ) ?;
379
+ queue. add_used ( head. index , 0 ) ?;
380
380
needs_interrupt = true ;
381
381
}
382
382
@@ -397,9 +397,7 @@ impl Balloon {
397
397
// We shouldn't ever have an extra buffer if the driver follows
398
398
// the protocol, but return it if we find one.
399
399
error ! ( "balloon: driver is not compliant, more than one stats buffer received" ) ;
400
- self . queues [ STATS_INDEX ]
401
- . add_used ( prev_stats_desc, 0 )
402
- . map_err ( BalloonError :: Queue ) ?;
400
+ self . queues [ STATS_INDEX ] . add_used ( prev_stats_desc, 0 ) ?;
403
401
}
404
402
for index in ( 0 ..head. len ) . step_by ( SIZE_OF_STAT ) {
405
403
// Read the address at position `index`. The only case
@@ -447,9 +445,7 @@ impl Balloon {
447
445
// The communication is driven by the device by using the buffer
448
446
// and sending a used buffer notification
449
447
if let Some ( index) = self . stats_desc_index . take ( ) {
450
- self . queues [ STATS_INDEX ]
451
- . add_used ( index, 0 )
452
- . map_err ( BalloonError :: Queue ) ?;
448
+ self . queues [ STATS_INDEX ] . add_used ( index, 0 ) ?;
453
449
self . signal_used_queue ( )
454
450
} else {
455
451
error ! ( "Failed to update balloon stats, missing descriptor." ) ;
0 commit comments