All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Sandeen <sandeen@sandeen.net>
To: David Howells <dhowells@redhat.com>, Eric Sandeen <sandeen@redhat.com>
Cc: linux-fsdevel <linux-fsdevel@vger.kernel.org>,
	Lukas Schauer <lukas@schauer.dev>
Subject: Re: [RFC PATCH 2/2] watch_queue: Fix pipe accounting
Date: Fri, 14 Feb 2025 10:58:44 -0600	[thread overview]
Message-ID: <0a3f44cb-46f1-4ffe-ba8e-ce7f0cee1bc1@sandeen.net> (raw)
In-Reply-To: <4145092.1739551762@warthog.procyon.org.uk>

On 2/14/25 10:49 AM, David Howells wrote:
> Eric Sandeen <sandeen@redhat.com> wrote:
> 
>> -	if (!pipe_has_watch_queue(pipe)) {
>> -		pipe->max_usage = nr_slots;
>> -		pipe->nr_accounted = nr_slots;
>> -	}
>> +	pipe->max_usage = nr_slots;
>> +	pipe->nr_accounted = nr_slots;
> 
> Hmmm...   The pipe ring is supposed to have some spare capacity when used as a
> watch queue so that you can bung at least a few messages into it.

If the pipe has an original number of buffers on it, and
then watch_queue_set_size adjusts that number - where does
the spare capacity come from? Who adds it / where?

Thanks,
-Eric

> David
> 
> 


  reply	other threads:[~2025-02-14 16:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-14 15:34 [RFC PATCH 0/2] watch_queue: Fix pipe allocation and accounting Eric Sandeen
2025-02-14 15:37 ` [RFC PATCH 1/2] watch_queue: Fix pipe buffer allocation Eric Sandeen
2025-02-14 15:38 ` [RFC PATCH 2/2] watch_queue: Fix pipe accounting Eric Sandeen
2025-02-14 16:49   ` David Howells
2025-02-14 16:58     ` Eric Sandeen [this message]
2025-02-14 17:36       ` Eric Sandeen
2025-02-14 16:28 ` [RFC PATCH 0/2] watch_queue: Fix pipe allocation and accounting Eric Sandeen

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=0a3f44cb-46f1-4ffe-ba8e-ce7f0cee1bc1@sandeen.net \
    --to=sandeen@sandeen.net \
    --cc=dhowells@redhat.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=lukas@schauer.dev \
    --cc=sandeen@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.