lkml.org 
[lkml]   [2008]   [Apr]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: nommu: handling anonymous mmap clearing in userspace rather than kernel
Mike Frysinger wrote:

> i also expected MAP_UNINITIALIZE to be unacceptable to LKML. and
> afaik, there doesnt seem to be a way to distinguish in the kernel
> whether the call is coming from userspace or kernel space, so the
> memset() call will still be called for the kernel. ideally the code
> would read:
> if (!kernel && !(flags & MAP_UNINITIALIZE))
> memset(base, 0, len);

Have you examined all callers in the kernel whether they can take
uninitialized memory? (Your code doesn't match your description btw, so
I'm only guessing what you actually want to achieve.)

Really, if MAP_UNINITIALIZE is unacceptable, then that's too bad and
we'll carry it as a local patch, but all the other proposed mechanisms
are non-solutions because they break an established interface.


Bernd
--
This footer brought to you by insane German lawmakers.
Analog Devices GmbH Wilhelm-Wagenfeld-Str. 6 80807 Muenchen
Sitz der Gesellschaft Muenchen, Registergericht Muenchen HRB 40368
Geschaeftsfuehrer Thomas Wessel, William A. Martin, Margaret Seif


\
 
 \ /
  Last update: 2008-04-03 13:09    [W:0.058 / U:0.124 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site