patch-2.4.25 linux-2.4.25/arch/ia64/kernel/sys_ia64.c

Next file: linux-2.4.25/arch/ia64/kernel/time.c
Previous file: linux-2.4.25/arch/ia64/kernel/setup.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.24/arch/ia64/kernel/sys_ia64.c linux-2.4.25/arch/ia64/kernel/sys_ia64.c
@@ -15,6 +15,7 @@
 #include <linux/smp.h>
 #include <linux/smp_lock.h>
 #include <linux/highuid.h>
+#include <linux/hugetlb.h>
 
 #include <asm/shmparam.h>
 #include <asm/uaccess.h>
@@ -29,6 +30,10 @@
 
 	if (len > RGN_MAP_LIMIT)
 		return -ENOMEM;
+#ifdef CONFIG_HUGETLB_PAGE
+	if (rgn_index(addr)==REGION_HPAGE)
+		addr = 0;
+#endif
 	if (!addr)
 		addr = TASK_UNMAPPED_BASE;
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)