All of lore.kernel.org
 help / color / mirror / Atom feed
* xen: 82599 passthrough problem
       [not found] <mailman.33246.1463368129.871.xen-devel@lists.xen.org>
@ 2016-05-16  3:41 ` liuenliang
  2016-05-16  9:56   ` Andrew Cooper
  2016-05-17  8:41   ` Jan Beulich
  0 siblings, 2 replies; 5+ messages in thread
From: liuenliang @ 2016-05-16  3:41 UTC (permalink / raw)
  To: xen-devel; +Cc: Fanhenglong, Hanweidong (Randy)

Hi,all:

I also met this problem when passthrough 82599 to domU by SRIOV, and the call stack as follows:
(XEN) Xen call trace:
(XEN)    [<ffff82c480140143>] panic+0xc3/0x1a0
(XEN)    [<ffff82c480126f62>] symbols_lookup+0x22/0x2a0
(XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
(XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
(XEN)    [<ffff82c48012750a>] __print_symbol+0x8a/0xc0
(XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
(XEN)    [<ffff82c48018d430>] show_stack+0x110/0x180
(XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
(XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
(XEN)    [<ffff82c48018e274>] do_invalid_op+0x394/0x420
(XEN)    [<ffff82c4802218f8>] handle_exception_saved+0x30/0x6e
(XEN)    [<ffff82c48016ed76>] __pirq_guest_unbind+0x2d6/0x340
(XEN)    [<ffff82c48016ce04>] domain_spin_lock_irq_desc+0x64/0xa0
(XEN)    [<ffff82c48016f1dd>] pirq_guest_unbind+0x5d/0x160
(XEN)    [<ffff82c480146b89>] pci_release_devices+0x129/0x220
(XEN)    [<ffff82c480164028>] domain_relinquish_resources+0xa8/0x2a0
(XEN)    [<ffff82c4801054e4>] domain_kill+0x84/0x100
(XEN)    [<ffff82c480103364>] do_domctl+0x9c4/0x1620
(XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d


1) The version of xen-syms is xen-syms-4.1.2_115 and the passthrough is done via 'pci='. 
2) I using qemu-xen, and the version is 1.2.2.
3) This happens when I reboot the guest(HVM), but not happens all the time.

BTW, the bug "corruption  caused by race conditions between device allocation and deallocation to a domain." is fixed.(the link is:
http://xenbits.xen.org/gitweb/?p=xen.git;a=commit;h=15a9f34d1b1a6c50f2da046a6e4c6726a230d089)

So, anyone who knows what is the problem and any advices? Thanks.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: xen: 82599 passthrough problem
  2016-05-16  3:41 ` xen: 82599 passthrough problem liuenliang
@ 2016-05-16  9:56   ` Andrew Cooper
  2016-05-17  2:13     ` liuenliang
  2016-05-17  8:41   ` Jan Beulich
  1 sibling, 1 reply; 5+ messages in thread
From: Andrew Cooper @ 2016-05-16  9:56 UTC (permalink / raw)
  To: liuenliang, xen-devel; +Cc: Fanhenglong, Hanweidong (Randy)

On 16/05/16 04:41, liuenliang wrote:
> Hi,all:
>
> I also met this problem when passthrough 82599 to domU by SRIOV, and the call stack as follows:
> (XEN) Xen call trace:
> (XEN)    [<ffff82c480140143>] panic+0xc3/0x1a0
> (XEN)    [<ffff82c480126f62>] symbols_lookup+0x22/0x2a0
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c48012750a>] __print_symbol+0x8a/0xc0
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c48018d430>] show_stack+0x110/0x180
> (XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
> (XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
> (XEN)    [<ffff82c48018e274>] do_invalid_op+0x394/0x420
> (XEN)    [<ffff82c4802218f8>] handle_exception_saved+0x30/0x6e
> (XEN)    [<ffff82c48016ed76>] __pirq_guest_unbind+0x2d6/0x340
> (XEN)    [<ffff82c48016ce04>] domain_spin_lock_irq_desc+0x64/0xa0
> (XEN)    [<ffff82c48016f1dd>] pirq_guest_unbind+0x5d/0x160
> (XEN)    [<ffff82c480146b89>] pci_release_devices+0x129/0x220
> (XEN)    [<ffff82c480164028>] domain_relinquish_resources+0xa8/0x2a0
> (XEN)    [<ffff82c4801054e4>] domain_kill+0x84/0x100
> (XEN)    [<ffff82c480103364>] do_domctl+0x9c4/0x1620
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
>
>
> 1) The version of xen-syms is xen-syms-4.1.2_115 and the passthrough is done via 'pci='. 
> 2) I using qemu-xen, and the version is 1.2.2.
> 3) This happens when I reboot the guest(HVM), but not happens all the time.
>
> BTW, the bug "corruption  caused by race conditions between device allocation and deallocation to a domain." is fixed.(the link is:
> http://xenbits.xen.org/gitweb/?p=xen.git;a=commit;h=15a9f34d1b1a6c50f2da046a6e4c6726a230d089)
>
> So, anyone who knows what is the problem and any advices? Thanks.

There are several things going on there.

First of all, you look to have hit a BUG or a WARN:

(XEN)    [<ffff82c48016ed76>] __pirq_guest_unbind+0x2d6/0x340

and while trying to dump the stack to the console, you hit a further
panic in:

(XEN)    [<ffff82c480126f62>] symbols_lookup+0x22/0x2a0

For the first one, use addr2line on your debug symbols to find which
BUG() you hit, which might help you diagnose the issue.

For the second one, is there any further information from the panic on
the console?

~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: xen: 82599 passthrough problem
  2016-05-16  9:56   ` Andrew Cooper
@ 2016-05-17  2:13     ` liuenliang
  0 siblings, 0 replies; 5+ messages in thread
From: liuenliang @ 2016-05-17  2:13 UTC (permalink / raw)
  To: Andrew Cooper, xen-devel; +Cc: Fanhenglong, Hanweidong (Randy)

Thank you for your reply.
For the first question, the BUG I hit is :

static irq_guest_action_t *__pirq_guest_unbind(
    struct domain *d, int pirq, struct irq_desc *desc)
{
    unsigned int        irq;
    irq_guest_action_t *action;
    cpumask_t           cpu_eoi_map;
    int                 i;

    action = (irq_guest_action_t *)desc->action;
    irq = desc - irq_desc;

    if ( unlikely(action == NULL) )
    {
        dprintk(XENLOG_G_WARNING, "dom%d: pirq %d: desc->action is NULL!\n",
                d->domain_id, pirq);
        return NULL;
    }

    BUG_ON(!(desc->status & IRQ_GUEST));

    for ( i = 0; (i < action->nr_guests) && (action->guest[i] != d); i++ ) 
        continue;

    BUG_ON(i == action->nr_guests);	 // (This BUG_ON is hit)

For the second question, there are no more information from the panic on the console, and I do not care about that because I trigger panic when BUG_ON is hit. 
So my question is what the reason of the BUG_ON is, and how can I fix it.
Thanks.

--------
Enliang Liu
Best Regards

-----Original Message-----
From: Andrew Cooper [mailto:andrew.cooper3@citrix.com] 
Sent: Monday, May 16, 2016 5:56 PM
To: liuenliang; xen-devel@lists.xen.org
Cc: Fanhenglong; Hanweidong (Randy)
Subject: Re: [Xen-devel] xen: 82599 passthrough problem

On 16/05/16 04:41, liuenliang wrote:
> Hi,all:
>
> I also met this problem when passthrough 82599 to domU by SRIOV, and the call stack as follows:
> (XEN) Xen call trace:
> (XEN)    [<ffff82c480140143>] panic+0xc3/0x1a0
> (XEN)    [<ffff82c480126f62>] symbols_lookup+0x22/0x2a0
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c48012750a>] __print_symbol+0x8a/0xc0
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c48018d430>] show_stack+0x110/0x180
> (XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
> (XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
> (XEN)    [<ffff82c48018e274>] do_invalid_op+0x394/0x420
> (XEN)    [<ffff82c4802218f8>] handle_exception_saved+0x30/0x6e
> (XEN)    [<ffff82c48016ed76>] __pirq_guest_unbind+0x2d6/0x340
> (XEN)    [<ffff82c48016ce04>] domain_spin_lock_irq_desc+0x64/0xa0
> (XEN)    [<ffff82c48016f1dd>] pirq_guest_unbind+0x5d/0x160
> (XEN)    [<ffff82c480146b89>] pci_release_devices+0x129/0x220
> (XEN)    [<ffff82c480164028>] domain_relinquish_resources+0xa8/0x2a0
> (XEN)    [<ffff82c4801054e4>] domain_kill+0x84/0x100
> (XEN)    [<ffff82c480103364>] do_domctl+0x9c4/0x1620
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
>
>
> 1) The version of xen-syms is xen-syms-4.1.2_115 and the passthrough is done via 'pci='. 
> 2) I using qemu-xen, and the version is 1.2.2.
> 3) This happens when I reboot the guest(HVM), but not happens all the time.
>
> BTW, the bug "corruption  caused by race conditions between device allocation and deallocation to a domain." is fixed.(the link is:
> http://xenbits.xen.org/gitweb/?p=xen.git;a=commit;h=15a9f34d1b1a6c50f2
> da046a6e4c6726a230d089)
>
> So, anyone who knows what is the problem and any advices? Thanks.

There are several things going on there.

First of all, you look to have hit a BUG or a WARN:

(XEN)    [<ffff82c48016ed76>] __pirq_guest_unbind+0x2d6/0x340

and while trying to dump the stack to the console, you hit a further panic in:

(XEN)    [<ffff82c480126f62>] symbols_lookup+0x22/0x2a0

For the first one, use addr2line on your debug symbols to find which
BUG() you hit, which might help you diagnose the issue.

For the second one, is there any further information from the panic on the console?

~Andrew
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: xen: 82599 passthrough problem
  2016-05-16  3:41 ` xen: 82599 passthrough problem liuenliang
  2016-05-16  9:56   ` Andrew Cooper
@ 2016-05-17  8:41   ` Jan Beulich
  1 sibling, 0 replies; 5+ messages in thread
From: Jan Beulich @ 2016-05-17  8:41 UTC (permalink / raw)
  To: liuenliang; +Cc: Fanhenglong, xen-devel, Hanweidong (Randy)

>>> On 16.05.16 at 05:41, <liuenliang@huawei.com> wrote:
> I also met this problem when passthrough 82599 to domU by SRIOV, and the 
> call stack as follows:
> (XEN) Xen call trace:
> (XEN)    [<ffff82c480140143>] panic+0xc3/0x1a0
> (XEN)    [<ffff82c480126f62>] symbols_lookup+0x22/0x2a0
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c48012750a>] __print_symbol+0x8a/0xc0
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> (XEN)    [<ffff82c48018d430>] show_stack+0x110/0x180
> (XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
> (XEN)    [<ffff82c48016ed78>] __pirq_guest_unbind+0x2d8/0x340
> (XEN)    [<ffff82c48018e274>] do_invalid_op+0x394/0x420
> (XEN)    [<ffff82c4802218f8>] handle_exception_saved+0x30/0x6e
> (XEN)    [<ffff82c48016ed76>] __pirq_guest_unbind+0x2d6/0x340
> (XEN)    [<ffff82c48016ce04>] domain_spin_lock_irq_desc+0x64/0xa0
> (XEN)    [<ffff82c48016f1dd>] pirq_guest_unbind+0x5d/0x160
> (XEN)    [<ffff82c480146b89>] pci_release_devices+0x129/0x220
> (XEN)    [<ffff82c480164028>] domain_relinquish_resources+0xa8/0x2a0
> (XEN)    [<ffff82c4801054e4>] domain_kill+0x84/0x100
> (XEN)    [<ffff82c480103364>] do_domctl+0x9c4/0x1620
> (XEN)    [<ffff82c480221468>] syscall_enter+0x88/0x8d
> 
> 
> 1) The version of xen-syms is xen-syms-4.1.2_115 and the passthrough is done 
> via 'pci='. 

I guess we first of all need to know whether this is an issue on
newer, still maintained versions of Xen - 4.1.x has been out of
maintenance for quite some time.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* xen: 82599 passthrough problem
@ 2016-02-03  1:37 Norton.Zhu
  0 siblings, 0 replies; 5+ messages in thread
From: Norton.Zhu @ 2016-02-03  1:37 UTC (permalink / raw)
  To: xen-devel

Hi,

I met a problem when passthrough 82599 to domU(for some reasons, I use pci passthrough not SRIOV).
It works well after passthrough, but the host hung after destroy domU.
Btw, no log prints even from serial port, but I found it hung afer unbind irq.
anyone knows what's wrong with it? thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-05-17  8:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <mailman.33246.1463368129.871.xen-devel@lists.xen.org>
2016-05-16  3:41 ` xen: 82599 passthrough problem liuenliang
2016-05-16  9:56   ` Andrew Cooper
2016-05-17  2:13     ` liuenliang
2016-05-17  8:41   ` Jan Beulich
2016-02-03  1:37 Norton.Zhu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.