[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200901014636.29737-3-richard.weiyang@linux.alibaba.com>
Date: Tue, 1 Sep 2020 09:46:31 +0800
From: Wei Yang <richard.weiyang@...ux.alibaba.com>
To: mike.kravetz@...cle.com, akpm@...ux-foundation.org
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org, bhe@...hat.com,
Wei Yang <richard.weiyang@...ux.alibaba.com>
Subject: [Patch v4 2/7] mm/hugetlb: remove VM_BUG_ON(!nrg) in get_file_region_entry_from_cache()
We are sure to get a valid file_region, otherwise the
VM_BUG_ON(resv->region_cache_count <= 0) at the very beginning would be
triggered.
Let's remove the redundant one.
Signed-off-by: Wei Yang <richard.weiyang@...ux.alibaba.com>
Reviewed-by: Mike Kravetz <mike.kravetz@...cle.com>
---
mm/hugetlb.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/mm/hugetlb.c b/mm/hugetlb.c
index db6af2654f12..fbaf49bc1d26 100644
--- a/mm/hugetlb.c
+++ b/mm/hugetlb.c
@@ -240,7 +240,6 @@ get_file_region_entry_from_cache(struct resv_map *resv, long from, long to)
resv->region_cache_count--;
nrg = list_first_entry(&resv->region_cache, struct file_region, link);
- VM_BUG_ON(!nrg);
list_del(&nrg->link);
nrg->from = from;
--
2.20.1 (Apple Git-117)
Powered by blists - more mailing lists