All of lore.kernel.org
 help / color / mirror / Atom feed
* [7/7] hugetlb: make private functions static
@ 2002-11-06  2:30 William Lee Irwin III
  2002-11-06  6:26 ` hugetlb: No coalescing of adjacent mappings in /proc/pid/maps dada1
  0 siblings, 1 reply; 2+ messages in thread
From: William Lee Irwin III @ 2002-11-06  2:30 UTC (permalink / raw)
  To: linux-kernel

This patch makes various private structures and procedures static.

 hugetlbpage.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)


diff -urpN hugetlbfs-2.5.46-5/arch/i386/mm/hugetlbpage.c hugetlbfs-2.5.46-6/arch/i386/mm/hugetlbpage.c
--- hugetlbfs-2.5.46-5/arch/i386/mm/hugetlbpage.c	2002-11-05 13:59:05.000000000 -0800
+++ hugetlbfs-2.5.46-6/arch/i386/mm/hugetlbpage.c	2002-11-05 14:02:05.000000000 -0800
@@ -18,16 +18,16 @@
 #include <asm/tlb.h>
 #include <asm/tlbflush.h>
 
-long    htlbpagemem = 0;
+static long    htlbpagemem;
 int     htlbpage_max;
-long    htlbzone_pages;
+static long    htlbzone_pages;
 
 struct vm_operations_struct hugetlb_vm_ops;
 static LIST_HEAD(htlbpage_freelist);
 static spinlock_t htlbpage_lock = SPIN_LOCK_UNLOCKED;
 
 #define MAX_ID 	32
-struct htlbpagekey {
+static struct htlbpagekey {
 	struct inode *in;
 	int key;
 } htlbpagek[MAX_ID];
@@ -109,7 +109,7 @@ static int anon_get_hugetlb_page(struct 
 	return page ? 1 : -1;
 }
 
-int make_hugetlb_pages_present(unsigned long addr, unsigned long end, int flags)
+static int make_hugetlb_pages_present(unsigned long addr, unsigned long end, int flags)
 {
 	int write;
 	struct mm_struct *mm = current->mm;

^ permalink raw reply	[flat|nested] 2+ messages in thread

* hugetlb: No coalescing of adjacent mappings in /proc/pid/maps
  2002-11-06  2:30 [7/7] hugetlb: make private functions static William Lee Irwin III
@ 2002-11-06  6:26 ` dada1
  0 siblings, 0 replies; 2+ messages in thread
From: dada1 @ 2002-11-06  6:26 UTC (permalink / raw)
  To: linux-kernel, William Lee Irwin III

Hello William

I noticed a small problem if a process allocates hugetlb memory using

sys_alloc_hugepages(0, 0, 4*1024*1024, PROT_READ|PROT_WRITE, 0) ;

If this process uses a lot of hugetlb pages, its /proc/pid/maps contains one
entry for each mapping.

Could it be possible to coalesce all consecutive mappings onto only one ? As
standard mmap() calls do ?


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-11-06  6:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-11-06  2:30 [7/7] hugetlb: make private functions static William Lee Irwin III
2002-11-06  6:26 ` hugetlb: No coalescing of adjacent mappings in /proc/pid/maps dada1

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.