From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jason Gunthorpe Subject: Re: [PATCH 3/5] vDPA: introduce vDPA bus Date: Tue, 21 Jan 2020 14:05:04 +0000 Message-ID: <20200121140456.GA12330@mellanox.com> References: <20200117070324-mutt-send-email-mst@kernel.org> <239b042c-2d9e-0eec-a1ef-b03b7e2c5419@redhat.com> <20200120174933.GB3891@mellanox.com> <2a324cec-2863-58f4-c58a-2414ee32c930@redhat.com> <20200121004047-mutt-send-email-mst@kernel.org> <20200121031506-mutt-send-email-mst@kernel.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <20200121031506-mutt-send-email-mst@kernel.org> Content-Language: en-US Content-ID: Sender: linux-kernel-owner@vger.kernel.org To: "Michael S. Tsirkin" Cc: Jason Wang , Shahaf Shuler , Rob Miller , "linux-kernel@vger.kernel.org" , "kvm@vger.kernel.org" , "virtualization@lists.linux-foundation.org" , Netdev , "Bie, Tiwei" , "maxime.coquelin@redhat.com" , "Liang, Cunming" , "Wang, Zhihong" , "Wang, Xiao W" , "haotian.wang@sifive.com" , "Zhu, Lingshan" , "eperezma@redhat.com" , "lulu@redhat.com" , Parav Pandit List-Id: virtualization@lists.linuxfoundation.org On Tue, Jan 21, 2020 at 03:15:43AM -0500, Michael S. Tsirkin wrote: > > This sounds more flexible e.g driver may choose to implement static map= ping > > one through commit. But a question here, it looks to me this still requ= ires > > the DMA to be synced with at least commit here. Otherwise device may ge= t DMA > > fault? Or device is expected to be paused DMA during begin? > >=20 > > Thanks >=20 > For example, commit might switch one set of tables for another, > without need to pause DMA. I'm not aware of any hardware that can do something like this completely atomically.. Any mapping change API has to be based around add/remove regions without any active DMA (ie active DMA is a guest error the guest can be crashed if it does this) Jason