Thread (27 messages) 27 messages, 5 authors, 2024-07-30

RE: [PATCH] xen: introduce xen_vring_use_dma

From: Stefano Stabellini <sstabellini@kernel.org>
Date: 2020-06-29 23:49:12
Also in: linux-iommu, lkml, virtualization, xen-devel

On Mon, 29 Jun 2020, Peng Fan wrote:
quoted
quoted
If that is the case, how is it possible that virtio breaks on ARM
using the default dma_ops? The breakage is not Xen related (except
that Xen turns dma_ops on). The original message from Peng was:

  vring_map_one_sg -> vring_use_dma_api
                   -> dma_map_page
  		       -> __swiotlb_map_page
  		                ->swiotlb_map_page
  				->__dma_map_area(phys_to_virt(dma_to_phys(dev,
dev_addr)), size, dir);
quoted
  However we are using per device dma area for rpmsg, phys_to_virt
  could not return a correct virtual address for virtual address in
  vmalloc area. Then kernel panic.

I must be missing something. Maybe it is because it has to do with RPMesg?
I think it's an RPMesg bug, yes
rpmsg bug is another issue, it should not use dma_alloc_coherent for reserved area,
and use vmalloc_to_page.

Anyway here using dma api will also trigger issue.
Is the stack trace above for the RPMesg issue or for the Trusty issue?
If it is the stack trace for RPMesg, can you also post the Trusty stack
trace? Or are they indentical?

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help