[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] xen: 82599 passthrough problem



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@xxxxxxxxxx] 
Sent: Monday, May 16, 2016 5:56 PM
To: liuenliang; xen-devel@xxxxxxxxxxxxx
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@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.