Received: by 10.223.185.116 with SMTP id b49csp1139951wrg; Wed, 14 Feb 2018 12:14:24 -0800 (PST) X-Google-Smtp-Source: AH8x227igtDPQI/1yqBKkKDLCWag5+1D5i4PBkbzTfYNZ/pL9TenSlDLCGKl/Myx4eTWY95uPfhU X-Received: by 10.99.55.65 with SMTP id g1mr178266pgn.284.1518639264613; Wed, 14 Feb 2018 12:14:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518639264; cv=none; d=google.com; s=arc-20160816; b=HXy8EyOcMLh7IFXogZbjVbQ+3DKCQObzDwYaUf1GDXCs6r+kiLCU4S4Y5mQD5iIRKx qMo675ei+/judMl1FQlLTOK6DSSa2QGOW3E3IcRjbnv8nF+SjWlkGAfOkAQOPw3Xoa8Y O+j07kyuSgFqimMRGqknq76rGL9gzU89WMa5sq4hi8Ett69EzarAq/+Rw5bbiMJ3dYJ+ ZejZsc4by5082eQ1hEIpq+LWx+iyLXEjfIrf3xuZmJOfvEkA5deCo+zu9ypN0aePX0RG t7wadyh3yUxAbttLSIOSE2eOofwAhn35ROESM7lmQC+FMpBIbD2OLpBFNzEO2i3gBqct 2SRA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=578lu1gZbAtmeOArQERzKmg78fcxNMvw41gcqEm1eYk=; b=A0u71vG7nIeWYP2rlVyHqYYk0vbQAKlif6CWmBAE+Tk1wZ8n9Ldtsr1JJ4tPjCHoH7 I9TD4+GIhYVG8ZMrnwJyyQaOL1HmTC0MA69V3pU3v1x/yb390EXq46BHjf6SUoVaOs/+ IJoGi2+2c2rCSJA9Jr49Z0vDvbNytjLENNwc6Pec7iBN7j0dCv24x4jZAMb+im0TtEWS fXbBjgObJQZ89knLmMSBh5LvnHWiJ/1IVFEIS8pc/h05/L7gIAJt0ttrDiBrOODjJQe8 1UqBDt4wuOgIEgiQfwHChA2gjVdW9OzUwTMoe77taS4RMoJOjOKqbdcPYReg1aaWfTn4 w8oA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=uq0637Ji; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e6si2611752pfg.279.2018.02.14.12.14.09; Wed, 14 Feb 2018 12:14:24 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=uq0637Ji; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1163120AbeBNT4g (ORCPT + 99 others); Wed, 14 Feb 2018 14:56:36 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:44414 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1033430AbeBNT4e (ORCPT ); Wed, 14 Feb 2018 14:56:34 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=578lu1gZbAtmeOArQERzKmg78fcxNMvw41gcqEm1eYk=; b=uq0637Jif5Lczv4H8phtRE9Of qsKpOPr3pprYvh3/N7e64wNB17P+arQ17r4ajmEyABRlFORUfVBS1nyBeJB3dXbZkaBMubA4W7RUa mKDa1TS0xWGsbNv0R5P4H3VxitwsL/9JitSK+SDa6zu9/bq96mKCqnA4FoKB8OWkNKF5Q8VIHnhsh NzPYk95ynrucsZPCFdU3tS8qFgiapRcUTTgqpu0Tdch9ShCo12fSFrrQfEks0TuGpsSz7wRfcKBzw f+3O1FyHymbkJ8FcBMk74krRbkb3ovlzCLdsf6HDfdDsVYoCxYu65CCww1/FuR87g+vcq2czjlnwv hGfuRLrMg==; Received: from willy by bombadil.infradead.org with local (Exim 4.89 #1 (Red Hat Linux)) id 1em3AN-0000Ea-OA; Wed, 14 Feb 2018 19:56:31 +0000 Date: Wed, 14 Feb 2018 11:56:31 -0800 From: Matthew Wilcox To: Joe Perches Cc: Kees Cook , Andrew Morton , Matthew Wilcox , Linux-MM , LKML , Kernel Hardening Subject: Re: [PATCH 0/2] Add kvzalloc_struct to complement kvzalloc_array Message-ID: <20180214195631.GC20627@bombadil.infradead.org> References: <20180214182618.14627-1-willy@infradead.org> <1518634058.3678.15.camel@perches.com> <1518636765.3678.19.camel@perches.com> <20180214193613.GB20627@bombadil.infradead.org> <1518637426.3678.21.camel@perches.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1518637426.3678.21.camel@perches.com> User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Feb 14, 2018 at 11:43:46AM -0800, Joe Perches wrote: > On Wed, 2018-02-14 at 11:36 -0800, Matthew Wilcox wrote: > > If somebody wants them, then we can add them. > > Yeah, but I don't think any of it is necessary. > > How many of these struct+bufsize * count entries > actually exist? Wrong question. How many of them currently exist that don't check for integer overflow? How many of them will be added in the future that will fail to check for integer overflow? I chose five at random to fix as demonstration that the API is good. There are more; I imagine that Julia will be able to tell us how many.