From: David Howells Date: Mon, 06 Apr 2020 17:51:37 +0000 Subject: Re: [PATCH] mm: Add kvfree_sensitive() for freeing sensitive data objects Message-Id: <354824.1586195497@warthog.procyon.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit List-Id: References: <20200406023700.1367-1-longman@redhat.com> <319765.1586188840@warthog.procyon.org.uk> <334933.1586190389@warthog.procyon.org.uk> In-Reply-To: To: Linus Torvalds Cc: dhowells@redhat.com, Joe Perches , Waiman Long , Andrew Morton , Jarkko Sakkinen , James Morris , "Serge E. Hallyn" , Linux-MM , keyrings@vger.kernel.org, Linux Kernel Mailing List Linus Torvalds wrote: > > Add yet another alloc flag like __GFP_SENSITIVE > > and have kfree operate on that and not have a > > kfree_sensitive at all. > > That sounds potentially sensible. Maybe even a SLAB_SENSITIVE to mark > a whole slab cache sensitive for kmem_cache_create(). The allocation might be by vmalloc rather than kmalloc. I'm not sure if that makes things more difficult. David