Re: [PATCH 1/2] hwrng: virtio - use min() in copy_data()

From: Herbert Xu

Date: Fri Oct 02 2026 - 06:32:41 EST


On Sat, Sep 26, 2026 at 07:58:54AM +0200, Thorsten Blum wrote:
> Use the simpler min() macro since all values are unsigned and
> compatible. The subtraction avail - vi->data_idx is also guaranteed to
> be positive by the preceding check.
>
> Signed-off-by: Thorsten Blum <blum@xxxxxxxxxx>
> ---
> drivers/char/hw_random/virtio-rng.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)

All applied. Thanks.
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt