On Mon, Oct 07, 2019 at 04:17:36PM -0400, Dennis Zhou wrote:
> When discard is enabled, everytime a pinned extent is released back to
> the block_group's free space cache, a discard is issued for the extent.
> This is an overeager approach when it comes to discarding and helping
> the SSD maintain enough free space to prevent severe garbage collection
> situations.
> 
> This adds the beginning of async discard. Instead of issuing a discard
> prior to returning it to the free space, it is just marked as untrimmed.
> The block_group is then added to a LRU which then feeds into a workqueue
> to issue discards at a much slower rate. Full discarding of unused block
> groups is still done and will be address in a future patch in this
> series.
> 
> For now, we don't persist the discard state of extents and bitmaps.
> Therefore, our failure recovery mode will be to consider extents
> untrimmed. This lets us handle failure and unmounting as one in the
> same.
> 
> Signed-off-by: Dennis Zhou <[email protected]>

Reviewed-by: Josef Bacik <[email protected]>

Thanks,

Josef

Reply via email to