Re: [PATCH 1/7] revoke: special mmap handling
From: Jan Kara
Date: Mon Mar 12 2007 - 09:26:28 EST
Hi,
> This adds special handling for revoked memory mappings. We want to
> raise SIGBUS when accessing revoked mappings and return ENODEV when
> trying to remap with mmap(2).
>
> Signed-off-by: Pekka Enberg <penberg@xxxxxxxxxxxxxx>
> ---
> include/linux/mm.h | 2 ++
> mm/memory.c | 3 +++
> mm/mmap.c | 12 ++++++++----
> 3 files changed, 13 insertions(+), 4 deletions(-)
>
> Index: uml-2.6/include/linux/mm.h
> ===================================================================
> --- uml-2.6.orig/include/linux/mm.h 2007-03-08 10:24:24.000000000 +0200
> +++ uml-2.6/include/linux/mm.h 2007-03-08 10:24:25.000000000 +0200
> @@ -170,6 +170,8 @@
> #define VM_INSERTPAGE 0x02000000 /* The vma has had "vm_insert_page()" done on it */
> #define VM_ALWAYSDUMP 0x04000000 /* Always include in core dumps */
>
> +#define VM_REVOKED 0x04000000 /* Mapping has been revoked */
> +
Is it intended to conflict with VM_ALWAYSDUMP? I'd guess not and if
yes, it definitely deserves a comment...
Honza
--
Jan Kara <jack@xxxxxxx>
SuSE CR Labs
-
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/