Re: [PATCH v6 06/19] range: Introduce range_get_last_bit()

2024-06-03 Thread Eric Auger
On 6/3/24 08:10, Zhenzhong Duan wrote: > This helper get the highest 1 bit position of the upper bound. > > If the range is empty or upper bound is zero, -1 is returned. > > Suggested-by: Cédric Le Goater > Signed-off-by: Zhenzhong Duan Reviewed-by: Eric Auger Eric > --- > include/qemu/rang

[PATCH v6 06/19] range: Introduce range_get_last_bit()

2024-06-02 Thread Zhenzhong Duan
This helper get the highest 1 bit position of the upper bound. If the range is empty or upper bound is zero, -1 is returned. Suggested-by: Cédric Le Goater Signed-off-by: Zhenzhong Duan --- include/qemu/range.h | 11 +++ 1 file changed, 11 insertions(+) diff --git a/include/qemu/range