]> git.sesse.net Git - bcachefs-tools-debian/blobdiff - libbcachefs/journal_io.c
Update bcachefs sources to 9a555a741e80 bcachefs: omit alignment attribute on big...
[bcachefs-tools-debian] / libbcachefs / journal_io.c
index 057e7c6113157775366b187aad54c613cd91404b..16c1249c84e09ee91529cbae8b0b719f86b2c7b4 100644 (file)
@@ -1506,8 +1506,8 @@ static int journal_write_alloc(struct journal *j, struct journal_buf *w)
                c->opts.foreground_target;
        unsigned i, replicas = 0, replicas_want =
                READ_ONCE(c->opts.metadata_replicas);
-       unsigned replicas_need = min(replicas_want,
-                                    READ_ONCE(c->opts.metadata_replicas_required));
+       unsigned replicas_need = min_t(unsigned, replicas_want,
+                                      READ_ONCE(c->opts.metadata_replicas_required));
 
        rcu_read_lock();
 retry: