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

Re: [Xen-devel] Xen-unstable: AMD-Vi: update_paging_mode Try to access pdev_list without aquiring pcidevs_lock.



On 30.10.2019 23:21, Sander Eikelenboom wrote:
> Call trace seems to be the same in all cases.
> 
> --
> Sander
> 
> 
> (XEN) [2019-10-30 22:07:05.748] AMD-Vi: update_paging_mode Try to access 
> pdev_list without aquiring pcidevs_lock.
> (XEN) [2019-10-30 22:07:05.748] ----[ Xen-4.13.0-rc  x86_64  debug=y   Not 
> tainted ]----
> (XEN) [2019-10-30 22:07:05.748] CPU:    1
> (XEN) [2019-10-30 22:07:05.748] RIP:    e008:[<ffff82d080265748>] 
> iommu_map.c#update_paging_mode+0x1f2/0x3eb
> (XEN) [2019-10-30 22:07:05.748] RFLAGS: 0000000000010286   CONTEXT: 
> hypervisor (d0v2)

I didn't pay attention to this when writing my earlier reply: The
likely culprit looks to be f89f555827 ("remove late (on-demand)
construction of IOMMU page tables"). Prior to this I assume IOMMU
page tables got constructed only after ...

> (XEN) [2019-10-30 22:07:05.748] Xen call trace:
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d080265748>] R 
> iommu_map.c#update_paging_mode+0x1f2/0x3eb
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d080265ded>] F 
> amd_iommu_map_page+0x72/0x1c2
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d0802583b6>] F iommu_map+0x98/0x17e
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d0802586fb>] F 
> iommu_legacy_map+0x28/0x73
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d08034a4a6>] F 
> p2m-pt.c#p2m_pt_set_entry+0x4d3/0x844
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d080342e13>] F 
> p2m_set_entry+0x91/0x128
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d080343c52>] F 
> guest_physmap_add_entry+0x39f/0x5a3
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d080343f85>] F 
> guest_physmap_add_page+0x12f/0x138
> (XEN) [2019-10-30 22:07:05.748]    [<ffff82d0802201ee>] F 
> memory.c#populate_physmap+0x2e3/0x505

... Dom0 had populated the new guest's physmap.

Anyway, as odd as it may seem I guess there's little choice
besides making populate_physmap() (and likely a few others)
acquire the lock.

Jan

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

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