Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp3158535pxb; Thu, 10 Feb 2022 13:50:00 -0800 (PST) X-Google-Smtp-Source: ABdhPJxZkf6sq1Q6qOCqtbr4wXht9aIEWHN2d2GJMdb2TrVCUUq6UuiZgJl8flrOzbddorujdH+d X-Received: by 2002:a17:907:97d0:: with SMTP id js16mr8066432ejc.345.1644529799896; Thu, 10 Feb 2022 13:49:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644529799; cv=none; d=google.com; s=arc-20160816; b=hwSIYYvsiPh8sSt6GKMAvMh05lBV8cmoi9M3sTl0Mp8Gu05Xek6F4vxeXoVrtjLjSS EDzb/i5Lx0dBH0+NyozwiPbH/XlXT4UYaF870CBudQu6FKXzVzj7AgK/E4TLNCB31y38 zA+H2M91sZvMkPmfC9CdxhKOnx/YRmWZkWK7oNIxe9/LPf/42RbmoBKC38XQXMu3anwF wn6dEDQf6FlkuTQQwtT5eDFBDtDdyfeAY0KGBaaaorTL8DIqE0AVd9DdEwdyCgMy2WMh R4dh5G7m+g2gHRgSB/XxNur89wvLvG3igB5RvEwvzEaWb3ob4brb4UzLlBjBL2vXQz6s BV4w== 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=BFHj0bDE2ql3swAY1JvHUYSQUDfeEnWV/5IfYHYgHQc=; b=RgxivdvSIUUESklWQVleLOi03nJpNYxUi90+6i8bRdCQzJBhc2XtqV1hfZC5iFiqPA FozqsP5DYNEEmAl0V2tZr5uS3f1IEv+Ko5SJjAHGBz4Nn5U4CiclC07+cMh7FNT3T4f5 hEHe7aG+PocKG0YJz4QBRU6bCb1b6WP/RGj/dFC4MH2QBdoydZgeRxK6WACTBCYZfKuz 45+syGjf7D8E01BopRG3XIZEyC5eYQ+2Gjn9h3tW1sccmKq3oGswNIOo11QeHntkD6XJ vF48in2gXIYZ1K+RpslmUxu1bLkVGbUPPNXzq0rOrV8K3x+j7y0Jepp5rSBRK9u4xUrY EMVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=chrTi4R5; 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 hz6si9657522ejc.351.2022.02.10.13.49.32; Thu, 10 Feb 2022 13:49:59 -0800 (PST) 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=chrTi4R5; 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 S245324AbiBJRqW (ORCPT + 99 others); Thu, 10 Feb 2022 12:46:22 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:51136 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245319AbiBJRqT (ORCPT ); Thu, 10 Feb 2022 12:46:19 -0500 Received: from mail-pj1-x1033.google.com (mail-pj1-x1033.google.com [IPv6:2607:f8b0:4864:20::1033]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0825925C2 for ; Thu, 10 Feb 2022 09:46:20 -0800 (PST) Received: by mail-pj1-x1033.google.com with SMTP id t14-20020a17090a3e4e00b001b8f6032d96so6298316pjm.2 for ; Thu, 10 Feb 2022 09:46:20 -0800 (PST) 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=BFHj0bDE2ql3swAY1JvHUYSQUDfeEnWV/5IfYHYgHQc=; b=chrTi4R50FWzgvjlFK2MFw9uDWaTu3Qv5Ws+vcrV3YJbwXchR0OMrLp/7G0dmHhh2x el2004Nm4t/fHKLgSqiN6BplN4CtdC1/asamqd2BTjCEq9uDdP4dyWiwHBYlF1THpAHE 2cy64j8f94rGFTPOz48TApd78v4dMBfbPAiIA= 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=BFHj0bDE2ql3swAY1JvHUYSQUDfeEnWV/5IfYHYgHQc=; b=GREpIghOMTXh8KmTMwKvV1o4dSdn/uwSb29C/k1gxSOyVQmPjD8SGjAEeSfEmy05UD rXOBYuslOwA5S8y5++laiyklBgtswAJLH4vE2f+QqfQlXGjnO/26iHjBGtN6ANF+Tf5+ YtZFosc6M7+qgJswcPdghxRpYmjKsiUDvGoXmECAvzs952qvLgV9B8R7CI3kQ/GXjn93 bhUwsZhxGnsIOTsS8kDUYLfuJadNb95gAa9WiYXKRWYaGd4oSsSKenFhrzHLT9QEpC8r BUrnHvYDyyEWoF+pMiB3xT4PqwcHfU1gdfUeoecPzOYGaxLjNBQmupmuAvAnB6bMlR1f ynVw== X-Gm-Message-State: AOAM533TvWwAa22oKKoqeubRYEeG/KfeLO3ESd+w7cRQdliQqqXp5Ddp G+US6BgWN4D57yxzN//fbh+bGg== X-Received: by 2002:a17:902:d510:: with SMTP id b16mr8653125plg.152.1644515179460; Thu, 10 Feb 2022 09:46:19 -0800 (PST) Received: from www.outflux.net (smtp.outflux.net. [198.145.64.163]) by smtp.gmail.com with ESMTPSA id u18sm2847762pjn.49.2022.02.10.09.46.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Feb 2022 09:46:18 -0800 (PST) Date: Thu, 10 Feb 2022 09:46:17 -0800 From: Kees Cook To: Shuah Khan Cc: Muhammad Usama Anjum , Eric Biederman , Shuah Khan , Andrew Morton , kernel@collabora.com, kernelci@groups.io, "kernelci.org bot" , linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] selftests/exec: Add non-regular to TEST_GEN_PROGS Message-ID: <202202100945.BCDDA1BE3D@keescook> References: <20220210171323.1304501-1-usama.anjum@collabora.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 Thu, Feb 10, 2022 at 10:34:20AM -0700, Shuah Khan wrote: > On 2/10/22 10:13 AM, Muhammad Usama Anjum wrote: > > non-regular file needs to be compiled and then copied to the output > > directory. Remove it from TEST_PROGS and add it to TEST_GEN_PROGS. This > > removes error thrown by rsync when non-regular object isn't found: > > > > rsync: [sender] link_stat "/linux/tools/testing/selftests/exec/non-regular" failed: No such file or directory (2) > > rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1333) [sender=3.2.3] > > > > Fixes: 0f71241a8e32 ("selftests/exec: add file type errno tests") > > Reported-by: "kernelci.org bot" > > Signed-off-by: Muhammad Usama Anjum > > --- > > tools/testing/selftests/exec/Makefile | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/tools/testing/selftests/exec/Makefile b/tools/testing/selftests/exec/Makefile > > index 551affb437fe1..a89ba6de79870 100644 > > --- a/tools/testing/selftests/exec/Makefile > > +++ b/tools/testing/selftests/exec/Makefile > > @@ -3,8 +3,8 @@ CFLAGS = -Wall > > CFLAGS += -Wno-nonnull > > CFLAGS += -D_GNU_SOURCE > > -TEST_PROGS := binfmt_script non-regular > > -TEST_GEN_PROGS := execveat load_address_4096 load_address_2097152 load_address_16777216 > > +TEST_PROGS := binfmt_script > > +TEST_GEN_PROGS := execveat load_address_4096 load_address_2097152 load_address_16777216 non-regular > > TEST_GEN_FILES := execveat.symlink execveat.denatured script subdir > > # Makefile is a run-time dependency, since it's accessed by the execveat test > > TEST_FILES := Makefile > > > > This change looks good to me. regular is a binary and TEST_GEN_PROGS is > where it belongs. > > Reviewed-by: Shuah Khan > > Also binfmt_script could be renamed to clearly identify that it is python > script. This can be done in a separate patch. Yeah, I agree: that would help with skimming the Makefile for correctness. -- Kees Cook