All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Disseldorp <ddiss@suse.de>
To: Christoph Hellwig <hch@infradead.org>
Cc: dima@arista.com, Nathan Chancellor <nathan@kernel.org>,
	Nicolas Schier <nicolas.schier@linux.dev>,
	linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org,
	Nicolas Schier <nsc@kernel.org>
Subject: Re: [PATCH RFC] gen_init_cpio: Do fsync() only on regular files
Date: Tue, 7 Oct 2025 16:57:32 +1100	[thread overview]
Message-ID: <20251007165732.66949558.ddiss@suse.de> (raw)
In-Reply-To: <aOSZo8h6l2XNin3C@infradead.org>

On Mon, 6 Oct 2025 21:40:03 -0700, Christoph Hellwig wrote:

> On Tue, Oct 07, 2025 at 12:55:03AM +0100, Dmitry Safonov via B4 Relay wrote:
> > From: Dmitry Safonov <dima@arista.com>
> > 
> > Here at Arista gen_init_cpio is used in testing in order to create
> > an initramfs for specific tests. Most notably, there is a test that does
> > essentially a fork-bomb in kdump/panic kernel, replacing build-time
> > generated init script: instead of doing makedumpfile, it does call
> > shell tests.  
> 
> Why is is using fsync at all?  Seems like this was added in
> 
> commit ae18b94099b04264b32e33b057114024bc72c993
> Author: David Disseldorp <ddiss@suse.de>
> Date:   Tue Aug 19 13:05:45 2025 +1000
> 
>     gen_init_cpio: support -o <output_file> parameter
> 
> without any good explanation.  In general doing a per-file fsync
> is going to horrible wreck performance, and given that no one is
> interested in partial initramfs archives also rather pointless.

I should have explained why in the commit, sorry. The intention was to
catch any FS I/O errors during output archive writeback. fsync() is
called only once as the final I/O.

  reply	other threads:[~2025-10-07  5:57 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-06 23:55 [PATCH RFC] gen_init_cpio: Do fsync() only on regular files Dmitry Safonov
2025-10-06 23:55 ` Dmitry Safonov via B4 Relay
2025-10-07  0:07 ` Dmitry Safonov
2025-10-07  1:17 ` David Disseldorp
2025-10-07  3:09   ` Dmitry Safonov
2025-10-07  4:40 ` Christoph Hellwig
2025-10-07  5:57   ` David Disseldorp [this message]
2025-10-07  6:03     ` Christoph Hellwig
2025-10-07  6:25       ` David Disseldorp
2025-10-07  6:28         ` Christoph Hellwig

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=20251007165732.66949558.ddiss@suse.de \
    --to=ddiss@suse.de \
    --cc=dima@arista.com \
    --cc=hch@infradead.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nathan@kernel.org \
    --cc=nicolas.schier@linux.dev \
    --cc=nsc@kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.