From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from wes1-so2.wedos.net (wes1-so2.wedos.net [46.28.106.16]) by dpdk.org (Postfix) with ESMTP id A1B589AB2 for ; Tue, 10 May 2016 14:58:22 +0200 (CEST) Received: from jvn (dynamic-109-81-211-184.ipv4.broadband.iol.cz [109.81.211.184]) by wes1-so2.wedos.net (Postfix) with ESMTPSA id 3r3znp1vS3z8VW; Tue, 10 May 2016 14:58:22 +0200 (CEST) Date: Tue, 10 May 2016 14:58:26 +0200 From: Jan Viktorin To: "Burakov, Anatoly" Cc: "dev@dpdk.org" , David Marchand , "Wiles, Keith" , Santosh Shukla , "Stephen Hemminger" Message-ID: <20160510145826.637af9a5@jvn> In-Reply-To: References: <1461937456-22943-1-git-send-email-viktorin@rehivetech.com> <1461937456-22943-11-git-send-email-viktorin@rehivetech.com> Organization: RehiveTech X-Mailer: Claws Mail 3.13.0 (GTK+ 2.24.28; x86_64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 10/15] vfio: extract setup logic out of pci_vfio_map_resource X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 May 2016 12:58:22 -0000 On Tue, 10 May 2016 11:53:21 +0000 "Burakov, Anatoly" wrote: > Hi Jan, > > > > /* > > - * at this point, we know at least one port on this device is bound to > > VFIO, > > - * so we can proceed to try and set this particular port up > > - */ > > - > > - /* check if the group is viable */ > > - ret = ioctl(vfio_group_fd, VFIO_GROUP_GET_STATUS, > > &group_status); > > - if (ret) { > > - RTE_LOG(ERR, EAL, " %s cannot get group status, " > > - "error %i (%s)\n", pci_addr, errno, > > strerror(errno)); > > - close(vfio_group_fd); > > - clear_current_group(); > > - return -1; > > - } else if (!(group_status.flags & VFIO_GROUP_FLAGS_VIABLE)) { > > - RTE_LOG(ERR, EAL, " %s VFIO group is not viable!\n", > > pci_addr); > > - close(vfio_group_fd); > > - clear_current_group(); > > - return -1; > > - } > > - > > I think you've lost this bit when moving things around. I can't find any viability checks in eal_vfio.c Thanks for this catch, I'll check. I've rebased the patch set once because there were some changes to the original VFIO code. Hope for no more such rebasing. Regards Jan > > Thanks, > Anatoly -- Jan Viktorin E-mail: Viktorin@RehiveTech.com System Architect Web: www.RehiveTech.com RehiveTech Brno, Czech Republic