From: Waiman Long <email@example.com> To: Michal Hocko <firstname.lastname@example.org> Cc: Mike Kravetz <email@example.com>, Andrew Morton <firstname.lastname@example.org>, Matthew Wilcox <email@example.com>, firstname.lastname@example.org, email@example.com, firstname.lastname@example.org, Jarod Wilson <email@example.com> Subject: Re: [PATCH v2] mm/hugetlb: defer free_huge_page() to a workqueue Date: Mon, 16 Dec 2019 13:44:53 -0500 [thread overview] Message-ID: <firstname.lastname@example.org> (raw) In-Reply-To: <email@example.com> On 12/16/19 10:38 AM, Waiman Long wrote: > On 12/16/19 8:26 AM, Michal Hocko wrote: >> On Thu 12-12-19 15:52:20, Waiman Long wrote: >>> On 12/12/19 2:22 PM, Mike Kravetz wrote: >>>> On 12/12/19 11:04 AM, Davidlohr Bueso wrote: >>>>> There have been deadlock reports[1, 2] where put_page is called >>>>> from softirq context and this causes trouble with the hugetlb_lock, >>>>> as well as potentially the subpool lock. >>>>> >>>>> For such an unlikely scenario, lets not add irq dancing overhead >>>>> to the lock+unlock operations, which could incur in expensive >>>>> instruction dependencies, particularly when considering hard-irq >>>>> safety. For example PUSHF+POPF on x86. >>>>> >>>>> Instead, just use a workqueue and do the free_huge_page() in regular >>>>> task context. >>>>> >>>>>  https://firstname.lastname@example.org/ >>>>>  https://email@example.com/ >>>>> >>>>> Reported-by: Waiman Long <firstname.lastname@example.org> >>>>> Reported-by: Aneesh Kumar K.V <email@example.com> >>>>> Signed-off-by: Davidlohr Bueso <firstname.lastname@example.org> >>>> Thank you Davidlohr. >>>> >>>> The patch does seem fairly simple and straight forward. I need to brush up >>>> on my workqueue knowledge to provide a full review. >>>> >>>> Longman, >>>> Do you have a test to reproduce the issue? If so, can you try running with >>>> this patch. >>> Yes, I do have a test that can reproduce the issue. I will run it with >>> the patch and report the status tomorrow. >> Can you extract guts of the testcase and integrate them into hugetlb >> test suite? BTW, what hugetlb test suite are you talking about? Cheers, Longman
next prev parent reply other threads:[~2019-12-16 18:45 UTC|newest] Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-12-11 19:46 [PATCH v2] hugetlbfs: Disable softIRQ when taking hugetlb_lock Waiman Long 2019-12-11 22:04 ` Mike Kravetz 2019-12-11 22:19 ` Waiman Long 2019-12-12 1:11 ` Mike Kravetz 2019-12-12 6:06 ` Davidlohr Bueso 2019-12-12 6:30 ` Davidlohr Bueso 2019-12-12 19:04 ` [PATCH v2] mm/hugetlb: defer free_huge_page() to a workqueue Davidlohr Bueso 2019-12-12 19:22 ` Mike Kravetz 2019-12-12 19:36 ` Davidlohr Bueso 2019-12-12 20:52 ` Waiman Long 2019-12-12 21:04 ` Waiman Long 2019-12-16 13:26 ` Michal Hocko 2019-12-16 15:38 ` Waiman Long 2019-12-16 18:44 ` Waiman Long [this message] 2019-12-17 9:00 ` Michal Hocko 2019-12-17 18:05 ` Mike Kravetz 2019-12-18 12:18 ` hugetlbfs testing coverage (was: Re: [PATCH v2] mm/hugetlb: defer free_huge_page() to a workqueue) Michal Hocko 2019-12-12 21:01 ` [PATCH v2] mm/hugetlb: defer free_huge_page() to a workqueue Waiman Long 2019-12-16 13:37 ` Michal Hocko 2019-12-16 16:17 ` Waiman Long 2019-12-16 16:17 ` Davidlohr Bueso 2019-12-16 17:18 ` Matthew Wilcox 2019-12-16 19:08 ` Mike Kravetz 2019-12-16 19:13 ` Waiman Long 2019-12-12 21:32 ` [PATCH v2] hugetlbfs: Disable softIRQ when taking hugetlb_lock Andi Kleen 2019-12-12 22:42 ` Davidlohr Bueso 2019-12-11 23:05 ` Andi Kleen
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --firstname.lastname@example.org \ --subject='Re: [PATCH v2] mm/hugetlb: defer free_huge_page() to a workqueue' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
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).