lkml.org 
[lkml]   [2009]   [Jul]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v5] RO/NX protection for loadable kernel modules
Date
On Sun, 12 Jul 2009 05:15:24 pm Arjan van de Ven wrote:
> Rusty Russell <rusty@rustcorp.com.au> wrote:
> > (I like the idea of trying kmalloc and falling back, simply because
> > it reduces TLB pressure, but that's probably best done after
> > unification).
>
> or using a non-power-of-two get_free_pages() thing...
>
> some architectures will need to know that memory needs to be executable
> at allocation time so that it can be put in an executable address range
> etc...

Yes, maybe that's better than kmalloc. On my laptop I have 105 modules
loaded, with 3778464 total length: I'm wasting 206944 bytes on unused tails of
pages. But that's only 0.06% of my memory.

Thanks,
Rusty.


\
 
 \ /
  Last update: 2009-07-12 12:01    [W:0.075 / U:0.360 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site