qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 2/2] virtio-blk: Convert QEMUBH callback to "bitops.h" API


From: Richard Henderson
Subject: Re: [PATCH v2 2/2] virtio-blk: Convert QEMUBH callback to "bitops.h" API
Date: Fri, 7 May 2021 10:26:18 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1

On 5/7/21 10:06 AM, Philippe Mathieu-Daudé wrote:
By directly using find_first_bit() and find_next_bit from the
"bitops.h" API to iterate over the bitmap, we can remove the
bitmap[] variable-length array copy on the stack and the complex
manual bit testing/clearing logic.

Suggested-by: Stefan Hajnoczi<stefanha@redhat.com>
Suggested-by: Richard Henderson<richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé<philmd@redhat.com>
---
  hw/block/dataplane/virtio-blk.c | 19 ++++---------------
  1 file changed, 4 insertions(+), 15 deletions(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]