diff --git a/fs/bcachefs/movinggc.c b/fs/bcachefs/movinggc.c index d658be90f..8a6568dc5 100644 --- a/fs/bcachefs/movinggc.c +++ b/fs/bcachefs/movinggc.c @@ -327,6 +327,8 @@ static int bch2_copygc_thread(void *arg) u64 last, wait; int ret = 0; + memset(&ctxt, 0, sizeof(ctxt)); + buckets = kzalloc(sizeof(struct buckets_in_flight), GFP_KERNEL); if (!buckets) return -ENOMEM;