[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2560aab2-426c-6e58-cb4f-77ec76e0c941@amd.com>
Date: Wed, 30 Nov 2016 12:28:24 -0500
From: Serguei Sagalovitch <serguei.sagalovitch@....com>
To: Jason Gunthorpe <jgunthorpe@...idianresearch.com>,
Haggai Eran <haggaie@...lanox.com>
CC: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-rdma@...r.kernel.org" <linux-rdma@...r.kernel.org>,
"linux-nvdimm@...1.01.org" <linux-nvdimm@...1.01.org>,
"christian.koenig@....com" <christian.koenig@....com>,
"Suravee.Suthikulpanit@....com" <Suravee.Suthikulpanit@....com>,
"John.Bridgman@....com" <John.Bridgman@....com>,
"Alexander.Deucher@....com" <Alexander.Deucher@....com>,
"Linux-media@...r.kernel.org" <Linux-media@...r.kernel.org>,
"dan.j.williams@...el.com" <dan.j.williams@...el.com>,
"logang@...tatee.com" <logang@...tatee.com>,
"dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
Max Gurtovoy <maxg@...lanox.com>,
"linux-pci@...r.kernel.org" <linux-pci@...r.kernel.org>,
"Paul.Blinzer@....com" <Paul.Blinzer@....com>,
"Felix.Kuehling@....com" <Felix.Kuehling@....com>,
"ben.sander@....com" <ben.sander@....com>
Subject: Re: Enabling peer to peer device transactions for PCIe devices
On 2016-11-30 11:23 AM, Jason Gunthorpe wrote:
>> Yes, that sounds fine. Can we simply kill the process from the GPU driver?
>> Or do we need to extend the OOM killer to manage GPU pages?
> I don't know..
We could use send_sig_info to send signal from kernel to user space.
So theoretically GPU driver
could issue KILL signal to some process.
> On Wed, Nov 30, 2016 at 12:45:58PM +0200, Haggai Eran wrote:
>> I think we can achieve the kernel's needs with ZONE_DEVICE and DMA-API support
>> for peer to peer. I'm not sure we need vmap. We need a way to have a scatterlist
>> of MMIO pfns, and ZONE_DEVICE allows that.
I do not think that using DMA-API as it is is the best solution (at
least in the current form):
- It deals with handles/fd for the whole allocation but client
could/will use sub-allocation as
well as theoretically possible to "merge" several allocations in one
from GPU perspective.
- It require knowledge to export but because "sharing" is controlled
from user space it
means that we must "export" all allocation by default
- It deals with 'fd'/handles but user application may work with
addresses/pointers.
Also current DMA-API force each time to do all DMA table programming
unrelated if
location was changed or not. With vma / mmu we are able to install
notifier to intercept
changes in location and update translation tables only as needed (we do
not need to keep
get_user_pages() lock).
Powered by blists - more mailing lists