From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id 982AF91B5 for ; Tue, 20 Oct 2015 10:57:27 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga103.jf.intel.com with ESMTP; 20 Oct 2015 01:57:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.17,706,1437462000"; d="scan'208";a="815058078" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by fmsmga001.fm.intel.com with ESMTP; 20 Oct 2015 01:57:26 -0700 Received: from fmsmsx102.amr.corp.intel.com (10.18.124.200) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.248.2; Tue, 20 Oct 2015 01:57:25 -0700 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by FMSMSX102.amr.corp.intel.com (10.18.124.200) with Microsoft SMTP Server (TLS) id 14.3.248.2; Tue, 20 Oct 2015 01:57:25 -0700 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.96]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.106]) with mapi id 14.03.0248.002; Tue, 20 Oct 2015 16:57:23 +0800 From: "Qiu, Michael" To: "Iremonger, Bernard" , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v3 02/20] librte_ether: add fields from rte_pci_driver to rte_eth_dev_data Thread-Index: AQHRBQq/JnZfMGu1sk2SrOtL3+5lwA== Date: Tue, 20 Oct 2015 08:57:23 +0000 Message-ID: <533710CFB86FA344BFBF2D6802E6028621B4E0C5@SHSMSX101.ccr.corp.intel.com> References: <1444667120-12891-1-git-send-email-bernard.iremonger@intel.com> <1444667120-12891-3-git-send-email-bernard.iremonger@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v3 02/20] librte_ether: add fields from rte_pci_driver to rte_eth_dev_data 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, 20 Oct 2015 08:57:28 -0000 On 2015/10/13 0:26, Bernard Iremonger wrote:=0A= > add dev_flags to rte_eth_dev_data, add macros for dev_flags.=0A= > add kdrv to rte_eth_dev_data.=0A= > add numa_node to rte_eth_dev_data.=0A= > add drv_name to rte_eth_dev_data.=0A= > use dev_type to distinguish between vdev's and pdev's.=0A= > remove pci_dev branches.=0A= >=0A= > Signed-off-by: Bernard Iremonger =0A= > ---=0A= =0A= [../..]=0A= =0A= > /* attach the new physical device, then store port_id of the device */= =0A= > @@ -1143,14 +1141,11 @@ rte_eth_dev_configure(uint8_t port_id, uint16_t n= b_rx_q, uint16_t nb_tx_q,=0A= > * If link state interrupt is enabled, check that the=0A= > * device supports it.=0A= > */=0A= > - if (dev_conf->intr_conf.lsc =3D=3D 1) {=0A= > - const struct rte_pci_driver *pci_drv =3D &dev->driver->pci_drv;=0A= > -=0A= > - if (!(pci_drv->drv_flags & RTE_PCI_DRV_INTR_LSC)) {=0A= > + if ((dev_conf->intr_conf.lsc =3D=3D 1) &&=0A= > + (!(dev->data->dev_flags & RTE_ETH_DEV_INTR_LSC))) {=0A= > PMD_DEBUG_TRACE("driver %s does not support lsc\n",=0A= > - pci_drv->name);=0A= > + dev->data->drv_name);=0A= > return -EINVAL;=0A= > - }=0A= > }=0A= > =0A= > /*=0A= > @@ -1795,8 +1790,7 @@ rte_eth_dev_info_get(uint8_t port_id, struct rte_et= h_dev_info *dev_info)=0A= > FUNC_PTR_OR_RET(*dev->dev_ops->dev_infos_get);=0A= > (*dev->dev_ops->dev_infos_get)(dev, dev_info);=0A= > dev_info->pci_dev =3D dev->pci_dev;=0A= =0A= Here also pci_dev, I think after you remove pci_dev from vdevs, and this=0A= field could be remove I think, as I don't see any use of this field in=0A= dev_info, it should be more general and not only PCI.=0A= =0A= Thanks,=0A= Michael=0A= =0A= > - if (dev->driver)=0A= > - dev_info->driver_name =3D dev->driver->pci_drv.name;=0A= > + dev_info->driver_name =3D dev->data->drv_name;=0A= > }=0A= > =0A= >=0A= =0A=