Commit f31076a6 authored by Alaa Mohamed's avatar Alaa Mohamed Committed by Boris Ostrovsky
Browse files

xen: Convert kmap() to kmap_local_page()



kmap() is being deprecated and these usages are all local to the thread
so there is no reason kmap_local_page() can't be used.

Replace kmap() calls with kmap_local_page().

Signed-off-by: default avatarAlaa Mohamed <eng.alaamohamedsoliman.am@gmail.com>
Reviewed-by: default avatarJuergen Gross <jgross@suse.com>
Link: https://lore.kernel.org/r/20220419234328.10346-1-eng.alaamohamedsoliman.am@gmail.com


Signed-off-by: default avatarBoris Ostrovsky <boris.ostrovsky@oracle.com>
parent 262fc47a
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -178,9 +178,9 @@ static void __del_gref(struct gntalloc_gref *gref)
	unsigned long addr;

	if (gref->notify.flags & UNMAP_NOTIFY_CLEAR_BYTE) {
		uint8_t *tmp = kmap(gref->page);
		uint8_t *tmp = kmap_local_page(gref->page);
		tmp[gref->notify.pgoff] = 0;
		kunmap(gref->page);
		kunmap_local(tmp);
	}
	if (gref->notify.flags & UNMAP_NOTIFY_SEND_EVENT) {
		notify_remote_via_evtchn(gref->notify.event);