From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BD759C43216 for ; Thu, 26 Aug 2021 15:39:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A3C9B60F5C for ; Thu, 26 Aug 2021 15:39:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242977AbhHZPkl (ORCPT ); Thu, 26 Aug 2021 11:40:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48182 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242962AbhHZPkk (ORCPT ); Thu, 26 Aug 2021 11:40:40 -0400 Received: from mail-pj1-x1030.google.com (mail-pj1-x1030.google.com [IPv6:2607:f8b0:4864:20::1030]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 62FAEC0617A8 for ; Thu, 26 Aug 2021 08:39:53 -0700 (PDT) Received: by mail-pj1-x1030.google.com with SMTP id mq3so2465423pjb.5 for ; Thu, 26 Aug 2021 08:39:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:user-agent:in-reply-to:references :message-id:mime-version:content-transfer-encoding; bh=0x3JVYJjoPp3mCHZGSPU/br7LvYDmK0AvhxHSp9lei4=; b=BR2UH4Z+GTbgEsYwtzFTbhdGQ/ifkZOkcR9teV+AYwQ3uF+6UE2vX9k0M4WOgNrNWf raCkiFOMfrY6FzZdgajczRJJIDJCdW9kwHCG5G2CE9JrNoSypm+HxXGIIAQstL4hFcZ9 m1iWfYepYFxbr1A5juP/ftBYb8BjyINYS3TVo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:user-agent:in-reply-to :references:message-id:mime-version:content-transfer-encoding; bh=0x3JVYJjoPp3mCHZGSPU/br7LvYDmK0AvhxHSp9lei4=; b=YIY96m2c8r12Ma7H6Lw48yX9MfvWSLiuDX8tMsZ+6Q2EL3F4WFS42d/Gs1bau60BOb Xx9RVORb+KpqWWPloTVcW3hLGUf9/rd+fHB4thed9OIXEOjd0rhkqjs57nePPmb+VeeH IIA/wZi23tkMdd+AJ5u4PeWWMStqTDPCtkXx9kcQf6I88liKzevSKWCRc8frO4UgGIlw Y0+6RVNHioX4yLdTrRCKEkYc3emQ7/zcwA5K5f3ENfqAh7gNvxTKBuFnvE8AUk8KkqF6 Th5ddgDICk0OEefGmm8kJJiIQma9hBoZ0Iu7P0P0ByT26B8eLPsZZlt/FdJ3k+0v8Uv5 DL4A== X-Gm-Message-State: AOAM530vzab/qw0IWc7/gzaER2CfpDenCfDheVlcUBUU4iaOskcFXUmy ycKGw4dEugcKE+nZbflLF9qysg== X-Google-Smtp-Source: ABdhPJyT1qPGkMrZWNyo9SQCMwAQb4rxdWH8bunPfFQd6Ss5tMxVMpPCzWceJSepz+bPci6A3ddt0g== X-Received: by 2002:a17:90a:14e4:: with SMTP id k91mr17431519pja.3.1629992392852; Thu, 26 Aug 2021 08:39:52 -0700 (PDT) Received: from ?IPv6:::1? ([2600:6c55:4b00:c768:1835:a5a0:2702:1052]) by smtp.gmail.com with ESMTPSA id z131sm3466093pfc.159.2021.08.26.08.39.51 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 26 Aug 2021 08:39:52 -0700 (PDT) Date: Thu, 26 Aug 2021 08:39:47 -0700 From: Kees Cook To: Vincent MAILHOL CC: open list , "Gustavo A. R. Silva" , Arnd Bergmann , Ayush Sawal , Vinay Kumar Yadav , Rohit Maheshwari , Herbert Xu , "David S. Miller" , Kalle Valo , Jakub Kicinski , Stanislaw Gruszka , Luca Coelho , "James E.J. Bottomley" , "Martin K. Petersen" , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , Johannes Berg , Mordechay Goodstein , Lee Jones , Wolfgang Grandegger , Marc Kleine-Budde , Arunachalam Santhanam , Mikulas Patocka , linux-crypto@vger.kernel.org, ath10k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev , linux-scsi@vger.kernel.org, linux-can , bpf@vger.kernel.org, Rasmus Villemoes , Keith Packard , Dan Williams , Daniel Vetter , clang-built-linux@googlegroups.com, linux-hardening@vger.kernel.org Subject: Re: [PATCH v2 2/5] treewide: Replace open-coded flex arrays in unions User-Agent: K-9 Mail for Android In-Reply-To: References: <20210826050458.1540622-1-keescook@chromium.org> <20210826050458.1540622-3-keescook@chromium.org> Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-can@vger.kernel.org On August 26, 2021 12:36:27 AM PDT, Vincent MAILHOL wrote: >On Thu=2E 26 Aug 2021 at 14:04, Kees Cook wrote= : >> In support of enabling -Warray-bounds and -Wzero-length-bounds and >> correctly handling run-time memcpy() bounds checking, replace all >> open-coded flexible arrays (i=2Ee=2E 0-element arrays) in unions with t= he >> flex_array() helper macro=2E > >Nitpick: the commit description says flex_array() but the code is >actually DECLARE_FLEX_ARRAY() or __DECLARE_FLEX_ARRAY()=2E Ah yes, thanks! I had renamed the macro but missed these references=2E Now= fixed! -Kees