Skip to content

Commit be3e924

Browse files
committed
refactor(queue): remove do from do_pop_unchecked
Rename `do_pop_unchecked` to just `pop_unchecked`. Save couple bytes on the disk. Signed-off-by: Egor Lazarchuk <[email protected]>
1 parent 87d211a commit be3e924

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/vmm/src/devices/virtio/queue.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -522,7 +522,7 @@ impl Queue {
522522
return None;
523523
}
524524

525-
self.do_pop_unchecked()
525+
self.pop_unchecked()
526526
}
527527

528528
/// Try to pop the first available descriptor chain from the avail ring.
@@ -536,15 +536,15 @@ impl Queue {
536536
return None;
537537
}
538538

539-
self.do_pop_unchecked()
539+
self.pop_unchecked()
540540
}
541541

542542
/// Pop the first available descriptor chain from the avail ring.
543543
///
544544
/// # Important
545545
/// This is an internal method that ASSUMES THAT THERE ARE AVAILABLE DESCRIPTORS. Otherwise it
546546
/// will retrieve a descriptor that contains garbage data (obsolete/empty).
547-
fn do_pop_unchecked(&mut self) -> Option<DescriptorChain> {
547+
fn pop_unchecked(&mut self) -> Option<DescriptorChain> {
548548
// This fence ensures all subsequent reads see the updated driver writes.
549549
fence(Ordering::Acquire);
550550

0 commit comments

Comments
 (0)