From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: Re: [RFC PATCH v3 08/18] xen/arm: vITS: Add virtual ITS driver Date: Thu, 2 Jul 2015 15:30:23 +0100 Message-ID: <1435847423.21469.344.camel@citrix.com> References: <1434974517-12136-1-git-send-email-vijay.kilari@gmail.com> <1434974517-12136-9-git-send-email-vijay.kilari@gmail.com> <55898BA5.7040801@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Vijay Kilari Cc: Stefano Stabellini , Prasun Kapoor , Vijaya Kumar K , Tim Deegan , "xen-devel@lists.xen.org" , Julien Grall , Stefano Stabellini , manish.jaggi@caviumnetworks.com List-Id: xen-devel@lists.xenproject.org On Thu, 2015-07-02 at 19:03 +0530, Vijay Kilari wrote: > Hi Julien, > > On Tue, Jun 23, 2015 at 10:09 PM, Julien Grall wrote: > > Hi Vijay, > > > >> > >> +struct vits_device { > >> + uint32_t vdevid; > >> + uint32_t pdevid; > >> + struct its_device *its_dev; > >> + struct rb_node node; > >> +}; > > > > We spoke about a specific structure in the design [2] but you introduced > > a new one. Why? > > Section 6 of DraftG specifies to manage separate tree for device assignment. > This helps to manage RB-tree per domain to hold list of devices > assigned to this domain index with vdevid. > > This helps to check if device is assigned to this domain before processing > any ITS command with that vdevid. > > > > > Having everything in the its_device would help to catch a device > > attached to 2 different domains... > > One option is to introduce a new variable inside its_device to know > to which domain the device is currently assigned. IIRC that's what I intended, e.g. two trees referencing the same underlying data structure. Sorry that wasn't clear. > > > > > Also, the field pdevid is not vits specific but its. > pdevid can be removed as its_device structure already has it > > Regards > Vijay