linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mm: mempolicy: use VM_BUG_ON_VMA in queue_pages_test_walk()
@ 2020-01-15  6:09 Yang Shi
  2020-01-15 12:08 ` Li Xinhai
  2020-01-27 18:17 ` Qian Cai
  0 siblings, 2 replies; 10+ messages in thread
From: Yang Shi @ 2020-01-15  6:09 UTC (permalink / raw)
  To: akpm; +Cc: yang.shi, linux-mm, linux-kernel

The VM_BUG_ON() is already used by queue_pages_test_walk(), it sounds
better to dump more debug information by using VM_BUG_ON_VMA() to help
debugging.

Signed-off-by: Yang Shi <yang.shi@linux.alibaba.com>
---
 mm/mempolicy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/mempolicy.c b/mm/mempolicy.c
index 067cf7d..801d45d 100644
--- a/mm/mempolicy.c
+++ b/mm/mempolicy.c
@@ -621,7 +621,7 @@ static int queue_pages_test_walk(unsigned long start, unsigned long end,
 	unsigned long flags = qp->flags;
 
 	/* range check first */
-	VM_BUG_ON((vma->vm_start > start) || (vma->vm_end < end));
+	VM_BUG_ON_VMA((vma->vm_start > start) || (vma->vm_end < end), vma);
 
 	if (!qp->first) {
 		qp->first = vma;
-- 
1.8.3.1



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2020-02-14 12:24 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-15  6:09 [PATCH] mm: mempolicy: use VM_BUG_ON_VMA in queue_pages_test_walk() Yang Shi
2020-01-15 12:08 ` Li Xinhai
2020-01-15 17:27   ` Yang Shi
2020-01-16 15:52     ` Li Xinhai
2020-01-27 16:59       ` Yang Shi
2020-01-27 18:17 ` Qian Cai
2020-01-27 19:57   ` Yang Shi
2020-01-27 20:23     ` Qian Cai
2020-02-14  5:26       ` Andrew Morton
2020-02-14 12:24         ` Qian Cai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).