]> git.baikalelectronics.ru Git - kernel.git/commit
hwrng: virtio - always add a pending request
authorLaurent Vivier <lvivier@redhat.com>
Thu, 28 Oct 2021 10:11:11 +0000 (12:11 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Mon, 1 Nov 2021 09:26:47 +0000 (05:26 -0400)
commit27da5faafc5d9a2aca60d7169ea6d238091def95
treeeb4288b405a7821130982fc69ace34f1f76d8d36
parent115dba6c893aec6cc45f7e60e894278e8c39912f
hwrng: virtio - always add a pending request

If we ensure we have already some data available by enqueuing
again the buffer once data are exhausted, we can return what we
have without waiting for the device answer.

Signed-off-by: Laurent Vivier <lvivier@redhat.com>
Link: https://lore.kernel.org/r/20211028101111.128049-5-lvivier@redhat.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/char/hw_random/virtio-rng.c