Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-07 Thread Julien Grall
Hi Linda, On 07/04/15 16:45, Linda wrote: >>> +size = (bitmap1->size > bitmap2->size) ? bitmap1->size : >>> bitmap2->size; >> There might be an 'max' macro somwhere in the code that you could use >> for this? > Any guesses on where I might find the max macro. When I grep max, all I > find are

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-07 Thread Linda
Hey Konrad, On 4/2/2015 1:34 PM, Konrad Rzeszutek Wilk wrote: On Thu, Apr 02, 2015 at 11:38:16AM -0600, Linda Jacobson wrote: From: Linda Added bitmap functions for union intersection and difference betweenn two bitmaps Signed-off-by: Linda --- tools/libxl/libxl_utils.c | 115 +++

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-07 Thread Wei Liu
Sorry for keeping you waiting. I just get back from vacation. First I would like to thank Dario and Konrad for their reviews. Their comments are quite to the point and you should fix your code as suggested. In addition to their comments, I have a few comments. See below. On Thu, Apr 02, 2015 at

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-03 Thread Dario Faggioli
On Thu, 2015-04-02 at 15:34 -0400, Konrad Rzeszutek Wilk wrote: > On Thu, Apr 02, 2015 at 11:38:16AM -0600, Linda Jacobson wrote: > > --- a/tools/libxl/libxl_utils.c > > +++ b/tools/libxl/libxl_utils.c > > +goto out; > > +} > > + > > +for (int bit = 0; bit < (size * 8); bit++) > >

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-03 Thread Dario Faggioli
On Fri, 2015-04-03 at 07:48 -0600, Linda wrote: > Dario, > Hi, One thing: here in the ML, please, don't top post. > I like your comments on naming. We'll see what others say. > As far as difference, at least as I've implemented it, it's the > exclusive or. > Well, then I'd call it lib

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-03 Thread Linda
Dario, I like your comments on naming. We'll see what others say. As far as difference, at least as I've implemented it, it's the exclusive or. To all, I've been thinking about Konrad's comment that we should disallow bitmaps of unequal size, in the XOR/difference function. I've i

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-03 Thread Dario Faggioli
On Thu, 2015-04-02 at 11:38 -0600, Linda Jacobson wrote: > From: Linda > > Added bitmap functions for union intersection and difference betweenn two > bitmaps > Just wondering, about union and intersection, are them the best names for these operations, or do we want libxl_bitmap_or() and libxl_

Re: [Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-02 Thread Konrad Rzeszutek Wilk
On Thu, Apr 02, 2015 at 11:38:16AM -0600, Linda Jacobson wrote: > From: Linda > > Added bitmap functions for union intersection and difference betweenn two > bitmaps > > Signed-off-by: Linda > --- > tools/libxl/libxl_utils.c | 115 > ++ > tools/lib

[Xen-devel] [PATCH] tools/libxl new bitmap functions

2015-04-02 Thread Linda Jacobson
From: Linda Added bitmap functions for union intersection and difference betweenn two bitmaps Signed-off-by: Linda --- tools/libxl/libxl_utils.c | 115 ++ tools/libxl/libxl_utils.h | 10 2 files changed, 125 insertions(+) diff --git a/tools/l