summaryrefslogtreecommitdiff
path: root/fs/bcachefs/trace.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2021-04-01 04:44:55 +0300
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-23 00:08:59 +0300
commit241e26369e1267be376490152ee2c52021b4321a (patch)
tree3959554638d2d03f6d25d8433d1964b1b3532424 /fs/bcachefs/trace.h
parent9d8022db1ccfff6aaf1de6158c2a26b667c70a15 (diff)
downloadlinux-241e26369e1267be376490152ee2c52021b4321a.tar.xz
bcachefs: Don't flush btree writes more aggressively because of btree key cache
We need to flush the btree key cache when it's too dirty, because otherwise the shrinker won't be able to reclaim memory - this is done by journal reclaim. But journal reclaim also kicks btree node writes: this meant that btree node writes were getting kicked much too often just because we needed to flush btree key cache keys. This patch splits journal pins into two different lists, and teaches journal reclaim to not flush btree node writes when it only needs to flush key cache keys. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/trace.h')
-rw-r--r--fs/bcachefs/trace.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/bcachefs/trace.h b/fs/bcachefs/trace.h
index babb07e3acc4..387c1c49f696 100644
--- a/fs/bcachefs/trace.h
+++ b/fs/bcachefs/trace.h
@@ -716,6 +716,11 @@ DEFINE_EVENT(transaction_restart, trans_restart_iter_upgrade,
TP_ARGS(ip)
);
+DEFINE_EVENT(transaction_restart, trans_restart_relock,
+ TP_PROTO(unsigned long ip),
+ TP_ARGS(ip)
+);
+
DEFINE_EVENT(transaction_restart, trans_restart_traverse,
TP_PROTO(unsigned long ip),
TP_ARGS(ip)