lkml.org 
[lkml]   [2002]   [Oct]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] linux-2.5.43_vsyscall_A0
> > My problem is that mapping user code into the vsyscall fixmap is
> > complex and not very clean at all, breaks various concepts in the mm
> > and last but not the least it is slow
>
> Can you explain, in small words, why mapping user code is so horrible?

Currently Linux has neatly separated kernel and user page tables.
On architectures which have tree type tables in hardware you just have
a user level table and you stick a pointer to the kernel level tables
somewhere at the end of the first page. The normal user level page
handling doesn't know about the kernel pages. The vsyscall code is in
the kernel mapping in the fixmaps. Allowing the user to map arbitary
pages into the vsyscall area would blur this clear separation and
require much more special case handling.

In addition it would break a lot of assumptions that user mappings are
only < __PAGE_OFFSET, probably having security implications. For example
you would need to special case this in uaccess.h's access_ok(), which
would be quite a lot of overhead (any change to this function causes
many KB of binary bloat because *_user is so heavily used all over the kernel)

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

\
 
 \ /
  Last update: 2005-03-22 13:30    [W:0.112 / U:0.008 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site