]> git.ipfire.org Git - thirdparty/linux.git/commit
mm, swap: remove setting SWAP_MAP_BAD for discard cluster
authorKemeng Shi <shikemeng@huaweicloud.com>
Sat, 22 Feb 2025 16:08:48 +0000 (00:08 +0800)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 17 Mar 2025 05:06:40 +0000 (22:06 -0700)
commit43e9bbc3bb19893377364379e224c35db0256b88
tree420bd557f7c06e3c1fdb609cb976f38eee7f5b4e
parent1ddae9d67ee11886f9a35b78ad837eb26559e9ab
mm, swap: remove setting SWAP_MAP_BAD for discard cluster

Before alloc from a cluster, we will aqcuire cluster's lock and make sure
it is usable by cluster_is_usable(), so there is no need to set
SWAP_MAP_BAD for cluster to be discarded.

Link: https://lkml.kernel.org/r/20250222160850.505274-5-shikemeng@huaweicloud.com
Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com>
Reviewed-by: Kairui Song <kasong@tencent.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/swapfile.c