[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v7 6/9] Add the facility to limit ranges per rangeset
> -----Original Message----- > From: Jan Beulich [mailto:JBeulich@xxxxxxxx] > Sent: 09 May 2014 14:23 > To: Paul Durrant > Cc: xen-devel@xxxxxxxxxxxxx; Keir (Xen.org) > Subject: Re: [PATCH v7 6/9] Add the facility to limit ranges per rangeset > > >>> On 09.05.14 at 10:40, <paul.durrant@xxxxxxxxxx> wrote: > > A subsequent patch exposes rangesets to secondary emulators, so to allow > a > > limit to be placed on the amount of xenheap that an emulator can cause to > be > > consumed, the function rangeset_limit() has been created to set the > allowed > > number of ranges in a rangeset. By default, there is no limit. > > > > Signed-off-by: Paul Durrant <paul.durrant@xxxxxxxxxx> > > Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx> > Thanks, Paul > albeit ... > > > --- a/xen/common/rangeset.c > > +++ b/xen/common/rangeset.c > > @@ -25,6 +25,9 @@ struct rangeset { > > > > /* Ordered list of ranges contained in this set, and protecting lock. > > */ > > struct list_head range_list; > > + > > + /* Number of ranges that can be allocated */ > > + long nr_ranges; > > I would have preferred this to be unsigned int (and to have the no- > limit case more explicitly handled by never decrementing the count > when it's e.g. UINT_MAX). > > Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |