Commit 07137e9
Darrick J. Wong
xfs: don't lose solo dquot update transactions
Quota counter updates are tracked via incore objects which hang off the
xfs_trans object. These changes are then turned into dirty log items in
xfs_trans_apply_dquot_deltas just prior to commiting the log items to
the CIL.
However, updating the incore deltas do not cause XFS_TRANS_DIRTY to be
set on the transaction. In other words, a pure quota counter update
will be silently discarded if there are no other dirty log items
attached to the transaction.
This is currently not the case anywhere in the filesystem because quota
updates always dirty at least one other metadata item, but a subsequent
bug fix will add dquot log item precommits, so we actually need a dirty
dquot log item prior to xfs_trans_run_precommits. Also let's not leave
a logic bomb.
Cc: <stable@vger.kernel.org> # v2.6.35
Fixes: 0924378 ("xfs: split out iclog writing from xfs_trans_commit()")
Signed-off-by: "Darrick J. Wong" <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>1 parent 3762113 commit 07137e9
3 files changed
Lines changed: 32 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
104 | | - | |
| 104 | + | |
| 105 | + | |
105 | 106 | | |
106 | 107 | | |
107 | 108 | | |
| |||
173 | 174 | | |
174 | 175 | | |
175 | 176 | | |
176 | | - | |
| 177 | + | |
177 | 178 | | |
178 | 179 | | |
179 | 180 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
866 | 866 | | |
867 | 867 | | |
868 | 868 | | |
| 869 | + | |
869 | 870 | | |
870 | 871 | | |
871 | 872 | | |
| |||
894 | 895 | | |
895 | 896 | | |
896 | 897 | | |
897 | | - | |
898 | | - | |
899 | | - | |
900 | | - | |
901 | | - | |
902 | 898 | | |
903 | 899 | | |
904 | 900 | | |
| |||
924 | 920 | | |
925 | 921 | | |
926 | 922 | | |
927 | | - | |
| 923 | + | |
928 | 924 | | |
929 | 925 | | |
930 | 926 | | |
| |||
1018 | 1014 | | |
1019 | 1015 | | |
1020 | 1016 | | |
1021 | | - | |
| 1017 | + | |
1022 | 1018 | | |
1023 | 1019 | | |
1024 | 1020 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
606 | 606 | | |
607 | 607 | | |
608 | 608 | | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
609 | 627 | | |
610 | 628 | | |
611 | 629 | | |
| |||
642 | 660 | | |
643 | 661 | | |
644 | 662 | | |
645 | | - | |
| 663 | + | |
| 664 | + | |
646 | 665 | | |
647 | 666 | | |
648 | 667 | | |
| |||
671 | 690 | | |
672 | 691 | | |
673 | 692 | | |
674 | | - | |
| 693 | + | |
675 | 694 | | |
676 | | - | |
677 | | - | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
678 | 699 | | |
679 | 700 | | |
680 | 701 | | |
| |||
695 | 716 | | |
696 | 717 | | |
697 | 718 | | |
698 | | - | |
| 719 | + | |
699 | 720 | | |
700 | 721 | | |
701 | 722 | | |
| |||
0 commit comments