From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id D64E75585 for ; Wed, 21 Sep 2016 09:18:30 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga101.jf.intel.com with ESMTP; 21 Sep 2016 00:18:29 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.30,372,1470726000"; d="scan'208";a="1043566845" Received: from unknown (HELO dpdk-fedora20.icx.intel.com) ([10.240.176.135]) by fmsmga001.fm.intel.com with ESMTP; 21 Sep 2016 00:18:29 -0700 From: "xu,gang" To: dts@dpdk.org Cc: "xu,gang" Date: Wed, 21 Sep 2016 15:20:00 +0800 Message-Id: <1474442404-24219-1-git-send-email-gangx.xu@intel.com> X-Mailer: git-send-email 1.9.3 Subject: [dts] [PATCH V1] fix enable and disable ipv6 on FreeBSD 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, 21 Sep 2016 07:18:31 -0000 Signed-off-by: xu,gang --- nics/net_device.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/nics/net_device.py b/nics/net_device.py index 39bd4e5..bbe4bed 100644 --- a/nics/net_device.py +++ b/nics/net_device.py @@ -422,7 +422,11 @@ class NetDevice(object): self.__send_expect("ifconfig %s up" % intf, "# ") def enable_ipv6_freebsd(self, intf): - pass + self.__send_expect("sysctl net.ipv6.conf.%s.disable_ipv6=0" % + intf, "# ") + self.__send_expect("ifconfig %s down" % intf, "# ") + self.__send_expect("ifconfig %s up" % intf, "# ") + @nic_has_driver def disable_ipv6(self): @@ -443,7 +447,10 @@ class NetDevice(object): intf, "# ") def disable_ipv6_freebsd(self, intf): - pass + self.__send_expect("sysctl net.ipv6.conf.%s.disable_ipv6=1" % + intf, "# ") + self.__send_expect("ifconfig %s down" % intf, "# ") + self.__send_expect("ifconfig %s up" % intf, "# ") @nic_has_driver def get_ipv6_addr(self): -- 1.9.3