public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH 1/2] xfs: limit entries returned when counting fsmap records
Date: Fri, 2 Oct 2020 08:06:44 +0100	[thread overview]
Message-ID: <20201002070644.GA32516@infradead.org> (raw)
In-Reply-To: <160161416467.1967459.10753396346204946090.stgit@magnolia>

On Thu, Oct 01, 2020 at 09:49:24PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <darrick.wong@oracle.com>
> 
> If userspace asked fsmap to count the number of entries, we cannot
> return more than UINT_MAX entries because fmh_entries is u32.
> Therefore, stop counting if we hit this limit or else we will waste time
> to return truncated results.

Looks good,

Reviewed-by: Christoph Hellwig <hch@lst.de>

(after remembering the magic repurposing of -ECANCELED in the fsmap
code)

  reply	other threads:[~2020-10-02  7:06 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-02  4:49 [PATCH 0/2] xfs: a few fixes and cleanups to GETFSMAP Darrick J. Wong
2020-10-02  4:49 ` [PATCH 1/2] xfs: limit entries returned when counting fsmap records Darrick J. Wong
2020-10-02  7:06   ` Christoph Hellwig [this message]
2020-10-02  8:51   ` Chandan Babu R
2020-10-02  4:49 ` [PATCH 2/2] xfs: streamline xfs_getfsmap performance Darrick J. Wong
2020-10-02  7:15   ` Christoph Hellwig
2020-10-02 17:58     ` Darrick J. Wong
2020-10-05  6:30       ` Christoph Hellwig
2020-10-05 17:02         ` Darrick J. Wong
2020-10-02  8:52   ` Chandan Babu R
2020-10-04 19:14   ` [PATCH v1.2 2/2] xfs: fix deadlock and " Darrick J. Wong
  -- strict thread matches above, loose matches on Subject: below --
2020-10-05 18:21 [PATCH v2 0/2] xfs: a few fixes and cleanups to GETFSMAP Darrick J. Wong
2020-10-05 18:21 ` [PATCH 1/2] xfs: limit entries returned when counting fsmap records Darrick J. Wong

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=20201002070644.GA32516@infradead.org \
    --to=hch@infradead.org \
    --cc=darrick.wong@oracle.com \
    --cc=linux-xfs@vger.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox