On 3/28/20 3:10 PM, akpm@xxxxxxxxxxxxxxxxxxxx wrote: > The patch titled > Subject: mm/hugetlb: fix a addressing exception caused by huge_pte_offset > has been added to the -mm tree. Its filename is > mm-hugetlb-fix-a-addressing-exception-caused-by-huge_pte_offset.patch > > This patch should soon appear at > http://ozlabs.org/~akpm/mmots/broken-out/mm-hugetlb-fix-a-addressing-exception-caused-by-huge_pte_offset.patch > and later at > http://ozlabs.org/~akpm/mmotm/broken-out/mm-hugetlb-fix-a-addressing-exception-caused-by-huge_pte_offset.patch > > Before you just go and hit "reply", please: > a) Consider who else should be cc'ed > b) Prefer to cc a suitable mailing list as well > c) Ideally: find the original patch on the mailing list and do a > reply-to-all to that, adding suitable additional cc's > > *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** > > The -mm tree is included into linux-next and is updated > there every 3-4 working days > > ------------------------------------------------------ > From: Longpeng <longpeng2@xxxxxxxxxx> > Subject: mm/hugetlb: fix a addressing exception caused by huge_pte_offset This patch is what caused the BUG reported on i386 non-PAE kernel here: https://lore.kernel.org/linux-mm/CA+G9fYsJgZhhWLMzUxu_ZQ+THdCcJmFbHQ2ETA_YPP8M6yxOYA@xxxxxxxxxxxxxx/ As a clue, when building in this environment I get: CC mm/hugetlb.o mm/hugetlb.c: In function ‘huge_pte_offset’: cc1: warning: function may return address of local variable [-Wreturn-local-addr] mm/hugetlb.c:5361:14: note: declared here pud_t *pud, pud_entry; ^~~~~~~~~ cc1: warning: function may return address of local variable [-Wreturn-local-addr] mm/hugetlb.c:5361:14: note: declared here cc1: warning: function may return address of local variable [-Wreturn-local-addr] mm/hugetlb.c:5360:14: note: declared here p4d_t *p4d, p4d_entry; ^~~~~~~~~ I'm shutting down for the night and will look into it more tomorrow if someone else does not beat me to it. -- Mike Kravetz