Commit 599ea31
ext4: prevent used blocks from being allocated during fast commit replay
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.org1 parent 6eeaf88 commit 599ea31
3 files changed
Lines changed: 22 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2934 | 2934 | | |
2935 | 2935 | | |
2936 | 2936 | | |
| 2937 | + | |
| 2938 | + | |
| 2939 | + | |
2937 | 2940 | | |
2938 | 2941 | | |
2939 | 2942 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6093 | 6093 | | |
6094 | 6094 | | |
6095 | 6095 | | |
| 6096 | + | |
| 6097 | + | |
6096 | 6098 | | |
6097 | 6099 | | |
6098 | 6100 | | |
6099 | 6101 | | |
6100 | 6102 | | |
| 6103 | + | |
| 6104 | + | |
6101 | 6105 | | |
6102 | 6106 | | |
6103 | 6107 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1563 | 1563 | | |
1564 | 1564 | | |
1565 | 1565 | | |
1566 | | - | |
1567 | | - | |
| 1566 | + | |
| 1567 | + | |
| 1568 | + | |
1568 | 1569 | | |
1569 | | - | |
1570 | | - | |
| 1570 | + | |
| 1571 | + | |
1571 | 1572 | | |
1572 | 1573 | | |
1573 | 1574 | | |
1574 | 1575 | | |
1575 | 1576 | | |
| 1577 | + | |
| 1578 | + | |
| 1579 | + | |
| 1580 | + | |
| 1581 | + | |
| 1582 | + | |
1576 | 1583 | | |
1577 | 1584 | | |
1578 | 1585 | | |
| |||
1590 | 1597 | | |
1591 | 1598 | | |
1592 | 1599 | | |
| 1600 | + | |
| 1601 | + | |
| 1602 | + | |
1593 | 1603 | | |
1594 | 1604 | | |
1595 | 1605 | | |
| |||
1937 | 1947 | | |
1938 | 1948 | | |
1939 | 1949 | | |
1940 | | - | |
| 1950 | + | |
1941 | 1951 | | |
1942 | 1952 | | |
1943 | 1953 | | |
| |||
0 commit comments