From patchwork Tue Jul 24 16:49:36 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kees Cook X-Patchwork-Id: 10542691 X-Patchwork-Delegate: snitzer@redhat.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 77BC014E2 for ; Tue, 24 Jul 2018 16:56:28 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 63E0228D4C for ; Tue, 24 Jul 2018 16:56:28 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 577FC28FC2; Tue, 24 Jul 2018 16:56:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E857F28D4C for ; Tue, 24 Jul 2018 16:56:27 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.26]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 71A9F307D85C; Tue, 24 Jul 2018 16:56:26 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 211E23001A58; Tue, 24 Jul 2018 16:56:26 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 4BF1518037ED; Tue, 24 Jul 2018 16:56:25 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6OGuMEb012225 for ; Tue, 24 Jul 2018 12:56:23 -0400 Received: by smtp.corp.redhat.com (Postfix) id EEB8E300193C; Tue, 24 Jul 2018 16:56:22 +0000 (UTC) Delivered-To: dm-devel@redhat.com Received: from mx1.redhat.com (ext-mx10.extmail.prod.ext.phx2.redhat.com [10.5.110.39]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E745E3083320 for ; Tue, 24 Jul 2018 16:56:18 +0000 (UTC) Received: from mail-pl0-f67.google.com (mail-pl0-f67.google.com [209.85.160.67]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id CB96C5D687 for ; Tue, 24 Jul 2018 16:56:17 +0000 (UTC) Received: by mail-pl0-f67.google.com with SMTP id w3-v6so2031114plq.2 for ; Tue, 24 Jul 2018 09:56:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=NcyGQqHeJf08FCzNacBJKb8s2eWekxJenaMH09CYQ7Y=; b=NUe10EpSwaK9hTK+tgq8KHU1ZJEoxtFiiin1GLrUvH5befNzNbJp/dbqZtx0wwTjsZ S+9uldBhcSPn9UrOn3TzkhsKoKOGNGOHdl2zL3armIVu/iYQm29La09prGGpC6w7v5to kzrazNWKQj2c568+uReKEwROKVWqmdLy51RJM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=NcyGQqHeJf08FCzNacBJKb8s2eWekxJenaMH09CYQ7Y=; b=RxdJ13j390aI9KfYP0GkTcf8MuGaeeHHmVC4QYHDP5BcmKYSCvGJiTLJ0Y9AKTCDRO n1K5c+0siTDNExtKE6lWikJslc0b4I1MkdKVv1VREl7fjnFtCF2OK78v3kFuypv4L/VE uU7MtYepNnjCqFInjwzarhY8t7LFtvuaA7jT6pnW9iZB8rFhERgepjUlONx/1kZmjheT 7JO03je4PeqjMlcIM4Gwt0e0y0BV6ItbeAUuGKIOBf4jYumQyiqnOBmE8j4ooGTyUMMz lztaKeVTg1eZ/Ek1MhV78W/W6JEpp4fRNEIXM1EmgAxYc8HZ1rmGmhtInQY9NJFFNHsH f50A== X-Gm-Message-State: AOUpUlH8jTjOj8HAAFd3kBpi5TkOLURUkksb/nsf+tYk2fe+dP4zncpl muMqbC4ZpjmVAkX54x80eln6mA== X-Google-Smtp-Source: AAOMgpdsCSzdgHfeKIerJQZi1yIP1qsAKuD1uCzih3O8Vp+lUv2MyL1OLAAO13EERm9srC2f7xhK+w== X-Received: by 2002:a17:902:a5:: with SMTP id a34-v6mr18046476pla.60.1532451377375; Tue, 24 Jul 2018 09:56:17 -0700 (PDT) Received: from www.outflux.net (173-164-112-133-Oregon.hfc.comcastbusiness.net. [173.164.112.133]) by smtp.gmail.com with ESMTPSA id z4-v6sm21812205pfl.11.2018.07.24.09.56.15 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 24 Jul 2018 09:56:16 -0700 (PDT) From: Kees Cook To: Herbert Xu Date: Tue, 24 Jul 2018 09:49:36 -0700 Message-Id: <20180724164936.37477-19-keescook@chromium.org> In-Reply-To: <20180724164936.37477-1-keescook@chromium.org> References: <20180724164936.37477-1-keescook@chromium.org> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 24 Jul 2018 16:56:17 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 24 Jul 2018 16:56:17 +0000 (UTC) for IP:'209.85.160.67' DOMAIN:'mail-pl0-f67.google.com' HELO:'mail-pl0-f67.google.com' FROM:'keescook@chromium.org' RCPT:'' X-RedHat-Spam-Score: -0.131 (DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_PASS) 209.85.160.67 mail-pl0-f67.google.com 209.85.160.67 mail-pl0-f67.google.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.39 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.26 X-loop: dm-devel@redhat.com Cc: Giovanni Cabiddu , Mike Snitzer , "Gustavo A. R. Silva" , linux-wireless@vger.kernel.org, Will Deacon , linux-kernel@vger.kernel.org, David Howells , dm-devel@redhat.com, Jia-Ju Bai , Paul Mackerras , Pavel Machek , "H. Peter Anvin" , linux-afs@lists.infradead.org, Alasdair Kergon , Kees Cook , devel@driverdev.osuosl.org, x86@kernel.org, qat-linux@intel.com, Ingo Molnar , Eric Biggers , Geert Uytterhoeven , drbd-dev@lists.linbit.com, Rabin Vincent , Arnd Bergmann , Tudor-Dan Ambarus , linux-block@vger.kernel.org, Josh Poimboeuf , Thomas Gleixner , Lars Ellenberg , Jens Axboe , Andrew Morton , Greg Kroah-Hartman , linux-pm@vger.kernel.org, "Rafael J. Wysocki" , Philipp Reisner , linux-crypto@vger.kernel.org, linux-ppp@vger.kernel.org, Johannes Berg , Tim Chen , netdev@vger.kernel.org, David Woodhouse Subject: [dm-devel] [PATCH v6 18/18] crypto: Remove AHASH_REQUEST_ON_STACK X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.26 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.48]); Tue, 24 Jul 2018 16:56:27 +0000 (UTC) X-Virus-Scanned: ClamAV using ClamSMTP All users of AHASH_REQUEST_ON_STACK have been removed from the kernel, so drop it entirely so no VLAs get reintroduced by future users. Signed-off-by: Kees Cook --- include/crypto/hash.h | 5 ----- 1 file changed, 5 deletions(-) diff --git a/include/crypto/hash.h b/include/crypto/hash.h index 21587011ab0f..fca3e28c77a4 100644 --- a/include/crypto/hash.h +++ b/include/crypto/hash.h @@ -64,11 +64,6 @@ struct ahash_request { void *__ctx[] CRYPTO_MINALIGN_ATTR; }; -#define AHASH_REQUEST_ON_STACK(name, ahash) \ - char __##name##_desc[sizeof(struct ahash_request) + \ - crypto_ahash_reqsize(ahash)] CRYPTO_MINALIGN_ATTR; \ - struct ahash_request *name = (void *)__##name##_desc - /** * struct ahash_alg - asynchronous message digest definition * @init: **[mandatory]** Initialize the transformation context. Intended only to initialize the