From patchwork Fri Dec 13 13:50:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Howells X-Patchwork-Id: 13907057 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 771A8E7717D for ; Fri, 13 Dec 2024 13:50:39 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id AE12F6B0083; Fri, 13 Dec 2024 08:50:38 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id A69636B0085; Fri, 13 Dec 2024 08:50:38 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 8BC7C6B0088; Fri, 13 Dec 2024 08:50:38 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 6B3EA6B0083 for ; Fri, 13 Dec 2024 08:50:38 -0500 (EST) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id DD335AF533 for ; Fri, 13 Dec 2024 13:50:37 +0000 (UTC) X-FDA: 82890070368.05.BC3B036 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by imf24.hostedemail.com (Postfix) with ESMTP id D675718000A for ; Fri, 13 Dec 2024 13:50:32 +0000 (UTC) Authentication-Results: imf24.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=J9u0NfwY; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf24.hostedemail.com: domain of dhowells@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1734097824; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=zFfHFGyfFLnfH39ds9xcldOHx5zC/fcdWITNBPuGcyY=; b=OfhPdIM++YTP8R7sc0vERSCjNj9r0bzGGPIdIdYLntB+J78jgcX4mowxq3nR8gbhfB4d54 PBA4ihyNmLzpNFdCvWcFqDY7XsxAOpl0OIARN/7icVdRFQW85a2lgYUC+eUHvIsIFCWXgc RWB+uBXfxlkskSgWEZk9Zw/ZRbjpdQ0= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1734097824; a=rsa-sha256; cv=none; b=AZ48WHGZv2UNuBkDTyKa4TgR7gAZdYNlg+lP3e+/SrHubCHa1TSlXXnx+ff6VDLDgakfgk kSxWb5lRD8hd6At4tVM1EOO+qf0l44l8bt4ad/ON1ph+J3Lx2N/PO7a0Wnt+qAxPWlhlvK IuQfYtVsn1OqBJyUgDwn5bhaeA6Ws1w= ARC-Authentication-Results: i=1; imf24.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=J9u0NfwY; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf24.hostedemail.com: domain of dhowells@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1734097835; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=zFfHFGyfFLnfH39ds9xcldOHx5zC/fcdWITNBPuGcyY=; b=J9u0NfwYyQzfdcCDiRMwWHEYIxKLB6ONi2wv5iLjX6STtFiyFQH8j1PgmPDIiGVlO7kEM9 Xb9/7R7B23QyfQQX7y+vDaQmKBvbVtwkffIkNBqpHqb9dr/W2MZjrG+KRz9wIE37so2eiD hDLF4oDZs/N7Sz+nWrMhOxPm86qAcDI= Received: from mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-166-qo9Op8B1MvuELGCTRl92nA-1; Fri, 13 Dec 2024 08:50:33 -0500 X-MC-Unique: qo9Op8B1MvuELGCTRl92nA-1 X-Mimecast-MFC-AGG-ID: qo9Op8B1MvuELGCTRl92nA Received: from mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.12]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id A073919560A6; Fri, 13 Dec 2024 13:50:30 +0000 (UTC) Received: from warthog.procyon.org.uk.com (unknown [10.42.28.48]) by mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id BB0A9195394B; Fri, 13 Dec 2024 13:50:23 +0000 (UTC) From: David Howells To: Christian Brauner Cc: David Howells , Max Kellermann , Ilya Dryomov , Xiubo Li , Trond Myklebust , Jeff Layton , Matthew Wilcox , netfs@lists.linux.dev, linux-afs@lists.infradead.org, linux-cifs@vger.kernel.org, linux-nfs@vger.kernel.org, ceph-devel@vger.kernel.org, v9fs@lists.linux.dev, linux-erofs@lists.ozlabs.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Masahiro Yamada , Marc Dionne Subject: [PATCH 01/10] kheaders: Ignore silly-rename files Date: Fri, 13 Dec 2024 13:50:01 +0000 Message-ID: <20241213135013.2964079-2-dhowells@redhat.com> In-Reply-To: <20241213135013.2964079-1-dhowells@redhat.com> References: <20241213135013.2964079-1-dhowells@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.12 X-Stat-Signature: wo5swzt1mg1i1rj7hcn1zs91w88gx4yr X-Rspamd-Queue-Id: D675718000A X-Rspam-User: X-Rspamd-Server: rspam01 X-HE-Tag: 1734097832-196856 X-HE-Meta: U2FsdGVkX18tIgANXv0uMFIsJutIMcHydkV7jZtfnXQZ/1EE5m0OwML9sy5FLgDNOqaltnBtjL3aIHFbmFfz+wecszShbPvm8stcPcsfFKfbPJRSA1MAV8C5s8bOD78fWanOpxZlCQed5x/rdTeqZYraq1YHoxdYSqTTKSsib4Yl1Ay9mCDAo1V5IvgHENHOY1kG+JuwODuHRiVNuL6Cbcghe0fwLGtHeCCnGN7wMN47wP9oTSNrw0bFqlDlh2Vv75HcQT3TpwpzPafqlZC2vW6lzC4TyCEboFiA9zjy+FEvkEswefHexJrVT7P1hKEs0y2L6IngmRhccS/oC91XJewNhCjXJggyU8Hhd8ywdND4mry45KVyO8snRoapOREaoNfMqPiF6BEKqTSrqd2yiFpRCCpUDBhXsSqE0JOSbU2PesduZF2BQY8ujLV2ooJYsrMzObfLHPjgSyDu7kVIYPvq8rnOpC8Y4fo57quuydb77hfnAAGqAYqRnwDB3jslMjHEhqjo8T7YC6NvN7TyuDO0LqWyBItnqJPWtUD3OZVjSFo6YPLC5rTHXL7yJLCbnwilTHJgF6nVLP/sr8Q4y1dPRSTarvgzoOrFUrHYDzPOKofHhCHqhWokv9bceLTvxpRTFH07Pt2s9Zp3wssTjN2zEEvq1xI4GfAH0StkgzewZjfp6p7FonLxo43HtxeeL9vx+DRo+zhBZ87cqb+wcIA7tfKPLZomhm4F+ax2B95xPPIm9uf0+UmrHU8fkMNafTdDcUqypSTOzbEsANnISTJuvavEAGty4n2D/bqBoK/qGzQpoVvQH4Djcv1m6gWiH1BPWSAWYn0T/R3swnFs8jjTP3OkdXpF3JTmFZTPLJay6f2nUTJY6DFNijheI25UylKkbhN5Thkbu9x/2KW/P5eAlII93+oBwt2clshF3485O/8NELtnPOG6pNFne0Jio7KF1wZpalzzRw0+qLU FVnzJ8lv z+bhkLC4VuE9kO5URe+16Km4cCNLMQ1C8HSrMHi0avjMan8URRGdJxwByd2iYA9RPs8bxkwuPbgGkeIS27eZFr1sLPv3wIgH8vuU0thhucdjLnhkNS7kLZOCLRiqJSLfui4MYhXNYHNXJYCe3TkOBzAgHlXwTuA+4YbgySUSDA+nW3abwLOgyaxwDDwff8xd1w1RrCDfRmSD/xnj+/j+ihUP3//CICuH0hKy3Srj18yu0XVc8bsweibt+gpUmfd8CwUXYa+IR5KbibqTzrcuwOE24hr6IsR5h1FJxylE8pCbxky6PEHByuasbcLL8NntHFyC3/HQi4OpK/ndgFBEn9OhR4rC46lWB76fC6vX14FFxSZs3N9uc+fwG0UUlLlcxHv0yQXtaJ852F9r7WpxTbEA65JjVkjOqmhn9OERI8MkP8bnoPytE3NV7hXJ1GX4+ePrEPCZoFM90mKk8PNnRvG9/tA== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Tell tar to ignore silly-rename files (".__afs*" and ".nfs*") when building the header archive. These occur when a file that is open is unlinked locally, but hasn't yet been closed. Such files are visible to the user via the getdents() syscall and so programs may want to do things with them. During the kernel build, such files may be made during the processing of header files and the cleanup may get deferred by fput() which may result in tar seeing these files when it reads the directory, but they may have disappeared by the time it tries to open them, causing tar to fail with an error. Further, we don't want to include them in the tarball if they still exist. With CONFIG_HEADERS_INSTALL=y, something like the following may be seen: find: './kernel/.tmp_cpio_dir/include/dt-bindings/reset/.__afs2080': No such file or directory tar: ./include/linux/greybus/.__afs3C95: File removed before we read it The find warning doesn't seem to cause a problem. Fix this by telling tar when called from in gen_kheaders.sh to exclude such files. This only affects afs and nfs; cifs uses the Windows Hidden attribute to prevent the file from being seen. Signed-off-by: David Howells cc: Masahiro Yamada cc: Marc Dionne cc: linux-afs@lists.infradead.org cc: linux-nfs@vger.kernel.org cc: linux-kernel@vger.kernel.org --- kernel/gen_kheaders.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/gen_kheaders.sh b/kernel/gen_kheaders.sh index 383fd43ac612..7e1340da5aca 100755 --- a/kernel/gen_kheaders.sh +++ b/kernel/gen_kheaders.sh @@ -89,6 +89,7 @@ find $cpio_dir -type f -print0 | # Create archive and try to normalize metadata for reproducibility. tar "${KBUILD_BUILD_TIMESTAMP:+--mtime=$KBUILD_BUILD_TIMESTAMP}" \ + --exclude=".__afs*" --exclude=".nfs*" \ --owner=0 --group=0 --sort=name --numeric-owner --mode=u=rw,go=r,a+X \ -I $XZ -cf $tarfile -C $cpio_dir/ . > /dev/null