lkml.org 
[lkml]   [2020]   [Apr]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mm/vmalloc: Sanitize __get_vm_area() arguments
On Mon, Apr 06, 2020 at 06:01:55AM -0700, Christoph Hellwig wrote:
> On Fri, Apr 03, 2020 at 06:32:53PM +0200, Peter Zijlstra wrote:
> >
> > __get_vm_area() is an exported symbol, make sure the callers stay in
> > the expected memory range. When calling this function with memory
> > ranges outside of the VMALLOC range *bad* things can happen.
> >
> > (I noticed this when I managed to corrupt the kernel text by accident)
>
> Maybe it is time to unexport it? There are only two users:
>
> - staging/media/ipu3 really should be using vmap. And given that it
> is a staging driver it really doesn't matter anyway if we break it.
> - pcmcia/electra_cf.c is actually using it for something that is not
> a vmalloc address. But it is so special that I think prohibiting
> to build it as module seems fine.

I think I just sent you a patch along those lines ;-)

\
 
 \ /
  Last update: 2020-04-06 16:06    [W:0.089 / U:0.296 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site