From: Masahiro Yamada <masahiroy@kernel.org>
To: David Howells <dhowells@redhat.com>
Cc: Christian Brauner <christian@brauner.io>,
Max Kellermann <max.kellermann@ionos.com>,
Ilya Dryomov <idryomov@gmail.com>, Xiubo Li <xiubli@redhat.com>,
Trond Myklebust <trondmy@kernel.org>,
Jeff Layton <jlayton@kernel.org>,
Matthew Wilcox <willy@infradead.org>,
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,
Marc Dionne <marc.dionne@auristor.com>
Subject: Re: [PATCH 01/10] kheaders: Ignore silly-rename files
Date: Sat, 21 Dec 2024 14:15:00 +0900 [thread overview]
Message-ID: <CAK7LNAQndCMudAtVRAbfSfnV+XhSMDcnP-s1_GAQh8UiEdLBSg@mail.gmail.com> (raw)
In-Reply-To: <20241213135013.2964079-2-dhowells@redhat.com>
On Fri, Dec 13, 2024 at 10:50 PM David Howells <dhowells@redhat.com> wrote:
>
> 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:
I am confused.
kernel/gen_kheaders.sh is executed when CONFIG_IKHEADERS is enabled.
How is CONFIG_HEADERS_INSTALL related?
> 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.
I picked the following commit.
https://lore.kernel.org/all/20241218202021.17276-1-elsk@google.com/
This shoots the root cause of the 'find' errors.
Does it fix your problems too?
Your patch does not address the 'find' errors.
>
> 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 <dhowells@redhat.com>
> cc: Masahiro Yamada <masahiroy@kernel.org>
> cc: Marc Dionne <marc.dionne@auristor.com>
> 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
>
>
--
Best Regards
Masahiro Yamada
next prev parent reply other threads:[~2024-12-21 5:15 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-13 13:50 [PATCH 00/10] netfs, ceph, nfs, cachefiles: Miscellaneous fixes/changes David Howells
2024-12-13 13:50 ` [PATCH 01/10] kheaders: Ignore silly-rename files David Howells
2024-12-21 5:15 ` Masahiro Yamada [this message]
2024-12-13 13:50 ` [PATCH 02/10] netfs: Fix non-contiguous donation between completed reads David Howells
2024-12-13 13:50 ` [PATCH 03/10] netfs: Fix enomem handling in buffered reads David Howells
2024-12-13 13:50 ` [PATCH 04/10] nfs: Fix oops in nfs_netfs_init_request() when copying to cache David Howells
2024-12-13 13:50 ` [PATCH 05/10] cachefiles: Parse the "secctx" immediately David Howells
2024-12-13 13:50 ` [PATCH 06/10] netfs: Remove redundant use of smp_rmb() David Howells
2024-12-16 10:13 ` Akira Yokosawa
2024-12-13 13:50 ` [PATCH 07/10] netfs: Fix missing barriers by using clear_and_wake_up_bit() David Howells
2024-12-14 10:16 ` Akira Yokosawa
2024-12-14 13:44 ` David Howells
2024-12-16 10:11 ` Akira Yokosawa
2024-12-13 13:50 ` [PATCH 08/10] netfs: Work around recursion by abandoning retry if nothing read David Howells
2024-12-13 13:50 ` [PATCH 09/10] netfs: Fix ceph copy to cache on write-begin David Howells
2024-12-13 13:50 ` [PATCH 10/10] netfs: Fix the (non-)cancellation of copy when cache is temporarily disabled David Howells
2024-12-13 14:04 ` ceph xfstests failures [was Re: [PATCH 00/10] netfs, ceph, nfs, cachefiles: Miscellaneous fixes/changes] David Howells
2024-12-18 15:10 ` Alex Markuze
2024-12-16 20:34 ` [PATCH 11/10] netfs: Fix is-caching check in read-retry David Howells
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAK7LNAQndCMudAtVRAbfSfnV+XhSMDcnP-s1_GAQh8UiEdLBSg@mail.gmail.com \
--to=masahiroy@kernel.org \
--cc=ceph-devel@vger.kernel.org \
--cc=christian@brauner.io \
--cc=dhowells@redhat.com \
--cc=idryomov@gmail.com \
--cc=jlayton@kernel.org \
--cc=linux-afs@lists.infradead.org \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-erofs@lists.ozlabs.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-nfs@vger.kernel.org \
--cc=marc.dionne@auristor.com \
--cc=max.kellermann@ionos.com \
--cc=netfs@lists.linux.dev \
--cc=trondmy@kernel.org \
--cc=v9fs@lists.linux.dev \
--cc=willy@infradead.org \
--cc=xiubli@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox