net_util: queue_pair: Remove unnecessary mut from reference

warning: this argument is a mutable reference, but not used mutably
   --> net_util/src/queue_pair.rs:167:14
    |
167 |         tap: &mut Tap,
    |              ^^^^^^^^ help: consider changing to: `&Tap`
    |
    = warning: changing this function will impact semver compatibility
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut

Signed-off-by: Rob Bradford <rbradford@rivosinc.com>
This commit is contained in:
Rob Bradford 2023-08-22 10:44:09 +01:00 committed by Rob Bradford
parent 11c58870c4
commit 5636d91524

View File

@ -38,7 +38,7 @@ impl TxVirtio {
pub fn process_desc_chain( pub fn process_desc_chain(
&mut self, &mut self,
mem: &GuestMemoryMmap, mem: &GuestMemoryMmap,
tap: &mut Tap, tap: &Tap,
queue: &mut Queue, queue: &mut Queue,
rate_limiter: &mut Option<RateLimiter>, rate_limiter: &mut Option<RateLimiter>,
access_platform: Option<&Arc<dyn AccessPlatform>>, access_platform: Option<&Arc<dyn AccessPlatform>>,
@ -164,7 +164,7 @@ impl RxVirtio {
pub fn process_desc_chain( pub fn process_desc_chain(
&mut self, &mut self,
mem: &GuestMemoryMmap, mem: &GuestMemoryMmap,
tap: &mut Tap, tap: &Tap,
queue: &mut Queue, queue: &mut Queue,
rate_limiter: &mut Option<RateLimiter>, rate_limiter: &mut Option<RateLimiter>,
access_platform: Option<&Arc<dyn AccessPlatform>>, access_platform: Option<&Arc<dyn AccessPlatform>>,
@ -357,7 +357,7 @@ impl NetQueuePair {
) -> Result<bool, NetQueuePairError> { ) -> Result<bool, NetQueuePairError> {
let tx_tap_retry = self.tx.process_desc_chain( let tx_tap_retry = self.tx.process_desc_chain(
mem, mem,
&mut self.tap, &self.tap,
queue, queue,
&mut self.tx_rate_limiter, &mut self.tx_rate_limiter,
self.access_platform.as_ref(), self.access_platform.as_ref(),
@ -407,7 +407,7 @@ impl NetQueuePair {
) -> Result<bool, NetQueuePairError> { ) -> Result<bool, NetQueuePairError> {
self.rx_desc_avail = !self.rx.process_desc_chain( self.rx_desc_avail = !self.rx.process_desc_chain(
mem, mem,
&mut self.tap, &self.tap,
queue, queue,
&mut self.rx_rate_limiter, &mut self.rx_rate_limiter,
self.access_platform.as_ref(), self.access_platform.as_ref(),