Received: by 2002:a05:7412:37c9:b0:e2:908c:2ebd with SMTP id jz9csp1344410rdb; Wed, 20 Sep 2023 06:49:03 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEaQnPdcgUfT09u2jAtUF5+BItmCQH1Nwent+FJzOQ6uVh+Y5fNGyR32HEDgE3mvpImLF9U X-Received: by 2002:a05:6358:9924:b0:139:c82c:46dd with SMTP id w36-20020a056358992400b00139c82c46ddmr3138341rwa.10.1695217743284; Wed, 20 Sep 2023 06:49:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695217743; cv=none; d=google.com; s=arc-20160816; b=z0E2FYZnao/yBHgnhaGqZWVVhnnc9JfIEcaeYDWdCLj4orsfcskPTxyw9DLjOB1k+C sQEpYgzXf6vyb6hMB9LaI5IlOXnrEZUpaqkAsc246/JJSA3gqFTFMinU7IMDkl9mOCl3 NoKS5+l/qyKg5mDoUFIpjpidRezh1Y+up1EeAo8rXmJGhCOKRSqfpK8+YTHsce+iA0OQ XkhrSDUQb+/w6VD+9X/xeZXDWfxqnwxni6M4PxlxajN8EhjrnP4njWa6+nQeu1qKnbXY AASWg4ZxaigH9zn83F1poXhPcuSe7oljkNJoS/pRZooqAdQlQZ/M3YPbl8Z+OCLIPuUM 8AUg== 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:date :message-id:subject:references:in-reply-to:cc:to:from:dkim-signature; bh=EIbwI+llCQZNHb8o4RO3KbBwaOxuyggW74l96yAp7nI=; fh=xvLIIjrCKtxGrcmIRryI8L3jLajytLK96nxJTOpsY3w=; b=OD8Pxh3QFupzNswzNNpv4f894HgD1tP/tCirBV/COJl+OYaqyQYecfd0IZDyAA5dgi WMUMHUl2wrd3IGnopPYFwlS/JnCI9+Dw4nNejeA0IaQurZw0c6ZHTvOAB1WjR8YxG382 QPmDEqfA4TLD/0xkx/yJgb5ZcF8lOWhwqeFSoaU7LCqNkJQYPUcchm70uRif5ezvgogt I2Ittij8RGEi6x7jQJqhqAilHYWay0pOWZYBCkqZ39cjYAFiJVZIMvuiq3n/9KhrEX43 i7InYrhY2FljL+2dpz+S7WXCvQowN2pKzIcyocyXhy9i105Bmjeac9fC1ZYXlV9+ETp8 UKtw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=NfoV8bIt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id b25-20020a630c19000000b00564f803b104si11648410pgl.519.2023.09.20.06.49.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 06:49:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=NfoV8bIt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 8D11E825A6D5; Wed, 20 Sep 2023 06:35:35 -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 S236047AbjITNfh (ORCPT + 99 others); Wed, 20 Sep 2023 09:35:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37164 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234686AbjITNff (ORCPT ); Wed, 20 Sep 2023 09:35:35 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 49508D8; Wed, 20 Sep 2023 06:35:28 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id EC8AFC433C8; Wed, 20 Sep 2023 13:35:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695216927; bh=XOJB4ugM+cR3vGS6Flq4w3KzGhy52BGvvhYoUHMdbyM=; h=From:To:Cc:In-Reply-To:References:Subject:Date:From; b=NfoV8bItEvkFAnHF36MmLxcTVuQ7VSCT0le95ZO6wKefQMHFv21hTn/OMS78IWTW9 w3I76Et9G7W9nuLdS5+vzeeDvZSZuAOoY5yFUf8hILIHyFA9ycDvFIEWzOiCWQ0dPX 0VhSikuiP3Vi2PvG0hCRdI5dRWGr+s0oD5boWN5NuRBSF7vlBWxWBKYeqkvbvm1vV4 wN9ZpTulGECoSzN8S3DEKBWJ1QDDu/z6dvg4xM4b5Ns84Cou+2XXlTT0ecYrpndSCz sSEv84NiZuHhWv6W1NAazJ3AfEtH08IawA7UTW7P+MLfyj26CPY18NSt7svJ7frUGC 7ChsKz5qVI0Hw== From: Lee Jones To: Pavel Machek , Kees Cook Cc: Lee Jones , linux-leds@vger.kernel.org, Nathan Chancellor , Nick Desaulniers , Tom Rix , linux-kernel@vger.kernel.org, llvm@lists.linux.dev, linux-hardening@vger.kernel.org In-Reply-To: <20230915200938.never.767-kees@kernel.org> References: <20230915200938.never.767-kees@kernel.org> Subject: Re: (subset) [PATCH] leds: aw200xx: Annotate struct aw200xx with __counted_by Message-Id: <169521692572.3439618.17540674957048720159.b4-ty@kernel.org> Date: Wed, 20 Sep 2023 14:35:25 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Mailer: b4 0.12.2 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]); Wed, 20 Sep 2023 06:35:35 -0700 (PDT) On Fri, 15 Sep 2023 13:09:39 -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 aw200xx. > > [...] Applied, thanks! [1/1] leds: aw200xx: Annotate struct aw200xx with __counted_by commit: e43d6b679091d196d9ac7664035155ed4c9637cc -- Lee Jones [李琼斯]