[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH RFC 1/2] xen/page_alloc: Add size_align parameter to provide MFNs which are size aligned.
>>> On 30.11.16 at 05:39, <konrad@xxxxxxxxxx> wrote: > This is to support the requirement that exists in PV dom0 > when doing DMA requests: > > "dma_alloc_coherent() > [...] > The CPU virtual address and the DMA address are both guaranteed to be > aligned to the smallest PAGE_SIZE order which is greater than or equal > to the requested size. This invariant exists (for example) to guarantee > that if you allocate a chunk which is smaller than or equal to 64 > kilobytes, the extent of the buffer you receive will not cross a 64K > boundary." So I'm having trouble understanding what it is that actually needs fixing / changing here: Any order-N allocation will be order-N-aligned already. Is your caller perhaps simply not passing in a large enough order? And changing alloc_heap_pages(), which guarantees the requested alignment already anyway (after all it takes an order input, not a size one), looks completely pointless regardless of what extra requirements you may want to put on the exchange hypercall. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |