lkml.org 
[lkml]   [2015]   [Apr]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Hang on large copy_from_user with PREEMPT_NONE
On Tue, Apr 07, 2015 at 10:33:49AM -0700, Linus Torvalds wrote:
> On Tue, Apr 7, 2015 at 10:00 AM, Sasha Levin <sasha.levin@oracle.com> wrote:
> >
> > It locks up quickly without KASan as well.
>
> I suspect it's some virtualization artifact, where the writes cause
> COW faults (or just memory allocations) in the L0 domain.
>
> Whatever. It's probably not worth fighting. Either we just decide that
> "copy_from_user()" shouldn't bother to zero huge areas (limit the
> zeroing to some arbitrary size), or we just special-case the module
> loading.
>
> +#define COPY_CHUNK_SIZE (16*PAGE_SIZE)

This needs to be bigger, just to accomodate things like xfs, which
on my system is over 1mb. I think some out-of-tree modules
(not that I care deeply) are even bigger.

Special casing might be an easier call.

Dave



\
 
 \ /
  Last update: 2015-04-07 20:41    [W:0.055 / U:0.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site