lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1d4dc5f732e8da263c2a2e783e4550419cfb0c7b.camel@surriel.com>
Date:   Sun, 27 Mar 2022 22:24:08 -0400
From:   Rik van Riel <riel@...riel.com>
To:     Miaohe Lin <linmiaohe@...wei.com>
Cc:     linux-mm@...ck.org, kernel-team@...com,
        Oscar Salvador <osalvador@...e.de>,
        Naoya Horiguchi <naoya.horiguchi@....com>,
        Mel Gorman <mgorman@...e.de>,
        Johannes Weiner <hannes@...xchg.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        stable@...r.kernel.org, linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] mm,hwpoison: unmap poisoned page before invalidation

On Mon, 2022-03-28 at 10:14 +0800, Miaohe Lin wrote:
> On 2022/3/27 4:14, Rik van Riel wrote:
> 
> 
> > 
> > > >                         /* Retry if a clean page was removed
> > > > from
> > > > the cache. */
> > > > -                       if (invalidate_inode_page(vmf->page))
> > > > -                               poisonret = 0;
> > > > -                       unlock_page(vmf->page);
> > > > +                       if (invalidate_inode_page(page))
> > > > +                               poisonret = VM_FAULT_NOPAGE;
> > > > +                       unlock_page(page);
> > 
> 
> Sure, but when I think more about this, it seems this fix isn't
> ideal:
> If VM_FAULT_NOPAGE is returned with page table unset, the process
> will
> re-trigger page fault again and again until invalidate_inode_page
> succeeds
> to evict the inode page. This might hang the process a really long
> time.
> Or am I miss something?
> 
If invalidate_inode_page fails, we will return
VM_FAULT_HWPOISON, and kill the task, instead
of looping indefinitely.

-- 
All Rights Reversed.

Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ