After we remove ext4 journal callback, transaction->t_private_list is
not used anymore. Just remove unused transaction->t_private_list.
Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com>
---
Documentation/filesystems/journalling.rst | 2 --
fs/jbd2/transaction.c | 1 -
include/linux/jbd2.h | 6 ------
3 files changed, 9 deletions(-)
diff --git a/Documentation/filesystems/journalling.rst b/Documentation/filesystems/journalling.rst
index 0254f7d57429..74f6aa2e1009 100644
--- a/Documentation/filesystems/journalling.rst
+++ b/Documentation/filesystems/journalling.rst
@@ -112,8 +112,6 @@ so that you can do some of your own management. You ask the journalling
layer for calling the callback by simply setting
``journal->j_commit_callback`` function pointer and that function is
called after each transaction commit. You can also use
-``transaction->t_private_list`` for attaching entries to a transaction
-that need processing when the transaction commits.
JBD2 also provides a way to block all transaction updates via
jbd2_journal_lock_updates() /
diff --git a/fs/jbd2/transaction.c b/fs/jbd2/transaction.c
index 66513c18ca29..9fe17e290c21 100644
--- a/fs/jbd2/transaction.c
+++ b/fs/jbd2/transaction.c
@@ -92,7 +92,6 @@ static void jbd2_get_transaction(journal_t *journal,
atomic_set(&transaction->t_outstanding_revokes, 0);
atomic_set(&transaction->t_handle_count, 0);
INIT_LIST_HEAD(&transaction->t_inode_list);
- INIT_LIST_HEAD(&transaction->t_private_list);
/* Set up the commit timer for the new transaction. */
journal->j_commit_timer.expires = round_jiffies_up(transaction->t_expires);
diff --git a/include/linux/jbd2.h b/include/linux/jbd2.h
index 50f7ea8714bf..90c802e48e23 100644
--- a/include/linux/jbd2.h
+++ b/include/linux/jbd2.h
@@ -700,12 +700,6 @@ struct transaction_s
/* Disk flush needs to be sent to fs partition [no locking] */
int t_need_data_flush;
-
- /*
- * For use by the filesystem to store fs-specific data
- * structures associated with the transaction
- */
- struct list_head t_private_list;
};
struct transaction_run_stats_s {
--
2.30.0
On Tue 17-12-24 20:03:55, Kemeng Shi wrote:
> After we remove ext4 journal callback, transaction->t_private_list is
> not used anymore. Just remove unused transaction->t_private_list.
>
> Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com>
After the doc fixup feel free to add:
Reviewed-by: Jan Kara <jack@suse.cz>
Honza
> ---
> Documentation/filesystems/journalling.rst | 2 --
> fs/jbd2/transaction.c | 1 -
> include/linux/jbd2.h | 6 ------
> 3 files changed, 9 deletions(-)
>
> diff --git a/Documentation/filesystems/journalling.rst b/Documentation/filesystems/journalling.rst
> index 0254f7d57429..74f6aa2e1009 100644
> --- a/Documentation/filesystems/journalling.rst
> +++ b/Documentation/filesystems/journalling.rst
> @@ -112,8 +112,6 @@ so that you can do some of your own management. You ask the journalling
> layer for calling the callback by simply setting
> ``journal->j_commit_callback`` function pointer and that function is
> called after each transaction commit. You can also use
> -``transaction->t_private_list`` for attaching entries to a transaction
> -that need processing when the transaction commits.
>
> JBD2 also provides a way to block all transaction updates via
> jbd2_journal_lock_updates() /
> diff --git a/fs/jbd2/transaction.c b/fs/jbd2/transaction.c
> index 66513c18ca29..9fe17e290c21 100644
> --- a/fs/jbd2/transaction.c
> +++ b/fs/jbd2/transaction.c
> @@ -92,7 +92,6 @@ static void jbd2_get_transaction(journal_t *journal,
> atomic_set(&transaction->t_outstanding_revokes, 0);
> atomic_set(&transaction->t_handle_count, 0);
> INIT_LIST_HEAD(&transaction->t_inode_list);
> - INIT_LIST_HEAD(&transaction->t_private_list);
>
> /* Set up the commit timer for the new transaction. */
> journal->j_commit_timer.expires = round_jiffies_up(transaction->t_expires);
> diff --git a/include/linux/jbd2.h b/include/linux/jbd2.h
> index 50f7ea8714bf..90c802e48e23 100644
> --- a/include/linux/jbd2.h
> +++ b/include/linux/jbd2.h
> @@ -700,12 +700,6 @@ struct transaction_s
>
> /* Disk flush needs to be sent to fs partition [no locking] */
> int t_need_data_flush;
> -
> - /*
> - * For use by the filesystem to store fs-specific data
> - * structures associated with the transaction
> - */
> - struct list_head t_private_list;
> };
>
> struct transaction_run_stats_s {
> --
> 2.30.0
>
--
Jan Kara <jack@suse.com>
SUSE Labs, CR
On Tue, Dec 17, 2024 at 08:03:55PM +0800, Kemeng Shi wrote: > +++ b/Documentation/filesystems/journalling.rst > @@ -112,8 +112,6 @@ so that you can do some of your own management. You ask the journalling > layer for calling the callback by simply setting > ``journal->j_commit_callback`` function pointer and that function is > called after each transaction commit. You can also use > -``transaction->t_private_list`` for attaching entries to a transaction > -that need processing when the transaction commits. I think this also needs: -called after each transaction commit. You can also use +called after each transaction commit.
on 12/18/2024 2:02 AM, Matthew Wilcox wrote: > On Tue, Dec 17, 2024 at 08:03:55PM +0800, Kemeng Shi wrote: >> +++ b/Documentation/filesystems/journalling.rst >> @@ -112,8 +112,6 @@ so that you can do some of your own management. You ask the journalling >> layer for calling the callback by simply setting >> ``journal->j_commit_callback`` function pointer and that function is >> called after each transaction commit. You can also use >> -``transaction->t_private_list`` for attaching entries to a transaction >> -that need processing when the transaction commits. > > I think this also needs: > > -called after each transaction commit. You can also use > +called after each transaction commit. > Sure, thanks for correcting. Will fix in next version.
© 2016 - 2025 Red Hat, Inc.