All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mikulas Patocka <mpatocka@redhat.com>
To: Benjamin Marzinski <bmarzins@redhat.com>
Cc: Mike Snitzer <snitzer@redhat.com>,
	dm-devel@lists.linux.dev,  Damien Le Moal <dlemoal@kernel.org>,
	 Christian Loehle <christian.loehle@arm.com>
Subject: Re: [PATCH] dm-delay: don't busy-wait in kthread
Date: Mon, 14 Apr 2025 22:09:10 +0200 (CEST)	[thread overview]
Message-ID: <af034f2a-8b47-cbe2-cfbc-d30eeea6dad4@redhat.com> (raw)
In-Reply-To: <Z_09e7Zddckboca9@redhat.com>



On Mon, 14 Apr 2025, Benjamin Marzinski wrote:

> > cond_resched() shouldn't be removed because fsleep may fall back to 
> > udelay.
> 
> Again, your version is fine, but I'm not sure that cond_resched() was
> ever necessary, since there already is one in flush_delayed_bios().
> Also, at least the way it's currently coded, fsleep() will only resort
> to busy-waiting when the delay is 10 us or less, and the shortest it can
> be with this code is 62 us, so I don't think this cond_resched() will
> ever do anything.

Yes, but this is implementation detail that may change. Someone may change 
fsleep to spin for larger timeout without knowing that dm-delay depends on 
fsleep not spinning.

> > The patch should increase target version.
> > 
> > I fixed the patch so that it applies on the top Linus' tree and applied 
> > it to the linux-dm tree.
> > 
> > BTW. do we need to backport this to the stable kernels? I think not, but 
> > if you have some reason why should we backport it, explain it.
> 
> dm-delay is basically a testing target, so I agree that it seems
> unnecessary to backport this.
> 
> -Ben

OK, so I removed the "Fixes:" tag.

Mikulas


      parent reply	other threads:[~2025-04-14 20:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-11 20:56 [PATCH] dm-delay: don't busy-wait in kthread Benjamin Marzinski
2025-04-11 21:12 ` Benjamin Marzinski
2025-04-14  0:00 ` Damien Le Moal
2025-04-14  0:16 ` Damien Le Moal
2025-04-14 13:52 ` Mikulas Patocka
2025-04-14 16:53   ` Benjamin Marzinski
2025-04-14 17:06     ` Benjamin Marzinski
2025-04-14 20:09     ` Mikulas Patocka [this message]

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=af034f2a-8b47-cbe2-cfbc-d30eeea6dad4@redhat.com \
    --to=mpatocka@redhat.com \
    --cc=bmarzins@redhat.com \
    --cc=christian.loehle@arm.com \
    --cc=dlemoal@kernel.org \
    --cc=dm-devel@lists.linux.dev \
    --cc=snitzer@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 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.