fn rx_single_frame(&mut self, mut queue: &mut Queue) -> Result<bool> {
        let mem = self.mem.as_ref().ok_or(Error::NoMemoryConfigured)?;

        let next_desc = queue.iter(&mem).next();

        if next_desc.is_none() {
            // Queue has no available descriptors
            if self.rx_tap_listening {
                self.vring_worker
                    .as_ref()
                    .unwrap()
                    .unregister_listener(self.tap.as_raw_fd(), epoll::Events::EPOLLIN, 2)
                    .unwrap();
                self.rx_tap_listening = false;
            }
            return Ok(false);
        }

        let write_complete = self.rx.process_desc_chain(&mem, next_desc, &mut queue);

        Ok(write_complete)
    }
// Copies a single frame from `self.rx.frame_buf` into the guest. Returns true
// if a buffer was used, and false if the frame must be deferred until a buffer
// is made available by the driver.
Copies a single frame from `self.rx.frame_buf` into the guest. Returns true
if a buffer was used, and false if the frame must be deferred until a buffer
is made available by the driver.
Copies a single frame from ` self . rx . frame_buf ` into the guest . Returns true if a buffer was used and false if the frame must be deferred until a buffer is made available by the driver .
fn rx_single_frame(&mut self, mut queue: &mut Queue) -> Result<bool> {
        let mem = self.mem.as_ref().ok_or(Error::NoMemoryConfigured)?;
        let next_desc = queue.iter(&mem).next();
        if next_desc.is_none() {
            // Queue has no available descriptors
            if self.rx_tap_listening {
                self.vring_worker
                    .as_ref()
                    .unwrap()
                    .unregister_listener(self.tap.as_raw_fd(), epoll::Events::EPOLLIN, 2)
                    .unwrap();
                self.rx_tap_listening = false;
            }
            return Ok(false);
        }
        let write_complete = self.rx.process_desc_chain(&mem, next_desc, &mut queue);
        Ok(write_complete)
    }
fn rx_single_frame ( & mut self , mut queue : & mut Queue ) -> Result < bool > { let mem = self . mem . as_ref ( ) . ok_or ( Error :: NoMemoryConfigured ) ? ; let next_desc = queue . iter ( & mem ) . next ( ) ; if next_desc . is_none ( ) { // Queue has no available descriptors if self . rx_tap_listening { self . vring_worker . as_ref ( ) . unwrap ( ) . unregister_listener ( self . tap . as_raw_fd ( ) , epoll :: Events :: EPOLLIN , 2 ) . unwrap ( ) ; self . rx_tap_listening = false ; } return Ok ( false ) ; } let write_complete = self . rx . process_desc_chain ( & mem , next_desc , & mut queue ) ; Ok ( write_complete ) }
Copies a single frame from `self.rx.frame_buf` into the guest.
Copies a single frame from ` self . rx . frame_buf ` into the guest .
&mut self
queue
&mut Queue
&mut self
queue
&mut Queue