Re: Linux 2.6.32.20

Previous thread: Linux 2.6.27.52 by Greg KH on Friday, August 20, 2010 - 1:43 pm. (2 messages)

Next thread: Linux 2.6.34.5 by Greg KH on Friday, August 20, 2010 - 1:47 pm. (2 messages)
From: Greg KH
Date: Friday, August 20, 2010 - 1:46 pm

I'm announcing the release of the 2.6.32.20 kernel.

All users of the 2.6.32 kernel series must upgrade.

The updated 2.6.32.y git tree can be found at:
        git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-2.6.32.y.git
and can be browsed at the normal kernel.org git web browser:
        http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.32.y.git;a=summary

thanks,

greg k-h

------------

 Makefile           |    2 +-
 fs/proc/task_mmu.c |    8 +++++++-
 mm/memory.c        |   13 ++++++-------
 mm/mlock.c         |    8 ++++++++
 4 files changed, 22 insertions(+), 9 deletions(-)

Greg Kroah-Hartman (1):
      Linux 2.6.32.20

Linus Torvalds (2):
      mm: fix page table unmap for stack guard page properly
      mm: fix up some user-visible effects of the stack guard page

--

From: Greg KH
Date: Friday, August 20, 2010 - 1:46 pm

diff --git a/Makefile b/Makefile
index 64e538c..ad4d191 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
 VERSION = 2
 PATCHLEVEL = 6
 SUBLEVEL = 32
-EXTRAVERSION = .19
+EXTRAVERSION = .20
 NAME = Man-Eating Seals of Antiquity
 
 # *DOCUMENTATION*
diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c
index 366b101..899145d 100644
--- a/fs/proc/task_mmu.c
+++ b/fs/proc/task_mmu.c
@@ -206,6 +206,7 @@ static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma)
 	int flags = vma->vm_flags;
 	unsigned long ino = 0;
 	unsigned long long pgoff = 0;
+	unsigned long start;
 	dev_t dev = 0;
 	int len;
 
@@ -216,8 +217,13 @@ static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma)
 		pgoff = ((loff_t)vma->vm_pgoff) << PAGE_SHIFT;
 	}
 
+	/* We don't show the stack guard page in /proc/maps */
+	start = vma->vm_start;
+	if (vma->vm_flags & VM_GROWSDOWN)
+		start += PAGE_SIZE;
+
 	seq_printf(m, "%08lx-%08lx %c%c%c%c %08llx %02x:%02x %lu %n",
-			vma->vm_start,
+			start,
 			vma->vm_end,
 			flags & VM_READ ? 'r' : '-',
 			flags & VM_WRITE ? 'w' : '-',
diff --git a/mm/memory.c b/mm/memory.c
index 76d1b21..babb991 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -2662,24 +2662,23 @@ static int do_anonymous_page(struct mm_struct *mm, struct vm_area_struct *vma,
 	spinlock_t *ptl;
 	pte_t entry;
 
-	if (check_stack_guard_page(vma, address) < 0) {
-		pte_unmap(page_table);
+	pte_unmap(page_table);
+
+	/* Check if we need to add a guard page to the stack */
+	if (check_stack_guard_page(vma, address) < 0)
 		return VM_FAULT_SIGBUS;
-	}
 
+	/* Use the zero-page for reads */
 	if (!(flags & FAULT_FLAG_WRITE)) {
 		entry = pte_mkspecial(pfn_pte(my_zero_pfn(address),
 						vma->vm_page_prot));
-		ptl = pte_lockptr(mm, pmd);
-		spin_lock(ptl);
+		page_table = pte_offset_map_lock(mm, pmd, address, &ptl);
 		if (!pte_none(*page_table))
 			goto unlock;
 		goto setpte;
 	}
 
 	/* Allocate our own private page. ...
Previous thread: Linux 2.6.27.52 by Greg KH on Friday, August 20, 2010 - 1:43 pm. (2 messages)

Next thread: Linux 2.6.34.5 by Greg KH on Friday, August 20, 2010 - 1:47 pm. (2 messages)