remove_one() was not incrementing the key for the beginning of the range, so not all entries were being removed. This resulted in discards that were not unmapping all blocks.
Unified · Split
| @@ -689,6 +689,7 @@ static int remove_one(struct dm_btree_info *info, dm_block_t root, · 688 unmodified lines | ||
| 689 | 689 | value_ptr(n, index)); |
| 690 | 690 | |
| 691 | 691 | delete_at(n, index); |
| 692 | + keys[last_level] = k + 1ull; | |
| 692 | 693 | |
| 693 | 694 | } else |
| 694 | 695 | r = -ENODATA; |