|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Deadlocks by p2m_lock and event_lock
At 08:29 -0800 on 09 Mar (1331281767), Andres Lagar-Cavilla wrote:
> >> I don't know about the event lock, but it seems unwise to call in to
> >> handle_mmio with a gfn lock held. How about fixing the other path?
> >>
> >> diff -r 04673ecb9d78 xen/arch/x86/hvm/hvm.c
> >> --- a/xen/arch/x86/hvm/hvm.c Thu Mar 08 16:40:05 2012 +0000
> >> +++ b/xen/arch/x86/hvm/hvm.c Fri Mar 09 11:15:25 2012 +0000
> >> @@ -1324,10 +1324,11 @@ int hvm_hap_nested_page_fault(unsigned l
> >> if ( (p2mt == p2m_mmio_dm) ||
> >> (access_w && (p2mt == p2m_ram_ro)) )
> >> {
> >> + put_gfn(p2m->domain, gfn);
> >> if ( !handle_mmio() )
> >> hvm_inject_exception(TRAP_gp_fault, 0, 0);
> >> rc = 1;
> >> - goto out_put_gfn;
> >> + goto out;
> >> }
> >>
> >> #ifdef __x86_64__
> >> @@ -1379,6 +1380,7 @@ int hvm_hap_nested_page_fault(unsigned l
> >>
> >> out_put_gfn:
> >> put_gfn(p2m->domain, gfn);
> >> +out:
> >> if ( paged )
> >> p2m_mem_paging_populate(v->domain, gfn);
> >> if ( req_ptr )
> >
> > Yes, that's fine to release the p2m lock earlier than handle_mmio.
>
> Ack
OK, applied.
Tim.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |