Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp129904rdb; Fri, 29 Sep 2023 20:41:04 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHBghxlqhfQtne0AnNRmP0u7aiXTYHWf8diUipj44HLiY97RQqQ5Bb/PuBuMTbf1mF/DHHd X-Received: by 2002:a05:6a00:3908:b0:690:ca4e:661e with SMTP id fh8-20020a056a00390800b00690ca4e661emr5512426pfb.19.1696045263941; Fri, 29 Sep 2023 20:41:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696045263; cv=none; d=google.com; s=arc-20160816; b=hTAJD10eRX3xUGW2ZxYtZGvP8ZOn1EVKxiN98Y0n8iNtW+4Iflv0BpoiZkzT/ynlx2 Q8u916GThBkn/+8WD9GVUstfGWJWfquKZVIEdcjy9x+7eGxX4zrCF56q2OArCtDe798m LOmUp+KllOFj+5qwdK0tNYDsSCLtwi8o0A/qefg8DcHt908ecAfozArrd7JKQy5mB49O W23e6Tgc87pxDh1k7OwE2yBmopqZY/jmtau4IYBP41Gb/5jUPl+a9V+4D1peHcl1Ow/A qwzJWcRwYKn/+2vsYFEfO/HKE9TVndXQjLwa5h3DLqvBM+zCa6Fv2bV1rKCYIiSrQB8H D2/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=uDYWsdWil9zbQW5R6gj/5ZmSzR6wTayh9fz7CUaf8pU=; fh=gmNiTh9Hts0UHjc8ZYBzhiZIfIRQfd/vBlw5cI9tFWg=; b=p2c2E7F0RRJaBXPv1fu+d66jBNsXx7/TVCmjUEZ+7LOYHLfR4THIUvZtAqnFChKwbW caooZQsO73UEg1ma2JbVAAYeNb/PbKUKiCT/tzdUfO6WQh40AqGCOR3qcctq1VUx/9g9 P4Gt2OHaLmLOPNJsoEfcG9kCr7YudiqveSyqlLPz+QLw1GU7U6xsVYafa75BHP+QcY3s 3hdPTrAPS1LIvpxCngr5OOJznBdPKIFGZjD0HFuJrhu3dDAp8/wDgqdrxrbk8i1nZRAr qSl5uyELGFFQ2Tk8qUZ8gih0UVmlN5TM2t6NXaAlcGsH91kqTT/EXy/P5WFTdk085TfM m2dA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Goktd67T; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id w14-20020a63474e000000b00578e98dec9dsi22423937pgk.160.2023.09.29.20.41.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Sep 2023 20:41:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Goktd67T; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 306818116E50; Fri, 29 Sep 2023 12:17:59 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233786AbjI2TRx (ORCPT + 99 others); Fri, 29 Sep 2023 15:17:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60174 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233498AbjI2TRv (ORCPT ); Fri, 29 Sep 2023 15:17:51 -0400 Received: from mail-pf1-x42d.google.com (mail-pf1-x42d.google.com [IPv6:2607:f8b0:4864:20::42d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 41E151AE for ; Fri, 29 Sep 2023 12:17:49 -0700 (PDT) Received: by mail-pf1-x42d.google.com with SMTP id d2e1a72fcca58-690bccb0d8aso11790482b3a.0 for ; Fri, 29 Sep 2023 12:17:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1696015068; x=1696619868; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=uDYWsdWil9zbQW5R6gj/5ZmSzR6wTayh9fz7CUaf8pU=; b=Goktd67Tg8lYDKiXaINvkN3AaVpYaA3ud8M9AflT92uWcrPjuVt1t4P2eH5blKq/yT NZ8ulKNgRaJZqwgFxJWaZi6BAGE/xo2xkMZSat/WyY1NNpXc71HMFCKL/lGgmtQdIAs7 AkHJueEsis8GCrXrwsH7SBHV9+albejbZoEd0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696015068; x=1696619868; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=uDYWsdWil9zbQW5R6gj/5ZmSzR6wTayh9fz7CUaf8pU=; b=Yc+a3g2fAWGixNljSdyIOpa18o0Tb8fJpoReEPUUs2CLsedgT24Jk0Mqrq0gicdYjb c8nhaVjnasyLwomZVy8xFeYnlOOVfky4JcaYt/tdSdsDPNikVSoZFQTBI1qJDRfEAQRT oM+nqgdaPBmD5tOb79ozh/jVIqws530QA4T3fquufb+wqGgjVgTs1gCL+4DYIOYBFwmb 00NVy6PbIIIejO7L8ymwVUpUnPpsa3gczkbuzFZ2Pl5tTs5q90hIlk0bKt3nWC4VDmda Kw01AD2ixDF1KBJluxO/noFXDdGeoprOzA4QRcaMGMh+T9uPtw+Y+WxCG8k5orbPguAx WFDA== X-Gm-Message-State: AOJu0YwLgp1DRBvk9AUrgtaBSQFty/VsMxPjwAgnVHw0jYCs/wIfmwyA 0ax3ozVd3h9DdYiv6uNok8BUUA== X-Received: by 2002:a05:6a21:a593:b0:14c:ad99:22a9 with SMTP id gd19-20020a056a21a59300b0014cad9922a9mr6139280pzc.32.1696015068592; Fri, 29 Sep 2023 12:17:48 -0700 (PDT) Received: from www.outflux.net (198-0-35-241-static.hfc.comcastbusiness.net. [198.0.35.241]) by smtp.gmail.com with ESMTPSA id n3-20020aa79043000000b0068e12e6954csm4745873pfo.36.2023.09.29.12.17.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Sep 2023 12:17:47 -0700 (PDT) From: Kees Cook To: Mark Fasheh , Kees Cook Cc: Joel Becker , Joseph Qi , ocfs2-devel@lists.linux.dev, Nathan Chancellor , Nick Desaulniers , Tom Rix , linux-kernel@vger.kernel.org, llvm@lists.linux.dev, linux-hardening@vger.kernel.org Subject: Re: [PATCH] ocfs2: Annotate struct ocfs2_slot_info with __counted_by Date: Fri, 29 Sep 2023 12:17:46 -0700 Message-Id: <169601506493.3012633.12707221094157928597.b4-ty@chromium.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230915201522.never.979-kees@kernel.org> References: <20230915201522.never.979-kees@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS 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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Fri, 29 Sep 2023 12:17:59 -0700 (PDT) On Fri, 15 Sep 2023 13:15:23 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexing) and CONFIG_FORTIFY_SOURCE (for strcpy/memcpy-family > functions). > > As found with Coccinelle[1], add __counted_by for struct ocfs2_slot_info. > > [...] Applied to for-next/hardening, thanks! [1/1] ocfs2: Annotate struct ocfs2_slot_info with __counted_by https://git.kernel.org/kees/c/7c993785ae63 Take care, -- Kees Cook