Re: ext4: dev: Broken with CONFIG_JBD2=and CONFIG_EXT4_FS=m

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 9, 2020 at 3:49 PM Sedat Dilek <sedat.dilek@xxxxxxxxx> wrote:
>
> Hi Ted,
>
> with <ext4.git#dev> up to commit
> ab7b179af3f98772f2433ddc4ace6b7924a4e862 ("Merge branch
> 'hs/fast-commit-v9' into dev") I see some warnings (were reported via
> kernel-test-bot)...
>
> fs/jbd2/recovery.c:241:15: warning: unused variable 'seq' [-Wunused-variable]
> fs/ext4/fast_commit.c:1091:6: warning: variable 'start_time' is used
> uninitialized whenever 'if' condition is true
> [-Wsometimes-uninitialized]
> fs/ext4/fast_commit.c:1091:6: warning: variable 'start_time' is used
> uninitialized whenever '||' condition is true
> [-Wsometimes-uninitialized]
>
> ...and more severe a build breakage with CONFIG_JBD2=and CONFIG_EXT4_FS=m
>
> ERROR: modpost: "jbd2_fc_release_bufs" [fs/ext4/ext4.ko] undefined!
> ERROR: modpost: "jbd2_fc_init" [fs/ext4/ext4.ko] undefined!
> ERROR: modpost: "jbd2_fc_stop_do_commit" [fs/ext4/ext4.ko] undefined!
> ERROR: modpost: "jbd2_fc_stop" [fs/ext4/ext4.ko] undefined!
> ERROR: modpost: "jbd2_fc_start" [fs/ext4/ext4.ko] undefined!
>
> Looks like missing exports.
>

This fixes it...

$ git diff
diff --git a/fs/jbd2/journal.c b/fs/jbd2/journal.c
index 8a51c1ad7088..e50aeefaa217 100644
--- a/fs/jbd2/journal.c
+++ b/fs/jbd2/journal.c
@@ -754,6 +754,7 @@ int jbd2_fc_start(journal_t *journal, tid_t tid)

       return 0;
}
+EXPORT_SYMBOL(jbd2_fc_start);

/*
 * Stop a fast commit. If fallback is set, this function starts commit of
@@ -778,11 +779,13 @@ int jbd2_fc_stop(journal_t *journal)
{
       return __jbd2_fc_stop(journal, 0, 0);
}
+EXPORT_SYMBOL(jbd2_fc_stop);

int jbd2_fc_stop_do_commit(journal_t *journal, tid_t tid)
{
       return __jbd2_fc_stop(journal, tid, 1);
}
+EXPORT_SYMBOL(jbd2_fc_stop_do_commit);

/* Return 1 when transaction with given tid has already committed. */
int jbd2_transaction_committed(journal_t *journal, tid_t tid)
@@ -954,6 +957,7 @@ int jbd2_fc_release_bufs(journal_t *journal)

       return 0;
}
+EXPORT_SYMBOL(jbd2_fc_release_bufs);

/*
 * Conversion of logical to physical block numbers for the journal
@@ -1389,6 +1393,7 @@ int jbd2_fc_init(journal_t *journal, int num_fc_blks)
               return -ENOMEM;
       return 0;
}
+EXPORT_SYMBOL(jbd2_fc_init);

/* jbd2_journal_init_dev and jbd2_journal_init_inode:
 *

- Sedat -
diff --git a/fs/jbd2/journal.c b/fs/jbd2/journal.c
index 8a51c1ad7088..e50aeefaa217 100644
--- a/fs/jbd2/journal.c
+++ b/fs/jbd2/journal.c
@@ -754,6 +754,7 @@ int jbd2_fc_start(journal_t *journal, tid_t tid)
 
 	return 0;
 }
+EXPORT_SYMBOL(jbd2_fc_start);
 
 /*
  * Stop a fast commit. If fallback is set, this function starts commit of
@@ -778,11 +779,13 @@ int jbd2_fc_stop(journal_t *journal)
 {
 	return __jbd2_fc_stop(journal, 0, 0);
 }
+EXPORT_SYMBOL(jbd2_fc_stop);
 
 int jbd2_fc_stop_do_commit(journal_t *journal, tid_t tid)
 {
 	return __jbd2_fc_stop(journal, tid, 1);
 }
+EXPORT_SYMBOL(jbd2_fc_stop_do_commit);
 
 /* Return 1 when transaction with given tid has already committed. */
 int jbd2_transaction_committed(journal_t *journal, tid_t tid)
@@ -954,6 +957,7 @@ int jbd2_fc_release_bufs(journal_t *journal)
 
 	return 0;
 }
+EXPORT_SYMBOL(jbd2_fc_release_bufs);
 
 /*
  * Conversion of logical to physical block numbers for the journal
@@ -1389,6 +1393,7 @@ int jbd2_fc_init(journal_t *journal, int num_fc_blks)
 		return -ENOMEM;
 	return 0;
 }
+EXPORT_SYMBOL(jbd2_fc_init);
 
 /* jbd2_journal_init_dev and jbd2_journal_init_inode:
  *

[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux