[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87d08qhd1u.fsf@yhuang-dev.intel.com>
Date: Thu, 02 Apr 2020 09:49:33 +0800
From: "Huang\, Ying" <ying.huang@...el.com>
To: Zi Yan <ziy@...dia.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>, <linux-mm@...ck.org>,
<linux-kernel@...r.kernel.org>,
Andrea Arcangeli <aarcange@...hat.com>,
"Kirill A . Shutemov" <kirill.shutemov@...ux.intel.com>,
Vlastimil Babka <vbabka@...e.cz>,
Alexey Dobriyan <adobriyan@...il.com>,
Michal Hocko <mhocko@...e.com>,
Konstantin Khlebnikov <khlebnikov@...dex-team.ru>,
Jérôme Glisse <jglisse@...hat.com>,
Yang Shi <yang.shi@...ux.alibaba.com>
Subject: Re: [PATCH] /proc/PID/smaps: Add PMD migration entry parsing
Zi Yan <ziy@...dia.com> writes:
> On 31 Mar 2020, at 4:56, Huang, Ying wrote:
>>
>> From: Huang Ying <ying.huang@...el.com>
>> - /* FOLL_DUMP will return -EFAULT on huge zero page */
>> - page = follow_trans_huge_pmd(vma, addr, pmd, FOLL_DUMP);
>> + if (pmd_present(*pmd)) {
>> + /* FOLL_DUMP will return -EFAULT on huge zero page */
>> + page = follow_trans_huge_pmd(vma, addr, pmd, FOLL_DUMP);
>> + } else if (unlikely(is_swap_pmd(*pmd))) {
>
> Should be:
> } else if (unlikely(thp_migration_support() && is_swap_pmd(*pmd))) {
Thought this again. This can reduce the code size if
thp_migration_support() isn't enabled. I will do this in the next
version.
Best Regards,
Huang, Ying
Powered by blists - more mailing lists