From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 06188152A for ; Tue, 10 Jan 2017 14:59:29 +0100 (CET) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga101.fm.intel.com with ESMTP; 10 Jan 2017 05:59:28 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,344,1477983600"; d="scan'208";a="52175922" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.38]) ([10.237.220.38]) by fmsmga006.fm.intel.com with ESMTP; 10 Jan 2017 05:59:27 -0800 To: Stephen Hemminger , dev@dpdk.org References: <20170107181756.1944-1-sthemmin@microsoft.com> <20170107181756.1944-8-sthemmin@microsoft.com> Cc: Stephen Hemminger , Shreyansh Jain From: Ferruh Yigit Message-ID: <416d1526-f9d9-fa03-b04d-f63284a2df5d@intel.com> Date: Tue, 10 Jan 2017 13:59:27 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <20170107181756.1944-8-sthemmin@microsoft.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 7/8] ethdev: break ethernet driver and pci_driver connection X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Jan 2017 13:59:30 -0000 On 1/7/2017 6:17 PM, Stephen Hemminger wrote: > There are multiple buses and device types now. Therefore it no longer > makes sense that PCI driver information is part of the Ethernet driver > structure. > > This patch removes pci_driver from eth_driver and introduces a > new combined structure for use in all existing PMD's. The rationale > is that although all existing PCI drivers are Ethernet drivers, > it make sense that future projects may want to support PCI devices > that are not Ethernet. > > It also removes the requirement that driver is first element in > PCI driver structure. > > Signed-off-by: Stephen Hemminger > --- <...> > /** > + * @internal > + * The structure associated with a PMD PCI Ethernet driver. > + */ > +struct rte_pci_eth_driver { > + struct rte_pci_driver pci_drv; /**< Underlying PCI driver. */ > + struct eth_driver eth_drv; /**< Ethernet driver. */ > +}; So do we need to add rte_vdev_eth_driver struct for virtual drivers, or need to add rte_pci_cryptodev_driver struct for pci crypto devices? Can this be done in a more generic way? After Shreyansh's patches, there will be rte_device, rte_driver abstractions, can they be useful? <...>