Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp6029934iog; Thu, 23 Jun 2022 09:54:20 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uAcwxUgulzV6RkTzoIRarDL9LkJV/2gotTKo9YiKqEH036S9mBwdLvs8rR7J3uL5KSwU9X X-Received: by 2002:a05:6402:2552:b0:435:9e1c:ca49 with SMTP id l18-20020a056402255200b004359e1cca49mr11958518edb.126.1656003260720; Thu, 23 Jun 2022 09:54:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656003260; cv=none; d=google.com; s=arc-20160816; b=DlpyZtGuqQfXqyLWPgBdLclqN8TiOektrLrnGyuzXyaak9tibvcL2KdX5bp+ebfKKn YpQjpLORjdxIdzwiCIYX1GL5k9AUBlNO5iS5ziPX+Fkv6xdw1ApbrlDOmgweVc16chqK SjNEsq76ABuWpjCwgGw4WEHPrxpjUf5MdVU3nHf25QXMmyz8hKcfB0U5rq9PRtooUqd+ Jqr5tqcY96/vT/e4T9cC5EPmvV+y2E/8pEtnvcSsESgOAsrqxjRi6qBs9XLalMJgY8Of ctE8eJ22kDHFVs6PqnWFnY81WPCuEgdHsO04ck+fG5Oeroio1u6ku6yDIUzC2C8G6GWY 70CA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=g8uL4Cnos+tnqMRM/pR25DTlUlkkTtmxJhV6l+Yrd1g=; b=hJQ4YHobbYKlPsGBYVu7cjqn9aiX3Nl/fFU1QGgD2ycOSBZIomCzJ03Spn7BAABQyk KuU8aGVaHm1xWPQR38npkwjnPrXOGdRiilL/PstVvj4Gds3hNbsi+1HXyWie0sEKcnAE BL6snFSkhHGavFtOz5xzTew3RiPzMw3DUhBlCibqFTH6QLcdMMMgJL32IPxxnzgy1e7+ aCUmLo9Eg7tLqvU/SmmeZ0xfx2WTE0GOsQTWjxY8vTA2TjXIvbUHkJjy0LztmxrdVBri bbRUEcO6fQsazGeK4siBoX80r8l7mG8TZ64L2ZDKbVbSYSkzWlIoGXgkODJOQ7SGXcs/ nA2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=iq5Nofk2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a21-20020a1709066d5500b00702d8bd9e13si4353835ejt.707.2022.06.23.09.53.51; Thu, 23 Jun 2022 09:54:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=iq5Nofk2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232211AbiFWQ0M (ORCPT + 99 others); Thu, 23 Jun 2022 12:26:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231633AbiFWQ0H (ORCPT ); Thu, 23 Jun 2022 12:26:07 -0400 Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 641FF4504A for ; Thu, 23 Jun 2022 09:26:02 -0700 (PDT) Received: by mail-pj1-x1035.google.com with SMTP id h9-20020a17090a648900b001ecb8596e43so54309pjj.5 for ; Thu, 23 Jun 2022 09:26:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=g8uL4Cnos+tnqMRM/pR25DTlUlkkTtmxJhV6l+Yrd1g=; b=iq5Nofk2xDryk147dU/ZEzGYE5R3sJqvrdrhWA+r1L+t0r6bE6P+1TaIEdNkrJqCB/ Wjjy8ratdufNJKZyfwQu4YmbE3RVOD87F75MQbXVPsiFKf+C2mB7atafn2LS6CtKH/Os lqgOU8ZsaX4aYxfQCfMzO5re9+IbiBu8wbYJA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=g8uL4Cnos+tnqMRM/pR25DTlUlkkTtmxJhV6l+Yrd1g=; b=vI04D+0qwCwgT7LB/K4xTObt/bu2XZBtvvmkfFFj75p8PkLy2k2dZvVZ4N6wgJGeUH 6QTMW3xjw+WzqUsEbsK6JbkJgr+6ZsU+0Oeo551achbOKksnRd6z/1O60aT0/d31LOhb CBebCsKOiTSBD6KVljJQEKWJy9HWpQVuG3NoomFI8x/mFV/4Idy7K3d6GeT57rj0h8Ss 18Jd5PwjOHEd0nH0Xd9Tz3uszGdVLdcZDvzwSTVgiLWt02jG49pqagxLnwWCk84Aczc8 puruoNIvYIXjtfF8OLtj/C6wKFMAVYSFVWkFd0+f8slHhzG58vvzhhRv2Q/3L2/lFMk+ g/dA== X-Gm-Message-State: AJIora8qsCw0ErAssVUcDM5Zxv2EdCGn7mxHpOgR0iAT9IKynTISd4QL 11ekgUch6r/GHTJ3Pna5PLcreQ== X-Received: by 2002:a17:902:d905:b0:16a:2917:73dc with SMTP id c5-20020a170902d90500b0016a291773dcmr20464902plz.6.1656001561800; Thu, 23 Jun 2022 09:26:01 -0700 (PDT) Received: from www.outflux.net (smtp.outflux.net. [198.145.64.163]) by smtp.gmail.com with ESMTPSA id az5-20020a170902a58500b0016636256970sm12712658plb.167.2022.06.23.09.26.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Jun 2022 09:26:01 -0700 (PDT) Date: Thu, 23 Jun 2022 09:26:00 -0700 From: Kees Cook To: "Gustavo A. R. Silva" Cc: "Martin K. Petersen" , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, Adaptec OEM Raid Solutions , "James E.J. Bottomley" , linux-hardening@vger.kernel.org Subject: Re: [PATCH 0/8] scsi: aacraid: Replace one-element arrays with flexible-array members Message-ID: <202206230924.A8A4D005@keescook> References: <20220310040347.GA2295236@embeddedor> <20220315042223.GA2385465@embeddedor> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220315042223.GA2385465@embeddedor> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 14, 2022 at 11:22:23PM -0500, Gustavo A. R. Silva wrote: > On Tue, Mar 15, 2022 at 12:02:13AM -0400, Martin K. Petersen wrote: > > > > Gustavo, > > > > > Friendly ping: who can review or comment on this series, please? > > > > I'm afraid I don't have any hardware to test it on and the generated > > output differs substantially from the original code. > > Yeah; this series requires careful review from the people that > knows the code better. > > It took me a day of work to go through all the places that needed > to be changed due to the flexible array transformation. However, > due to the kind of changes, it'd be great to have a second opinion > or at least someone that could take a look at the changes. If the int/size_t changes are separated from the array size change, it's easier to see the array size change is a binary no-op. (i.e. diffoscope shows no executable changes.) I'd recommend splitting the int/size_t changes from the array size changes. -- Kees Cook