From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54866) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wmlpm-0000pN-Ar for qemu-devel@nongnu.org; Tue, 20 May 2014 11:20:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wmlpe-0001K0-Dc for qemu-devel@nongnu.org; Tue, 20 May 2014 11:20:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:17903) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wmlpe-0001J8-58 for qemu-devel@nongnu.org; Tue, 20 May 2014 11:19:58 -0400 From: Igor Mammedov Date: Tue, 20 May 2014 17:15:24 +0200 Message-Id: <1400598934-31921-22-git-send-email-imammedo@redhat.com> In-Reply-To: <1400598934-31921-1-git-send-email-imammedo@redhat.com> References: <1400598934-31921-1-git-send-email-imammedo@redhat.com> Subject: [Qemu-devel] [PATCH v2 21/31] trace: pc: add DIMM slot & address allocation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, alex@alex.org.uk, mst@redhat.com, aik@ozlabs.ru, hutao@cn.fujitsu.com, mjt@tls.msk.ru, tangchen@cn.fujitsu.com, kraxel@redhat.com, pasteka@kabsi.at, s.priebe@profihost.ag, agarcia@igalia.com, armbru@redhat.com, aliguori@amazon.com, david@gibson.dropbear.id.au, lersek@redhat.com, ehabkost@redhat.com, marcel.a@redhat.com, stefanha@redhat.com, cornelia.huck@de.ibm.com, rth@twiddle.net, agraf@suse.de, andrey@xdel.ru, vasilis.liaskovitis@profitbricks.com, pbonzini@redhat.com, afaerber@suse.de, aurelien@aurel32.net Add mhp_pc_dimm_assigned_slot & mhp_pc_dimm_assigned_address events to trace which address and slot where assigned to plugged in DIMM device on target-i386 machine. Signed-off-by: Igor Mammedov --- hw/i386/pc.c | 3 +++ trace-events | 4 ++++ 2 files changed, 7 insertions(+), 0 deletions(-) diff --git a/hw/i386/pc.c b/hw/i386/pc.c index aee8dfb..b6c0ef9 100644 --- a/hw/i386/pc.c +++ b/hw/i386/pc.c @@ -59,6 +59,7 @@ #include "hw/pci/pci_host.h" #include "acpi-build.h" #include "hw/mem/dimm.h" +#include "trace.h" /* debug PC/ISA interrupts */ //#define DEBUG_IRQ @@ -1566,6 +1567,7 @@ static void pc_dimm_plug(HotplugHandler *hotplug_dev, if (local_err) { goto out; } + trace_mhp_pc_dimm_assigned_address(addr); slot = object_property_get_int(OBJECT(dev), DIMM_SLOT_PROP, &local_err); if (local_err) { @@ -1581,6 +1583,7 @@ static void pc_dimm_plug(HotplugHandler *hotplug_dev, if (local_err) { goto out; } + trace_mhp_pc_dimm_assigned_slot(slot); memory_region_add_subregion(&pcms->hotplug_memory, addr - pcms->hotplug_memory_base, mr); diff --git a/trace-events b/trace-events index 4f4c58f..d78f103 100644 --- a/trace-events +++ b/trace-events @@ -1265,3 +1265,7 @@ mhp_acpi_write_slot(uint32_t slot) "set active slot: 0x%"PRIx32 mhp_acpi_write_ost_ev(uint32_t slot, uint32_t ev) "slot[0x%"PRIx32"] OST EVENT: 0x%"PRIx32 mhp_acpi_write_ost_status(uint32_t slot, uint32_t st) "slot[0x%"PRIx32"] OST STATUS: 0x%"PRIx32 mhp_acpi_clear_insert_evt(uint32_t slot) "slot[0x%"PRIx32"] clear insert event" + +#hw/i386/pc.c +mhp_pc_dimm_assigned_slot(int slot) "0x%d" +mhp_pc_dimm_assigned_address(uint64_t addr) "0x%"PRIx64 -- 1.7.1