From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=58189 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PDf3l-00033g-Tv for qemu-devel@nongnu.org; Wed, 03 Nov 2010 11:15:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PDf3k-0004zI-Iw for qemu-devel@nongnu.org; Wed, 03 Nov 2010 11:15:33 -0400 Received: from mx1.redhat.com ([209.132.183.28]:22155) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PDf3k-0004zB-C0 for qemu-devel@nongnu.org; Wed, 03 Nov 2010 11:15:32 -0400 Message-ID: <4CD17C8F.8070506@redhat.com> Date: Wed, 03 Nov 2010 16:15:27 +0100 From: Gerd Hoffmann MIME-Version: 1.0 Subject: Re: [Qemu-devel] MSI broken? References: <4CD14173.7000007@redhat.com> <20101103123446.GB26077@valinux.co.jp> <4CD1585B.2010200@redhat.com> <20101103133718.GC26077@valinux.co.jp> In-Reply-To: <20101103133718.GC26077@valinux.co.jp> Content-Type: multipart/mixed; boundary="------------050607080502040608040503" List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Isaku Yamahata Cc: "qemu-devel@nongnu.org" This is a multi-part message in MIME format. --------------050607080502040608040503 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hi, >>> Let's track it down futher. >>> Were acpi_mem_writel() and apic_send_msi() in hw/apic.c called or not? >> >> No such function in my tree (savannah/master). >> >> Looks like some bits needed for msi are not merged yet? > > Sorry typo. s/acpi/apic/. The attached patch gives me: msi_notify:243 intel-hda:30 notify vector 0x0 address: 0xfee01008 data: 0x4151 apic_send_msi:775 dest 1 vector 81 dest_mode 0 trigger_mode 0 delivery 1 apic_find_dest:443 no apic found for dest 1 cheers, Gerd --------------050607080502040608040503 Content-Type: text/plain; name="debug.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="debug.diff" diff --git a/hw/apic.c b/hw/apic.c index 63d62c7..9b3ba10 100644 --- a/hw/apic.c +++ b/hw/apic.c @@ -439,6 +439,8 @@ static int apic_find_dest(uint8_t dest) return i; } + fprintf(stderr, "%s:%d no apic found for dest %d\n", + __FUNCTION__, __LINE__, dest); return -1; } @@ -769,6 +771,8 @@ static void apic_send_msi(target_phys_addr_t addr, uint32 data) uint8_t trigger_mode = (data >> MSI_DATA_TRIGGER_SHIFT) & 0x1; uint8_t delivery = (data >> MSI_DATA_DELIVERY_MODE_SHIFT) & 0x7; /* XXX: Ignore redirection hint. */ + fprintf(stderr, "%s:%d dest %d vector %d dest_mode %d trigger_mode %d delivery %d\n", + __FUNCTION__, __LINE__, dest, vector, dest_mode, trigger_mode, delivery); apic_deliver_irq(dest, dest_mode, delivery, vector, 0, trigger_mode); } --------------050607080502040608040503--