xen/xenbus: Fix granting of vmalloc'd memory
authorSimon Leiner <simon@leiner.me>
Tue, 25 Aug 2020 09:31:52 +0000 (11:31 +0200)
committerJuergen Gross <jgross@suse.com>
Thu, 27 Aug 2020 06:58:48 +0000 (08:58 +0200)
commitd742db70033c745e410523e00522ee0cfe2aa416
treefa7839e4a938daccf8f881ea913926950bd31e8f
parentc330fb1ddc0a922f044989492b7fcca77ee1db46
xen/xenbus: Fix granting of vmalloc'd memory

On some architectures (like ARM), virt_to_gfn cannot be used for
vmalloc'd memory because of its reliance on virt_to_phys. This patch
introduces a check for vmalloc'd addresses and obtains the PFN using
vmalloc_to_pfn in that case.

Signed-off-by: Simon Leiner <simon@leiner.me>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Link: https://lore.kernel.org/r/20200825093153.35500-1-simon@leiner.me
Signed-off-by: Juergen Gross <jgross@suse.com>
drivers/xen/xenbus/xenbus_client.c