Re: [Qemu-devel] [PATCH v5 4/6] block: convert ThrottleGroup to object with QOM

2017-08-21 Thread Alberto Garcia
On Sat 19 Aug 2017 09:08:59 AM CEST, Manos Pitsidianakis wrote: >>> +if (tg->name) { >>> +/* error if name is duplicate */ >>> +QTAILQ_FOREACH(iter, _groups, list) { >>> +if (!g_strcmp0(tg->name, iter->name) && tg != iter) { >> >>I'm just nitpicking here :) but if

Re: [Qemu-devel] [PATCH v5 4/6] block: convert ThrottleGroup to object with QOM

2017-08-19 Thread Manos Pitsidianakis
On Fri, Aug 18, 2017 at 03:05:31PM +0200, Alberto Garcia wrote: On Fri 18 Aug 2017 05:10:17 AM CEST, Manos Pitsidianakis wrote: * If no ThrottleGroup is found with the given name a new one is * created. * - * @name: the name of the ThrottleGroup + * This function edits throttle_groups

Re: [Qemu-devel] [PATCH v5 4/6] block: convert ThrottleGroup to object with QOM

2017-08-18 Thread Alberto Garcia
On Fri 18 Aug 2017 05:10:17 AM CEST, Manos Pitsidianakis wrote: > * If no ThrottleGroup is found with the given name a new one is > * created. > * > - * @name: the name of the ThrottleGroup > + * This function edits throttle_groups and must be called under the global > + * mutex. > + * > +

[Qemu-devel] [PATCH v5 4/6] block: convert ThrottleGroup to object with QOM

2017-08-17 Thread Manos Pitsidianakis
ThrottleGroup is converted to an object. This will allow the future throttle block filter drive easy creation and configuration of throttle groups in QMP and cli. A new QAPI struct, ThrottleLimits, is introduced to provide a shared struct for all throttle configuration needs in QMP.