From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Beal Subject: (Patch) Save Registers for QEMU Monitor Commands Date: Wed, 03 Jan 2007 11:21:03 -0800 Message-ID: <1167852063.17482.6.camel@anthracite.dev.neuraliq.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-MpFiZkouttr408u5ej/A" Return-path: To: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org --=-MpFiZkouttr408u5ej/A Content-Type: text/plain Content-Transfer-Encoding: 7bit Hello, This patch adds a kvm_save_registers call before each command run in qemu monitor. This affects commands such as "info registers," "info tlb," and "info mem." This is to synchronize the cpu state so that monitor commands are more accurate. Best Regards, David Beal --=-MpFiZkouttr408u5ej/A Content-Disposition: attachment; filename=kvm_save_regs.diff Content-Type: text/x-patch; name=kvm_save_regs.diff; charset=us-ascii Content-Transfer-Encoding: 7bit Index: trunk/qemu/monitor.c =================================================================== --- trunk/qemu/monitor.c (revision 4252) +++ trunk/qemu/monitor.c (working copy) @@ -25,6 +25,9 @@ #include "disas.h" #include #include "migration.h" +#if USE_KVM +#include "qemu-kvm.h" +#endif //#define DEBUG //#define DEBUG_COMPLETION @@ -2231,6 +2234,15 @@ goto fail; } +#ifdef USE_KVM + if(1) + { + CPUState *env=mon_get_cpu(); + if (kvm_allowed) + kvm_save_registers(env); + } +#endif + switch(nb_args) { case 0: cmd->handler(); --=-MpFiZkouttr408u5ej/A Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV --=-MpFiZkouttr408u5ej/A Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kvm-devel mailing list kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org https://lists.sourceforge.net/lists/listinfo/kvm-devel --=-MpFiZkouttr408u5ej/A--