[PATCH 0/3] Generic support for revoking mappings

From: Eric W. Biederman
Date: Sat Sep 25 2010 - 19:34:00 EST



During hotplug or rmmod if a device or file is mmaped, it's mapping
needs to be removed and future access need to return SIGBUS almost like
truncate. This case is rare enough that it barely gets tested, and
making a generic implementation warranted. I have tried with sysfs but
a complete and generic implementation does not seem possible without mm
support.

It looks like a fully generic implementation with mm knowledge
is shorter and easier to get right than what I have in sysfs today.

So here is that fully generic implementation.

Eric W. Biederman (3):
mm: Introduce revoke_mappings.
mm: Consolidate vma destruction into remove_vma.
mm: Cause revoke_mappings to wait until all close methods have completed.
---
include/linux/fs.h | 2 +
include/linux/mm.h | 2 +
mm/Makefile | 2 +-
mm/mmap.c | 34 +++++-----
mm/nommu.c | 5 ++
mm/revoke.c | 192 ++++++++++++++++++++++++++++++++++++++++++++++++++++
6 files changed, 219 insertions(+), 18 deletions(-)

Eric
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/