bcachefs: Add a cond_resched call to the copygc main loop
authorKent Overstreet <kent.overstreet@gmail.com>
Tue, 25 May 2021 22:42:05 +0000 (18:42 -0400)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:09:04 +0000 (17:09 -0400)
commitc4d4b2f01abd95af7c6dccf236e2760aef5a9b69
tree064a769a536a115afe5f5272bd7ec1ecc4234b68
parent443d2760e51f3e17ddb47ddaf969ba49e6dbd06d
bcachefs: Add a cond_resched call to the copygc main loop

We seem to have a bug where the copygc thread ends up spinning and
making the system unusable - this will at least prevent it from locking
up the machine, and it's a good thing to have anyways.

Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
fs/bcachefs/movinggc.c