From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=35738 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PPfjW-0002oz-II for qemu-devel@nongnu.org; Mon, 06 Dec 2010 13:24:20 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PPfjV-00046w-Ke for qemu-devel@nongnu.org; Mon, 06 Dec 2010 13:24:18 -0500 Received: from mx1.redhat.com ([209.132.183.28]:47617) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PPfjV-00046p-EY for qemu-devel@nongnu.org; Mon, 06 Dec 2010 13:24:17 -0500 From: Luiz Capitulino Date: Mon, 6 Dec 2010 16:23:47 -0200 Message-Id: <1291659852-23028-1-git-send-email-lcapitulino@redhat.com> Subject: [Qemu-devel] [PATCH v1 00/25]: Monitor: First step on an internal QMP API List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: aliguori@us.ibm.com, armbru@redhat.com Today, when writing an info command that is used by QMP and HMP, the programmer has to implement: 1. The handler itself, that's the function that gathers data and returns it as QObjects 2. A pretty printing function, which is called by the human monitor to print the returned QObjects in human readable form However, we want to have a clean separation between QMP and the human monitor. Actually, we want to turn QMP into an internal API and the human monitor should be written on top of that. So, this series does: 1. Move all QMP calling code to the info handler using it, that's we change the pretty printing function to call QMP and turn it into an info handler 2. Drop all QMP calling code from do_info() Please, note that this is only done for info handlers. Command handlers will take a bit more time to be converted. balloon.c | 26 +----- balloon.h | 2 +- block.c | 16 ++- block.h | 8 +- console.h | 8 +- hw/pci.c | 9 ++- hw/pci.h | 4 +- input.c | 11 ++- migration.c | 13 ++- migration.h | 4 +- monitor.c | 341 +++++++++++++++++++++++++++-------------------------------- qemu-char.c | 10 ++- qemu-char.h | 4 +- ui/vnc.c | 11 ++- 14 files changed, 227 insertions(+), 240 deletions(-)