lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <200907291058.23390.laurent.pinchart@skynet.be>
Date:	Wed, 29 Jul 2009 10:58:23 +0200
From:	Laurent Pinchart <laurent.pinchart@...net.be>
To:	Jonathan Corbet <corbet@....net>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: Should I use kmap or kmap_atomic to map user pages that will be written in a loop ?

Hi Jonathan,

On Monday 27 July 2009 23:11:58 Jonathan Corbet wrote:
> On Sun, 26 Jul 2009 23:52:09 +0200 Laurent Pinchart wrote:
> > I receive data from the USB subsystem in URB buffers, which are small
> > kernel buffers. As I have to strip headers from those buffers, I can't
> > initialize the URBs to copy data directly to the userspace buffers, so
> > there's at least one memcpy operation involved :-S
> >
> > I could indeed append the URBs to a list in the callback called from
> > interrupt context, and process them from a threaded interrupt handler.
> > Would it make much difference ?
>
> Moving the actual copying out of interrupt context seems like a good
> idea.  And if you can get away from the whole get_user_pages() and
> kmap() mess into a straight copy-to-user-space situation, you'll make
> your life easier.  So that would be my recommendation, yes.

Thanks. I'll try that, it will make my life easier.

Regards,

Laurent Pinchart

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ