Commit faa03c60 authored by Al Viro's avatar Al Viro Committed by Tim Gardner

page_to_phys() always returns a multiple of PAGE_SIZE

BugLink: http://bugs.launchpad.net/bugs/1558624Acked-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
(cherry picked from commit bdb97e91)
Signed-off-by: default avatarTim Gardner <tim.gardner@canonical.com>
parent efac9846
......@@ -366,8 +366,7 @@ static void *s390_dma_alloc(struct device *dev, size_t size,
pa = page_to_phys(page);
memset((void *) pa, 0, size);
map = s390_dma_map_pages(dev, page, pa % PAGE_SIZE,
size, DMA_BIDIRECTIONAL, NULL);
map = s390_dma_map_pages(dev, page, 0, size, DMA_BIDIRECTIONAL, NULL);
if (dma_mapping_error(dev, map)) {
free_pages(pa, get_order(size));
return NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment