From 8cf87dd59ff7f58db2a449c05d15f3315244d466 Mon Sep 17 00:00:00 2001 From: Vladimir Kondratyev Date: Wed, 29 Sep 2021 23:14:47 +0300 Subject: [PATCH] LinuxKPI: Cast offset_in_page() parameter to unsigned long to reduce number of patches in drm-kmod Reviewed by: hselasky Differential revision: https://reviews.freebsd.org/D32093 (cherry picked from commit 37eba5b77a5733ac711b119141619c89b8446471) --- sys/compat/linuxkpi/common/include/linux/mm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/mm.h b/sys/compat/linuxkpi/common/include/linux/mm.h index dc75ae4483c..871d16cb06f 100644 --- a/sys/compat/linuxkpi/common/include/linux/mm.h +++ b/sys/compat/linuxkpi/common/include/linux/mm.h @@ -229,7 +229,7 @@ vma_pages(struct vm_area_struct *vma) return ((vma->vm_end - vma->vm_start) >> PAGE_SHIFT); } -#define offset_in_page(off) ((off) & (PAGE_SIZE - 1)) +#define offset_in_page(off) ((unsigned long)(off) & (PAGE_SIZE - 1)) static inline void set_page_dirty(struct vm_page *page)