From patchwork Mon Dec 15 02:55:49 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Fu, Weiyi (NSN - CN/Hangzhou)" X-Patchwork-Id: 1991 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 304016A94; Mon, 15 Dec 2014 03:56:51 +0100 (CET) Received: from demumfd001.nsn-inter.net (demumfd001.nsn-inter.net [93.183.12.32]) by dpdk.org (Postfix) with ESMTP id B062D959 for ; Mon, 15 Dec 2014 03:56:48 +0100 (CET) Received: from demuprx017.emea.nsn-intra.net ([10.150.129.56]) by demumfd001.nsn-inter.net (8.14.3/8.14.3) with ESMTP id sBF2ul1Q024003 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 15 Dec 2014 02:56:47 GMT Received: from SGSIHTC002.nsn-intra.net ([10.159.225.19]) by demuprx017.emea.nsn-intra.net (8.12.11.20060308/8.12.11) with ESMTP id sBF2uYcd001009 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=FAIL); Mon, 15 Dec 2014 03:56:42 +0100 Received: from SGSIHTC007.nsn-intra.net (10.159.225.24) by SGSIHTC002.nsn-intra.net (10.159.225.19) with Microsoft SMTP Server (TLS) id 14.3.195.1; Mon, 15 Dec 2014 10:55:51 +0800 Received: from SGSIMBX001.nsn-intra.net ([169.254.1.131]) by SGSIHTC007.nsn-intra.net ([10.159.225.24]) with mapi id 14.03.0195.001; Mon, 15 Dec 2014 10:55:50 +0800 From: "Fu, Weiyi (NSN - CN/Hangzhou)" To: "Fu, Weiyi (NSN - CN/Hangzhou)" , "ext Ouyang, Changchun" , "dev@dpdk.org" Thread-Topic: [dpdk-dev] In DPDK 1.7.1, the link status of the interface using virtio driver is always down. Thread-Index: AQHQFRoVfrrffY6AGUCV6tB+0HXMP5yKEnVAgAAxdTCAAFnNAIAAlTsQgATGo1A= Date: Mon, 15 Dec 2014 02:55:49 +0000 Message-ID: <2680B515A539A446ACBEC0EBBDEC3DF80E9388D2@SGSIMBX001.nsn-intra.net> References: <2680B515A539A446ACBEC0EBBDEC3DF80E938312@SGSIMBX001.nsn-intra.net> <2680B515A539A446ACBEC0EBBDEC3DF80E938465@SGSIMBX001.nsn-intra.net> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.159.225.117] MIME-Version: 1.0 X-purgate-type: clean X-purgate-Ad: Categorized by eleven eXpurgate (R) http://www.eleven.de X-purgate: clean X-purgate: This mail is considered clean (visit http://www.eleven.de for further information) X-purgate-size: 2196 X-purgate-ID: 151667::1418612207-0000658F-5D8720C7/0/0 Subject: Re: [dpdk-dev] In DPDK 1.7.1, the link status of the interface using virtio driver is always down. 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi, With follow changes, the link is UP and interface can receive and send traffic. Thanks a lot:) Brs, Fu Weiyi -----Original Message----- From: Fu, Weiyi (NSN - CN/Hangzhou) Sent: Friday, December 12, 2014 9:57 AM To: 'ext Ouyang, Changchun'; dev@dpdk.org Cc: 'mmvijay@gmail.com' Subject: RE: [dpdk-dev] In DPDK 1.7.1, the link status of the interface using virtio driver is always down. Hi, I have ingnored the link status. Rx and tx can't work. I will try the methods Vijay suggested to have a try. Thanks! Brs, Fu Weiyi -----Original Message----- From: ext Ouyang, Changchun [mailto:changchun.ouyang@intel.com] Sent: Friday, December 12, 2014 9:00 AM To: Fu, Weiyi (NSN - CN/Hangzhou); dev@dpdk.org Cc: Ouyang, Changchun Subject: RE: [dpdk-dev] In DPDK 1.7.1, the link status of the interface using virtio driver is always down. Hi > -----Original Message----- > From: Fu, Weiyi (NSN - CN/Hangzhou) [mailto:weiyi.fu@nsn.com] > Sent: Thursday, December 11, 2014 7:42 PM > To: Fu, Weiyi (NSN - CN/Hangzhou); Ouyang, Changchun; dev@dpdk.org > Subject: RE: [dpdk-dev] In DPDK 1.7.1, the link status of the interface using > virtio driver is always down. > > Hi Changchun, > I found you had done follow change to allow the virtio interface startup > when the link is down. Is there any scenario causing link down for virtio > interface? > Not really in my environment, those codes are RFC codes from Brocade, Not merged into mainline yet. You can apply this patch and ignore the link state to see if rx and tx still works. Thanks Changchun diff --git a/lib/librte_pmd_virtio/virtio_ethdev.c b/lib/librte_pmd_virtio/virtio_ethdev.c index 3344ffb..43d1c19 100644 --- a/lib/librte_pmd_virtio/virtio_ethdev.c +++ b/lib/librte_pmd_virtio/virtio_ethdev.c @@ -784,6 +784,7 @@ eth_virtio_dev_init(__rte_unused struct eth_driver *eth_drv, } #endif hw->use_msix = virtio_has_msix(&pci_dev->addr); + hw->use_msix = 1; hw->io_base = (uint32_t)(uintptr_t)pci_dev->mem_resource[0].addr; /* Reset the device although not necessary at startup */