Received: by 2002:a05:7412:da14:b0:e2:908c:2ebd with SMTP id fe20csp2244599rdb; Mon, 9 Oct 2023 19:11:05 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHgFV9+z3Y/KyiQDAN1RPHCzqN62rwT7ZiJaVRyCB90pwfBjkJ5PcjNw9TdL0RLLTMgRryg X-Received: by 2002:a17:902:8343:b0:1c2:82e:32de with SMTP id z3-20020a170902834300b001c2082e32demr16016502pln.0.1696903865177; Mon, 09 Oct 2023 19:11:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696903865; cv=none; d=google.com; s=arc-20160816; b=nCfh5Tnq66ORFN1JCx3Lm/STcrfYcon8S8OKLL1/+21KGgBoAB6tMMIHHAx5xukenu LicnmbsmxfRxGHsuTKLFGWAvTiAT0PlJt5Afk9AeJ/jIbO9BCdRK7Ptw1Iuqjo58QT8T ZFfU3GQvuWIGRoP4fzUYhzqfEgghGAtlmr9xBQ9NhhpdVtNm+C4sBjNx1T9/rtjpZ9Ey T+mvxcSEt5Czqjv7+JBVgkkV5fqUVUEWLNrlWS5zFD8UiFYTX7eYeFQ8mUtdHjV3KeIO Po4vjuG52Q9wlVsXWTs+F12Qjva/guptdC+9LtJTDqNcL2Oz+iHmk3fYGtyX/8J++7+T sdRw== 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=tLdCG6jN7hKzemz3BqeIqgk+1LWVl64DMX/5vSOGzuU=; fh=gwKTCCxOZn95Qp9zASul0Ig3zalKr3cM4L2x+FTjcyA=; b=u2Noe3KtJ/tixDL8TF5U7xq0pEbvRio4vMcD5o2bX3f/Y4BolAlvP/5kv3SmVSlYU9 JzE1dQblL4GjXzhZ22utQC2RT4No0uSXwvQnPEIDnN9sIM3RZ8dvGO93GRfreyMRfx1O uV+Efn0RkQ3LEh+szSda6uefBqhWxGIJxHDW24yLcbzaKYhQSk962ppZI5aRDHqID2yY g+HsgH4rJr+gxINn1snZgdwf6LjxIFPpfP7tfSR+iYRUFwbJ2Vkl6/txxF7KhUXQuAGW zx0nHkRzEe9jDc835Z8maXq9TIkQ1pE+vdk4J9g6YPm4JBhIqKlRBu3DLTSA3Z92/33I IMRg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2023-03-30 header.b=1VSbNAdY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id q6-20020a170902a3c600b001bbaa5e95fdsi90211plb.102.2023.10.09.19.11.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Oct 2023 19:11:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2023-03-30 header.b=1VSbNAdY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 9AFE5807F49E; Mon, 9 Oct 2023 19:10:11 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1441843AbjJJCKE (ORCPT + 99 others); Mon, 9 Oct 2023 22:10:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45940 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1379326AbjJJCKD (ORCPT ); Mon, 9 Oct 2023 22:10:03 -0400 Received: from mx0b-00069f02.pphosted.com (mx0b-00069f02.pphosted.com [205.220.177.32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AA7CCA7; Mon, 9 Oct 2023 19:10:01 -0700 (PDT) Received: from pps.filterd (m0246630.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 399NwuB9016274; Tue, 10 Oct 2023 02:09:44 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type : content-transfer-encoding; s=corp-2023-03-30; bh=tLdCG6jN7hKzemz3BqeIqgk+1LWVl64DMX/5vSOGzuU=; b=1VSbNAdYfjhd59uutV3S/ras1X34agVW3cGcUSEjg8U/657+vAVblWInhj8XJ+38mqyC V9/p9cPxOA1udFDuIl+4+SOU6s9pVo3W7OVhxPHPBYarR8k4CFSCSVH8gztAyMRVGLeJ pNVldwuKDfs88Pp89q5DnbtvqWgwd1lNs8q/xADnNt3vsU5MT2MEPPKz9/r8z+ow0VmZ Nf7gtXF7piozNM2A2vQ3D4R7IdbJusKtbS3TuIosLpyQ85S5q/65922YxTnaCClXK1oF ZRTRZB2AMyBs/rYAXIncrPjio/EKHj/0SUeRVqC7LzEWxtwiONulWYooRnNlk//lquBR Cg== Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.appoci.oracle.com [138.1.114.2]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3tmh89sdk8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 10 Oct 2023 02:09:44 +0000 Received: from pps.filterd (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 39A1JBsp014884; Tue, 10 Oct 2023 02:09:43 GMT Received: from pps.reinject (localhost [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 3tjws63mcb-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 10 Oct 2023 02:09:43 +0000 Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 39A29dUM036611; Tue, 10 Oct 2023 02:09:42 GMT Received: from ca-mkp2.ca.oracle.com.com (mpeterse-ol9.allregionaliads.osdevelopmeniad.oraclevcn.com [100.100.251.135]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTP id 3tjws63m9y-3; Tue, 10 Oct 2023 02:09:42 +0000 From: "Martin K. Petersen" To: Bodo Stroesser , Kees Cook Cc: "Martin K . Petersen" , linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, Nathan Chancellor , Nick Desaulniers , Tom Rix , linux-kernel@vger.kernel.org, llvm@lists.linux.dev, linux-hardening@vger.kernel.org Subject: Re: [PATCH] scsi: target: tcmu: Annotate struct tcmu_tmr with __counted_by Date: Mon, 9 Oct 2023 22:09:34 -0400 Message-Id: <169690017527.1410956.11295274010331353504.b4-ty@oracle.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230922175300.work.148-kees@kernel.org> References: <20230922175300.work.148-kees@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.267,Aquarius:18.0.980,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-10-10_01,2023-10-09_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 mlxlogscore=682 mlxscore=0 bulkscore=0 phishscore=0 suspectscore=0 spamscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2309180000 definitions=main-2310100013 X-Proofpoint-GUID: bkFeGgmIwkMBadGMwEnQVSLRIbis1HxP X-Proofpoint-ORIG-GUID: bkFeGgmIwkMBadGMwEnQVSLRIbis1HxP X-Spam-Status: No, score=2.7 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_SBL_CSS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email 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 (agentk.vger.email [0.0.0.0]); Mon, 09 Oct 2023 19:10:11 -0700 (PDT) X-Spam-Level: ** On Fri, 22 Sep 2023 10:53:01 -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 tcmu_tmr. > > [...] Applied to 6.7/scsi-queue, thanks! [1/1] scsi: target: tcmu: Annotate struct tcmu_tmr with __counted_by https://git.kernel.org/mkp/scsi/c/caf22c969ed1 -- Martin K. Petersen Oracle Linux Engineering