Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: fdmanana@kernel.org
To: linux-btrfs@vger.kernel.org
Subject: [PATCH 0/9] btrfs: some free space cache fixes and updates
Date: Thu,  4 May 2023 12:04:17 +0100	[thread overview]
Message-ID: <cover.1683196407.git.fdmanana@suse.com> (raw)

From: Filipe Manana <fdmanana@suse.com>

Several updates to the free space cache code (most of it to the in memory
data structure, shared between the free space cache and the free space
tree). A bug fix, some cleanups, minor optimizations and adding several
asserts to verify we are holding the necessary lock(s) when udpating the
in memory space cache - this was motivated by an attempt to debug an
invalid memory access when manipulating the in memory free space cache,
as I suspected we had some code path not taking a required lock before
manipulating the in memory red black tree of free space entries.

Filipe Manana (9):
  btrfs: fix space cache inconsistency after error loading it from disk
  btrfs: avoid extra memory allocation when copying free space cache
  btrfs: avoid searching twice for previous node when merging free space entries
  btrfs: use precomputed end offsets at do_trimming()
  btrfs: simplify arguments to tree_insert_offset()
  btrfs: assert proper locks are held at tree_insert_offset()
  btrfs: assert tree lock is held when searching for free space entries
  btrfs: assert tree lock is held when linking free space
  btrfs: assert tree lock is held when removing free space entries

 fs/btrfs/free-space-cache.c | 111 +++++++++++++++++++++++-------------
 1 file changed, 72 insertions(+), 39 deletions(-)

-- 
2.35.1


             reply	other threads:[~2023-05-04 11:04 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-04 11:04 fdmanana [this message]
2023-05-04 11:04 ` [PATCH 1/9] btrfs: fix space cache inconsistency after error loading it from disk fdmanana
2023-05-05  8:23   ` Anand Jain
2023-05-04 11:04 ` [PATCH 2/9] btrfs: avoid extra memory allocation when copying free space cache fdmanana
2023-05-05  8:27   ` Anand Jain
2023-05-04 11:04 ` [PATCH 3/9] btrfs: avoid searching twice for previous node when merging free space entries fdmanana
2023-05-04 11:04 ` [PATCH 4/9] btrfs: use precomputed end offsets at do_trimming() fdmanana
2023-05-05  9:00   ` Anand Jain
2023-05-04 11:04 ` [PATCH 5/9] btrfs: simplify arguments to tree_insert_offset() fdmanana
2023-05-04 11:04 ` [PATCH 6/9] btrfs: assert proper locks are held at tree_insert_offset() fdmanana
2023-05-04 11:04 ` [PATCH 7/9] btrfs: assert tree lock is held when searching for free space entries fdmanana
2023-05-05  9:44   ` Anand Jain
2023-05-04 11:04 ` [PATCH 8/9] btrfs: assert tree lock is held when linking free space fdmanana
2023-05-05  9:45   ` Anand Jain
2023-05-04 11:04 ` [PATCH 9/9] btrfs: assert tree lock is held when removing free space entries fdmanana
2023-05-05 20:51 ` [PATCH 0/9] btrfs: some free space cache fixes and updates David Sterba

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=cover.1683196407.git.fdmanana@suse.com \
    --to=fdmanana@kernel.org \
    --cc=linux-btrfs@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