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: <e4be89df-2bf9-76a2-497f-c6ba3256c95a@redhat.com>
Date:   Mon, 29 Oct 2018 17:14:46 +0800
From:   Jason Wang <jasowang@...hat.com>
To:     Simon Guo <wei.guo.simon@...ux.alibaba.com>,
        Alex Williamson <alex.williamson@...hat.com>,
        Eric Auger <eric.auger@...hat.com>
Cc:     qixuan.wu@...ux.alibaba.com, linux-kernel@...r.kernel.org,
        kvm@...r.kernel.org, Peter Xu <peterx@...hat.com>
Subject: Re: Can VFIO pin only a specific region of guest mem when use pass
 through devices?


On 2018/10/29 上午10:42, Simon Guo wrote:
> Hi,
>
> I am using network device pass through mode with qemu x86(-device vfio-pci,host=0000:xx:yy.z)
> and “intel_iommu=on” in host kernel command line, and it shows the whole guest memory
> were pinned(vfio_pin_pages()), viewed by the “top” RES memory output. I understand it is due
> to device can DMA to any guest memory address and it cannot be swapped.
>
> However can we just pin a rang of address space allowed by iommu group of that device,
> instead of pin whole address space? I do notice some code like vtd_host_dma_iommu().
> Maybe there is already some way to enable that?
>
> Sorry if I missed some basics. I googled some but no luck to find the answer yet. Please
> let me know if any discussion already raised on that.
>
> Any other suggestion will also be appreciated. For example, can we modify the guest network
> card driver to allocate only from a specific memory region(zone), and qemu advises guest
> kernel to only pin that memory region(zone) accordingly?
>
> Thanks,
> - Simon


One possible method is to enable IOMMU of VM.

Peter (cced) may know more.

Thanks

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ