[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200402082142.GL22681@dhcp22.suse.cz>
Date: Thu, 2 Apr 2020 10:21:42 +0200
From: Michal Hocko <mhocko@...nel.org>
To: "Huang, Ying" <ying.huang@...el.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>, linux-mm@...ck.org,
linux-kernel@...r.kernel.org, Zi Yan <ziy@...dia.com>,
Andrea Arcangeli <aarcange@...hat.com>,
"Kirill A . Shutemov" <kirill.shutemov@...ux.intel.com>,
Vlastimil Babka <vbabka@...e.cz>,
Alexey Dobriyan <adobriyan@...il.com>,
Konstantin Khlebnikov <khlebnikov@...dex-team.ru>,
Jérôme Glisse <jglisse@...hat.com>,
Yang Shi <yang.shi@...ux.alibaba.com>
Subject: Re: [PATCH -V2] /proc/PID/smaps: Add PMD migration entry parsing
On Thu 02-04-20 16:10:29, Huang, Ying wrote:
> Michal Hocko <mhocko@...nel.org> writes:
>
> > On Thu 02-04-20 15:03:23, Huang, Ying wrote:
[...]
> >> > Could you explain why do we need this WARN_ON? I haven't really checked
> >> > the swap support for THP but cannot we have normal swap pmd entries?
> >>
> >> I have some patches to add the swap pmd entry support, but they haven't
> >> been merged yet.
> >>
> >> Similar checks are for all THP migration code paths, so I follow the
> >> same style.
> >
> > I haven't checked other migration code paths but what is the reason to
> > add the warning here? Even if this shouldn't happen, smaps is perfectly
> > fine to ignore that situation, no?
>
> Yes. smaps itself is perfectly fine to ignore it. I think this is used
> to find bugs in other code paths such as THP migration related.
Please do not add new warnings without a good an strong reasons. As a
matter of fact there are people running with panic_on_warn and each
warning is fatal for them. Please also note that this is a user trigable
path and that requires even more care.
--
Michal Hocko
SUSE Labs
Powered by blists - more mailing lists