Skip to content

Commit

Permalink
Fix clippy lint warnings. (#118)
Browse files Browse the repository at this point in the history
  • Loading branch information
qwandor authored Nov 14, 2023
1 parent 3da64ea commit 4b60f5d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/device/gpu.rs
Original file line number Diff line number Diff line change
Expand Up @@ -174,18 +174,18 @@ impl<H: Hal, T: Transport> VirtIOGpu<H, T> {

/// Send a request to the device and block for a response.
fn request<Req: AsBytes, Rsp: FromBytes>(&mut self, req: Req) -> Result<Rsp> {
req.write_to_prefix(&mut *self.queue_buf_send).unwrap();
req.write_to_prefix(&mut self.queue_buf_send).unwrap();
self.control_queue.add_notify_wait_pop(
&[&self.queue_buf_send],
&mut [&mut self.queue_buf_recv],
&mut self.transport,
)?;
Ok(Rsp::read_from_prefix(&*self.queue_buf_recv).unwrap())
Ok(Rsp::read_from_prefix(&self.queue_buf_recv).unwrap())
}

/// Send a mouse cursor operation request to the device and block for a response.
fn cursor_request<Req: AsBytes>(&mut self, req: Req) -> Result {
req.write_to_prefix(&mut *self.queue_buf_send).unwrap();
req.write_to_prefix(&mut self.queue_buf_send).unwrap();
self.cursor_queue.add_notify_wait_pop(
&[&self.queue_buf_send],
&mut [],
Expand Down

0 comments on commit 4b60f5d

Please sign in to comment.