From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Michael S. Tsirkin" Subject: Re: [PATCH] virtio-console: avoid DMA from stack Date: Wed, 1 Mar 2017 23:25:14 +0200 Message-ID: <20170301232508-mutt-send-email-mst@kernel.org> References: <075115ddd99246ffc4228a3e050ba68eb36c6a8c.1485935920.git.osandov@fb.com> <20170201134712.GA7935@amit-lp.rh> <20170301200110.GA24754@vader.dhcp.thefacebook.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <20170301200110.GA24754@vader.dhcp.thefacebook.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: virtualization-bounces@lists.linux-foundation.org Errors-To: virtualization-bounces@lists.linux-foundation.org To: Omar Sandoval Cc: kernel-team@fb.com, virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Amit Shah List-Id: virtualization@lists.linuxfoundation.org On Wed, Mar 01, 2017 at 12:01:10PM -0800, Omar Sandoval wrote: > On Wed, Feb 01, 2017 at 07:17:12PM +0530, Amit Shah wrote: > > On (Wed) 01 Feb 2017 [00:02:27], Omar Sandoval wrote: > > > From: Omar Sandoval > > > > > > put_chars() stuffs the buffer it gets into an sg, but that buffer may be > > > on the stack. This breaks with CONFIG_VMAP_STACK=y (for me, it > > > manifested as printks getting turned into NUL bytes). > > > > Seems reasonable. I wonder since all implementations of hvc do a > > memcpy, if we can abstract it - but that'll need some work. > > > > Reviewed-by: Amit Shah > > > > Michael, please add to the virtio queue. > > > > Amit > > Hi, Michael, > > I don't see this in Linus' master or in your git tree, is it going to go > in for -rc1? > > Thanks. Yes.