Files
linux/mm
Linus Torvalds d7c75177f0 mm: avoid wrapping vm_pgoff in mremap()
commit 982134ba62 upstream.

The normal mmap paths all avoid creating a mapping where the pgoff
inside the mapping could wrap around due to overflow.  However, an
expanding mremap() can take such a non-wrapping mapping and make it
bigger and cause a wrapping condition.

Noticed by Robert Swiecki when running a system call fuzzer, where it
caused a BUG_ON() due to terminally confusing the vma_prio_tree code.  A
vma dumping patch by Hugh then pinpointed the crazy wrapped case.

Reported-and-tested-by: Robert Swiecki <robert@swiecki.net>
Acked-by: Hugh Dickins <hughd@google.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-04-14 16:53:30 -07:00
..
2009-04-01 08:59:13 -07:00
2010-07-05 11:10:42 -07:00
2009-06-16 19:47:28 -07:00
2010-01-06 15:05:22 -08:00
2010-05-12 14:57:00 -07:00
2010-12-09 13:26:39 -08:00
2009-09-22 07:17:35 -07:00
2010-10-28 21:44:18 -07:00
2010-12-09 13:27:02 -08:00
2010-09-26 17:21:27 -07:00
2007-10-20 01:27:18 +02:00
2009-10-01 16:11:12 -07:00
2010-08-26 16:41:46 -07:00
2009-06-23 12:50:05 -07:00
2010-01-22 15:18:41 -08:00
2010-01-18 10:19:11 -08:00