bcachefs: Fix triggering of discard by the journal path
authorKent Overstreet <kent.overstreet@linux.dev>
Sat, 12 Jul 2025 23:31:49 +0000 (19:31 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Wed, 16 Jul 2025 21:32:33 +0000 (17:32 -0400)
commitb4d6e204f892846b435ad5df89306a8ad56191f9
treefeb4818276e02e4afcbf4774184958261802978f
parent30792947c6f33175e53ae3b8de3f6971c26505b9
bcachefs: Fix triggering of discard by the journal path

It becomes possible to do discards after a journal flush, which
naturally the journal code is reponsible for.

A prior refactoring seems to have broken this - which went unnoticed
because the foreground allocator path can also trigger discards.

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/journal_io.c