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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210309124609.GG2356281@nvidia.com>
Date:   Tue, 9 Mar 2021 08:46:09 -0400
From:   Jason Gunthorpe <jgg@...dia.com>
To:     "Zengtao (B)" <prime.zeng@...ilicon.com>
Cc:     Peter Xu <peterx@...hat.com>,
        Alex Williamson <alex.williamson@...hat.com>,
        Cornelia Huck <cohuck@...hat.com>,
        Kevin Tian <kevin.tian@...el.com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Giovanni Cabiddu <giovanni.cabiddu@...el.com>,
        Michel Lespinasse <walken@...gle.com>,
        Jann Horn <jannh@...gle.com>,
        Max Gurtovoy <mgurtovoy@...dia.com>,
        "kvm@...r.kernel.org" <kvm@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Linuxarm <linuxarm@...wei.com>
Subject: Re: 答复: [PATCH] vfio/pci: make the
 vfio_pci_mmap_fault reentrant

On Tue, Mar 09, 2021 at 03:49:09AM +0000, Zengtao (B) wrote:
> Hi guys:
> 
> Thanks for the helpful comments, after rethinking the issue, I have proposed
>  the following change: 
> 1. follow_pte instead of follow_pfn.

Still no on follow_pfn, you don't need it once you use vmf_insert_pfn

> 2. vmf_insert_pfn loops instead of io_remap_pfn_range
> 3. proper undos when some call fails.
> 4. keep the bigger lock range to avoid unessary pte install. 

Why do we need locks at all here?

Jason

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ