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 B485E2A5F for ; Wed, 23 Dec 2015 04:55:22 +0100 (CET) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga101.fm.intel.com with ESMTP; 22 Dec 2015 19:55:14 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,467,1444719600"; d="scan'208";a="17981963" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by fmsmga004.fm.intel.com with ESMTP; 22 Dec 2015 19:55:13 -0800 Received: from shecgisg003.sh.intel.com (shecgisg003.sh.intel.com [10.239.29.90]) by shvmail01.sh.intel.com with ESMTP id tBN3tBOA019907; Wed, 23 Dec 2015 11:55:11 +0800 Received: from shecgisg003.sh.intel.com (localhost [127.0.0.1]) by shecgisg003.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id tBN3t9nJ031275; Wed, 23 Dec 2015 11:55:11 +0800 Received: (from ypei@localhost) by shecgisg003.sh.intel.com (8.13.6/8.13.6/Submit) id tBN3t8Vm031271; Wed, 23 Dec 2015 11:55:08 +0800 From: Yulong Pei To: dts@dpdk.org Date: Wed, 23 Dec 2015 11:55:05 +0800 Message-Id: <1450842905-31238-1-git-send-email-yulong.pei@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dts] [V2][PATCH] fix interface can not up when switch from igb_uio to legacy driver X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Dec 2015 03:55:23 -0000 when an interface switch from igb_uio driver to legacy linux driver, the interface always in down state, but it should be in up state. Signed-off-by: Yulong Pei --- framework/net_device.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/net_device.py b/framework/net_device.py index 37495bd..f3ee9a7 100644 --- a/framework/net_device.py +++ b/framework/net_device.py @@ -722,6 +722,9 @@ class NetDevice(object): self.__send_expect( "echo %s > /sys/bus/pci/drivers/%s/bind" % (nic_pci_num, driver), "# ") + if driver == self.default_driver: + itf = self.get_interface_name() + self.__send_expect("ifconfig %s up" % itf, "# ") def bind_driver_linux_pci_stub(self, bus_id, devfun_id): """ -- 2.1.0