]> git.ipfire.org Git - thirdparty/linux.git/blobdiff - fs/ocfs2/journal.c
Merge tag 'ext4_for_linus-6.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git...
[thirdparty/linux.git] / fs / ocfs2 / journal.c
index e8e7d47265aa95fd897f8332f9a99f21a05274ef..ce215565d061ed98686dc075923d7a7503b96cd9 100644 (file)
@@ -908,9 +908,9 @@ int ocfs2_journal_init(struct ocfs2_super *osb, int *dirty)
 
        /* call the kernels journal init function now */
        j_journal = jbd2_journal_init_inode(inode);
-       if (j_journal == NULL) {
+       if (IS_ERR(j_journal)) {
                mlog(ML_ERROR, "Linux journal layer error\n");
-               status = -EINVAL;
+               status = PTR_ERR(j_journal);
                goto done;
        }
 
@@ -1684,9 +1684,9 @@ static int ocfs2_replay_journal(struct ocfs2_super *osb,
        }
 
        journal = jbd2_journal_init_inode(inode);
-       if (journal == NULL) {
+       if (IS_ERR(journal)) {
                mlog(ML_ERROR, "Linux journal layer error\n");
-               status = -EIO;
+               status = PTR_ERR(journal);
                goto done;
        }