From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:46790) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SyRz0-0006ei-E2 for qemu-devel@nongnu.org; Mon, 06 Aug 2012 14:24:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SyRyz-0004W9-4d for qemu-devel@nongnu.org; Mon, 06 Aug 2012 14:24:50 -0400 Received: from mx1.redhat.com ([209.132.183.28]:29327) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SyRyy-0004Vi-Rp for qemu-devel@nongnu.org; Mon, 06 Aug 2012 14:24:49 -0400 Message-ID: <50200BEE.3090903@redhat.com> Date: Mon, 06 Aug 2012 21:24:46 +0300 From: Orit Wasserman MIME-Version: 1.0 References: <1344275489-28789-1-git-send-email-owasserm@redhat.com> <1344275489-28789-9-git-send-email-owasserm@redhat.com> <5020093F.7020506@redhat.com> In-Reply-To: <5020093F.7020506@redhat.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 08/12] Add migrate_set_cache_size command List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: peter.maydell@linaro.org, aliguori@us.ibm.com, quintela@redhat.com, stefanha@gmail.com, qemu-devel@nongnu.org, mdroth@linux.vnet.ibm.com, blauwirbel@gmail.com, Petter Svard , Benoit Hudzia , avi@redhat.com, Aidan Shribman , pbonzini@redhat.com, lcapitulino@redhat.com, chegu_vinod@hp.com On 08/06/2012 09:13 PM, Eric Blake wrote: > On 08/06/2012 11:51 AM, Orit Wasserman wrote: >> Change XBZRLE cache size in bytes (the size should be a power of 2, it will be >> rounded down to the nearest power of 2). >> If XBZRLE cache size is too small there will be many cache miss. >> >> New query-migrate-cache-size QMP command and 'info migrate_cache_size' HMP >> command to query cache value. >> >> Signed-off-by: Benoit Hudzia >> Signed-off-by: Petter Svard >> Signed-off-by: Aidan Shribman >> Signed-off-by: Orit Wasserman > >> +# >> +# Since: 1.2 >> +## >> +{ 'command': 'query-migrate-cache-size', 'returns': 'int' } > > This is the first 'returns':'int' in the schema, but we do have a > 'returns':'str' for comparison of returning a native type instead of a > further struct. > >> +Example: >> + >> +-> { "execute": "query-migrate-cache-size" } >> +<- { "return": { "67108864" } } > > Invalid JSON. Inside an {}, everything has to be in name:value pairs, > but you gave no name to your string. But given the above, you aren't > returning a string, but an int. I think this should be: > > { "return": 67108864 } > > That's based solely off my reading of the schema, and not of the code > itself, so please actually execute your code, to see what really came > over the wire. > you are right I will fix the example. Orit