From: "Jan Beulich" Subject: Re: MSI causing softpanics in guest Date: Mon, 22 Sep 2008 09:12:17 +0100 Message-ID: <48D76F81.76E4.0078.0@novell.com> References: <48D40332.5090706@cc.gatech.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Anish Bhatt , Keir Fraser Cc: xen-devel@lists.xensource.com, haitao.shan@intel.com List-Id: xen-devel@lists.xenproject.org >>> Keir Fraser 20.09.08 10:15 >>> >On 3.3.0 you need to specify msi=3D1 on Xen's command line to enable MSI. = In >xen-unstable, MSI support is always enabled. > >I changed a check in evtchn_get_xen_pirq() into a BUG_ON() as it looks to = me >like it should never trigger. Jan Beulich was the original authour of = that >function -- cc'ed in case he can indicate whether I've actually broken = the >function. :-) No, I think that BUG_ON() you added is valid. It definitely is in the = context of startup_pirq(). I'd be curious to know what the type of that irq really = is, but that cannot be determined from the backtrace alone. Anish, could you perhaps add a simple printk() before the BUG_ON()? Unfortunately the driver in question does not appear to be part of the tree, so we can't = even check what it does prior to calling request_irq()... -- Keir On 19/9/08 20:53, "Anish Bhatt" wrote: > lspci shows MSI enabled for PCI device. PCI passthrough works fine. > However, as soon as the MSI driver for card is insmodded, kernel panics. > This is on xen-unstable. Tried the same with xen-3.3.0 which is > supposed to have MSI passthrough, but the same guest shows MSI as = disabled. > Any else seen this bug, or know of a workaround ? >=20 > Trace is as follows : >=20 > ------------[ cut here ]------------ > kernel BUG at=20 >=20 /usr/src/xen/xen-unstable.hg/linux-2.6.18-xen.hg/drivers/xen/core/evtchn.c:= 809> ! > invalid opcode: 0000 [#1] > SMP > Modules linked in: nfemsg nfdvnet ipv6 binfmt_misc dm_mod nfe usbcore > ext3 jbd processor fuse > CPU: 0 > EIP: 0061:[] Tainted: GF VLI > EFLAGS: 00210097 (2.6.18.8-xen #2) > EIP is at evtchn_get_xen_pirq+0x35/0x40 > eax: ffffffff ebx: 00000002 ecx: c0372e60 edx: 00000000 > esi: c2103560 edi: c03d3080 ebp: 000004f9 esp: ed385dac > ds: 007b es: 007b ss: 0069 > Process modprobe (pid: 2590, ti=3Ded384000 task=3Ded7b1100 task.ti=3Ded38= 4000) > Stack: c0248aef 00000000 00000000 00000000 00000000 00000000 00000000 > 00000000 > 00000000 00000000 00000000 00000000 00000000 00000000 00000000 > 00000000 > 00000000 00000000 00000000 00000000 00000000 00000000 00000000 > 00000000 > Call Trace: > [] startup_pirq+0x3f/0x250 > [] setup_irq+0x160/0x1b0 > [] nfe_interrupt_handler+0x0/0x30 [nfemsg] > [] request_irq+0xa3/0xc0 > [] nfemsg_module_init+0x8ad/0x133e [nfemsg] > [] cond_resched+0x2b/0x40 > [] wait_for_completion+0x19/0xf0 > [] sys_init_module+0x148/0x1b50 > [] syscall_call+0x7/0xb > Code: 00 00 89 d1 d3 e0 85 05 c4 2c 42 c0 74 1a 8b 14 95 c0 c0 44 c0 89 > d0 c1 e8 1c 83 e8 01 75 0c c1 ea 0c 81 e2 ff ff 00 00 89 d0 c3 <0f> 0b > 29 03 a4 f1 32 c0 eb ea 90 83 ec 08 89 74 24 04 89 c6 a1 > EIP: [] evtchn_get_xen_pirq+0x35/0x40 SS:ESP 0069:ed385dac > ### card [0] start: host progs ### > -bash-3.2# > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: ------------[ cut here ]------------ >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: kernel BUG at >=20 /usr/src/xen/xen-unstable.hg/linux-2.6.18-xen.hg/drivers/xen/core/evtchn.c:= 809> ! >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: invalid opcode: 0000 [#1] >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: SMP >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: CPU: 0 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: EIP is at evtchn_get_xen_pirq+0x35/0x40 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: eax: ffffffff ebx: 00000002 ecx: c0372e60 edx: 00000000 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: esi: c2103560 edi: c03d3080 ebp: 000004f9 esp: ed385dac >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: ds: 007b es: 007b ss: 0069 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: Process modprobe (pid: 2590, ti=3Ded384000 task=3Ded7b1100 > task.ti=3Ded384000) >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: Stack: c0248aef 00000000 00000000 00000000 00000000 00000000 > 00000000 00000000 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: 00000000 00000000 00000000 00000000 00000000 00000000 > 00000000 00000000 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: 00000000 00000000 00000000 00000000 00000000 00000000 > 00000000 00000000 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: Call Trace: >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: Code: 00 00 89 d1 d3 e0 85 05 c4 2c 42 c0 74 1a 8b 14 95 c0 c0 > 44 c0 89 d0 c1 e8 1c 83 e8 01 75 0c c1 ea 0c 81 e2 ff ff 00 00 89 d0 c3 > <0f> 0b 29 03 a4 f1 32 c0 eb ea 90 83 ec 08 89 74 24 04 89 c6 a1 >=20 > Message from syslogd@drake at Sep 19 15:36:44 ... > kernel: EIP: [] evtchn_get_xen_pirq+0x35/0x40 SS:ESP > 0069:ed385dac