[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 01/20] host-utils: add ffsl
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [PATCH 01/20] host-utils: add ffsl |
Date: |
Wed, 12 Dec 2012 16:41:51 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 |
On 12/12/2012 06:46 AM, Paolo Bonzini wrote:
> We can provide fast versions based on the other functions defined
> by host-utils.h. Some care is required on glibc, which provides
> ffsl already.
>
> Signed-off-by: Paolo Bonzini <address@hidden>
> ---
> host-utils.h | 26 ++++++++++++++++++++++++++
> 1 file changed, 26 insertions(+)
Reviewed-by: Eric Blake <address@hidden>
>
> diff --git a/host-utils.h b/host-utils.h
> index 821db93..231d580 100644
> --- a/host-utils.h
> +++ b/host-utils.h
> @@ -24,6 +24,7 @@
> */
>
> #include "compiler.h" /* QEMU_GNUC_PREREQ */
> +#include <string.h> /* ffsl */
I never really understood why ffs() is in <strings.h> but ffsl() is in
<string.h>, especially when neither function deals with strings (a
<bitops.h> header would have made more sense), but such is life.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH 14/20] hbitmap: add hbitmap_alloc_with_data and hbitmap_required_size, (continued)
- [Qemu-devel] [PATCH 15/20] hbitmap: add hbitmap_copy, Paolo Bonzini, 2012/12/12
- [Qemu-devel] [PATCH 16/20] block: split bdrv_enable_dirty_tracking and bdrv_disable_dirty_tracking, Paolo Bonzini, 2012/12/12
- [Qemu-devel] [PATCH 18/20] mirror: add support for persistent dirty bitmap, Paolo Bonzini, 2012/12/12
- [Qemu-devel] [PATCH 19/20] block: choose the default dirty bitmap granularity in bdrv_enable_dirty_tracking, Paolo Bonzini, 2012/12/12
- [Qemu-devel] [PATCH 01/20] host-utils: add ffsl, Paolo Bonzini, 2012/12/12
- Re: [Qemu-devel] [PATCH 01/20] host-utils: add ffsl,
Eric Blake <=
- [Qemu-devel] [PATCH 17/20] block: support a persistent dirty bitmap, Paolo Bonzini, 2012/12/12
- [Qemu-devel] [PATCH 20/20] monitor: add commands to start/stop dirty bitmap, Paolo Bonzini, 2012/12/12