Commit 8d71fc2
ext4: prevent used blocks from being allocated during fast commit replay
commit 599ea31 upstream.
During fast commit replay procedure, we clear inode blocks bitmap in
ext4_ext_clear_bb(), this may cause ext4_mb_new_blocks_simple() allocate
blocks still in use.
Make ext4_fc_record_regions() also record physical disk regions used by
inodes during replay procedure. Then ext4_mb_new_blocks_simple() can
excludes these blocks in use.
Signed-off-by: Xin Yin <yinxin.x@bytedance.com>
Link: https://lore.kernel.org/r/20220110035141.1980-2-yinxin.x@bytedance.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent ef2053a commit 8d71fc2
3 files changed
Lines changed: 22 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2779 | 2779 | | |
2780 | 2780 | | |
2781 | 2781 | | |
| 2782 | + | |
| 2783 | + | |
| 2784 | + | |
2782 | 2785 | | |
2783 | 2786 | | |
2784 | 2787 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6088 | 6088 | | |
6089 | 6089 | | |
6090 | 6090 | | |
| 6091 | + | |
| 6092 | + | |
6091 | 6093 | | |
6092 | 6094 | | |
6093 | 6095 | | |
6094 | 6096 | | |
6095 | 6097 | | |
| 6098 | + | |
| 6099 | + | |
6096 | 6100 | | |
6097 | 6101 | | |
6098 | 6102 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1558 | 1558 | | |
1559 | 1559 | | |
1560 | 1560 | | |
1561 | | - | |
1562 | | - | |
| 1561 | + | |
| 1562 | + | |
| 1563 | + | |
1563 | 1564 | | |
1564 | | - | |
1565 | | - | |
| 1565 | + | |
| 1566 | + | |
1566 | 1567 | | |
1567 | 1568 | | |
1568 | 1569 | | |
1569 | 1570 | | |
1570 | 1571 | | |
| 1572 | + | |
| 1573 | + | |
| 1574 | + | |
| 1575 | + | |
| 1576 | + | |
| 1577 | + | |
1571 | 1578 | | |
1572 | 1579 | | |
1573 | 1580 | | |
| |||
1585 | 1592 | | |
1586 | 1593 | | |
1587 | 1594 | | |
| 1595 | + | |
| 1596 | + | |
| 1597 | + | |
1588 | 1598 | | |
1589 | 1599 | | |
1590 | 1600 | | |
| |||
1954 | 1964 | | |
1955 | 1965 | | |
1956 | 1966 | | |
1957 | | - | |
| 1967 | + | |
1958 | 1968 | | |
1959 | 1969 | | |
1960 | 1970 | | |
| |||
0 commit comments