Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934108AbeALPlM convert rfc822-to-8bit (ORCPT + 1 other); Fri, 12 Jan 2018 10:41:12 -0500 Received: from smtp-out4.electric.net ([192.162.216.185]:58002 "EHLO smtp-out4.electric.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933947AbeALPlK (ORCPT ); Fri, 12 Jan 2018 10:41:10 -0500 From: David Laight To: 'Christopher Lameter' , Kees Cook CC: "linux-kernel@vger.kernel.org" , "David Windsor" , Pekka Enberg , "David Rientjes" , Joonsoo Kim , "Andrew Morton" , "linux-mm@kvack.org" , "linux-xfs@vger.kernel.org" , Linus Torvalds , Alexander Viro , Andy Lutomirski , Christoph Hellwig , "David S. Miller" , Laura Abbott , Mark Rutland , "Martin K. Petersen" , Paolo Bonzini , Christian Borntraeger , Christoffer Dall , Dave Kleikamp , Jan Kara , "Luis de Bethencourt" , Marc Zyngier , "Rik van Riel" , Matthew Garrett , "linux-fsdevel@vger.kernel.org" , "linux-arch@vger.kernel.org" , "netdev@vger.kernel.org" , "kernel-hardening@lists.openwall.com" Subject: RE: [PATCH 04/36] usercopy: Prepare for usercopy whitelisting Thread-Topic: [PATCH 04/36] usercopy: Prepare for usercopy whitelisting Thread-Index: AQHTikEtMNMFXqei5U6RoRU5MJZk06NwWf7g Date: Fri, 12 Jan 2018 15:10:42 +0000 Message-ID: References: <1515531365-37423-1-git-send-email-keescook@chromium.org> <1515531365-37423-5-git-send-email-keescook@chromium.org> In-Reply-To: Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.202.205.33] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-Outbound-IP: 156.67.243.126 X-Env-From: David.Laight@ACULAB.COM X-Proto: esmtps X-Revdns: X-HELO: AcuMS.aculab.com X-TLS: TLSv1.2:ECDHE-RSA-AES256-SHA384:256 X-Authenticated_ID: X-PolicySMART: 3396946, 3397078 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: From: Christopher Lameter > Sent: 10 January 2018 18:28 > On Tue, 9 Jan 2018, Kees Cook wrote: > > > +struct kmem_cache *kmem_cache_create_usercopy(const char *name, > > + size_t size, size_t align, slab_flags_t flags, > > + size_t useroffset, size_t usersize, > > + void (*ctor)(void *)); > > Hmmm... At some point we should switch kmem_cache_create to pass a struct > containing all the parameters. Otherwise the API will blow up with > additional functions. Or add an extra function to 'configure' the kmem_cache with the extra parameters. David