|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH] xen/swiotlb: don't initialize swiotlb twice on arm64
Hi, On 23/05/2019 00:26, Stefano Stabellini wrote: From: Stefano Stabellini <stefanos@xxxxxxxxxx> On arm64 swiotlb is already initialized by mem_init. We don't want to Arm64 will not always initialize the swiotlb. It will only be done if the user force it or there are memory above the DMA limit. initialize it twice, the memory is already allocated. Detect this condition in swiotlb-xen and skip the second initialization. I understand that the memory allocated by swiotlb will be replaced with freeing memory. So you at least have a memory leak. However, the logic to allocate the memory is quite different. For instance, AFAICT, swiotlb will allocate low pages while xen swiotlb will alloc any pages. So I think your commit message should contain a bit more details on the implication. I vaguely remember that on Xilinx on needed to use low memory as much as possible. Is this patch actually trying to fix that?
Rather than adding an extra if in a already difficult code to read. Can we move the allocation in a separate function and only call it if necessary?
Cheers, -- Julien Grall _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |