From e3427410c930ca828acbe0e75737a99a4d304499 Mon Sep 17 00:00:00 2001 From: hselasky Date: Mon, 9 Jan 2017 17:16:14 +0000 Subject: MFC r310557: Use correct integer type when computing the maximum physical address for kmem_alloc_contig(). Obtained from: kmacy @ Sponsored by: Mellanox Technologies --- sys/compat/linuxkpi/common/include/linux/gfp.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/compat/linuxkpi/common/include/linux') diff --git a/sys/compat/linuxkpi/common/include/linux/gfp.h b/sys/compat/linuxkpi/common/include/linux/gfp.h index e1f14b0..1c73022 100644 --- a/sys/compat/linuxkpi/common/include/linux/gfp.h +++ b/sys/compat/linuxkpi/common/include/linux/gfp.h @@ -136,8 +136,8 @@ alloc_pages(gfp_t gfp_mask, unsigned int order) size_t size; size = PAGE_SIZE << order; - page = kmem_alloc_contig(kmem_arena, size, gfp_mask, 0, -1, - size, 0, VM_MEMATTR_DEFAULT); + page = kmem_alloc_contig(kmem_arena, size, gfp_mask, + 0, ~(vm_paddr_t)0, size, 0, VM_MEMATTR_DEFAULT); if (page == 0) return (NULL); return (virt_to_page(page)); -- cgit v1.1