[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b9fc8a52-74b5-2f78-fbf6-8b473c6a8a36@amd.com>
Date: Tue, 27 Sep 2022 16:16:42 +0530
From: Bharata B Rao <bharata@....com>
To: "Huang, Ying" <ying.huang@...el.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
Andrew Morton <akpm@...ux-foundation.org>,
Zi Yan <ziy@...dia.com>, Yang Shi <shy828301@...il.com>,
Baolin Wang <baolin.wang@...ux.alibaba.com>,
Oscar Salvador <osalvador@...e.de>,
Matthew Wilcox <willy@...radead.org>
Subject: Re: [RFC 0/6] migrate_pages(): batch TLB flushing
On 9/23/2022 1:22 PM, Huang, Ying wrote:
> Bharata B Rao <bharata@....com> writes:
>>
>> Thanks for the patchset. I find it hitting the following BUG() when
>> running mmtests/autonumabench:
>>
>> kernel BUG at mm/migrate.c:2432!
>>
>> This is BUG_ON(!list_empty(&migratepages)) in migrate_misplaced_page().
>
> Thank you very much for reporting! I haven't reproduced this yet. But
> I will pay special attention to this when develop the next version, even
> if I cannot reproduce this finally.
The following change fixes the above reported BUG_ON().
diff --git a/mm/migrate.c b/mm/migrate.c
index a0de0d9b4d41..c11dd82245e5 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -1197,7 +1197,7 @@ static int migrate_page_unmap(new_page_t get_new_page, free_page_t put_new_page,
* references and be restored.
*/
/* restore the page to right list. */
- if (rc != -EAGAIN)
+ if (rc == -EAGAIN)
ret = NULL;
migrate_page_undo_page(page, page_was_mapped, anon_vma, locked, ret);
The pages that returned from unmapping stage with -EAGAIN used to
end up on "ret" list rather than continuing on the "from" list.
Regards,
Bharata.
Powered by blists - more mailing lists