Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932656AbcLNQ7M (ORCPT ); Wed, 14 Dec 2016 11:59:12 -0500 Received: from 8bytes.org ([81.169.241.247]:44566 "EHLO theia.8bytes.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753645AbcLNQ7J (ORCPT ); Wed, 14 Dec 2016 11:59:09 -0500 Date: Wed, 14 Dec 2016 17:58:56 +0100 From: Joerg Roedel To: Andy Lutomirski Cc: David Laight , David Woodhouse , Linus Torvalds , Ingo Molnar , Andy Lutomirski , "linux-kernel@vger.kernel.org" , "linux-usb@vger.kernel.org" , "dhowells@redhat.com" , "keyrings@vger.kernel.org" , Eric Biggers , "linux-crypto@vger.kernel.org" , Herbert Xu , Stephan Mueller Subject: Re: [PATCH] keys/encrypted: Fix two crypto-on-the-stack bugs Message-ID: <20161214165856.GD17255@8bytes.org> References: <8c273c9c41f51b34bb3115086f1d776895580637.1481575835.git.luto@kernel.org> <063D6719AE5E284EB5DD2968C1650D6DB023CA99@AcuExch.aculab.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 522 Lines: 13 On Tue, Dec 13, 2016 at 08:40:00AM -0800, Andy Lutomirski wrote: > But I think this is rather silly. Joerg, Linus, etc: would it be okay > to change lib/dma-debug.c to allow DMA *from* rodata? Yeah, this would be fine for DMA_TO_DEVICE mappings. At least I can't think of a reason right now to not allow it, in the end its also read-only memory for the CPU, so it can be readable by devices too. There is no danger of race conditions like on stacks or data leaks, as there is only compile-time data in rodata. Joerg