From patchwork Thu Apr 12 16:09:12 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Kodanev X-Patchwork-Id: 897726 X-Patchwork-Delegate: akodanev@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=lists.linux.it (client-ip=213.254.12.146; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=oracle.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=oracle.com header.i=@oracle.com header.b="ZFIEG31m"; dkim-atps=neutral Received: from picard.linux.it (picard.linux.it [213.254.12.146]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40MQb96k2rz9s2R for ; Fri, 13 Apr 2018 01:59:47 +1000 (AEST) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id 4BF7B3E7559 for ; Thu, 12 Apr 2018 17:59:45 +0200 (CEST) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-5.smtp.seeweb.it (in-5.smtp.seeweb.it [217.194.8.5]) by picard.linux.it (Postfix) with ESMTP id B8BF13E7532 for ; Thu, 12 Apr 2018 17:59:41 +0200 (CEST) Received: from userp2130.oracle.com (userp2130.oracle.com [156.151.31.86]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-5.smtp.seeweb.it (Postfix) with ESMTPS id 933686009A2 for ; Thu, 12 Apr 2018 17:59:40 +0200 (CEST) Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w3CFu6Fu196491 for ; Thu, 12 Apr 2018 15:59:39 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references; s=corp-2017-10-26; bh=tlVDr8idvzoTA/UofACSaNAwN0vVoGeVXF/OW4FkWqw=; b=ZFIEG31mUlLYkrZZfNSOkXYvCp88W3I8PDtPrVh0dQatQnoQgc0jbLWW4o79ZhKMQqME PsRJEXSwcunXS3Ppuo2UxSskgZV+SD2U+bE1xOBiTnIaNzDrXcCghyhwgOrgPUk5lBcO ZcUP1ZGLkXevrG9kw9/5EJMWWmaVieurUmVNHTSNL/sOXPbaFQjSaN2OBfU8MREZiDKo OduUQTBGZAlqEbXeahEju2HHe/+EdmC5L5wRS4BYolwnF9U7vWeZYAILxCojhsC+1HOx KcZh8NWiUixhxxPVHABrcoLKM8EI+sdaaLVZ0CKnZWyVwC2KP93ej40HC3eVMal2ptBF FA== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp2130.oracle.com with ESMTP id 2h6ne7mwdn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Thu, 12 Apr 2018 15:59:38 +0000 Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id w3CFxcp5019679 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Thu, 12 Apr 2018 15:59:38 GMT Received: from abhmp0005.oracle.com (abhmp0005.oracle.com [141.146.116.11]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w3CFxcfA021624 for ; Thu, 12 Apr 2018 15:59:38 GMT Received: from ak.ru.oracle.com (/10.162.80.29) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 12 Apr 2018 08:59:37 -0700 From: Alexey Kodanev To: ltp@lists.linux.it Date: Thu, 12 Apr 2018 19:09:12 +0300 Message-Id: <1523549352-1794-2-git-send-email-alexey.kodanev@oracle.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1523549352-1794-1-git-send-email-alexey.kodanev@oracle.com> References: <1523549352-1794-1-git-send-email-alexey.kodanev@oracle.com> X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8861 signatures=668698 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=869 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1711220000 definitions=main-1804120157 X-Virus-Scanned: clamav-milter 0.99.2 at in-5.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,SPF_PASS autolearn=disabled version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on in-5.smtp.seeweb.it Subject: [LTP] [PATCH 2/2] lib/tst_net.sh: use nodad in tst_add_ipaddr() X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.18 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" Save time when the tests run with netns and without network.sh. Signed-off-by: Alexey Kodanev --- testcases/lib/tst_net.sh | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) diff --git a/testcases/lib/tst_net.sh b/testcases/lib/tst_net.sh index 53f6277..a95eb33 100644 --- a/testcases/lib/tst_net.sh +++ b/testcases/lib/tst_net.sh @@ -126,8 +126,6 @@ init_ltp_netspace() tst_restore_ipaddr tst_restore_ipaddr rhost - - tst_wait_ipv6_dad } # Run command on remote host. @@ -389,9 +387,10 @@ tst_add_ipaddr() { local type="${1:-lhost}" local link_num="${2:-0}" - local mask + local mask dad if [ "$TST_IPV6" ]; then + dad="nodad" [ "$type" = "lhost" ] && mask=$IPV6_LPREFIX || mask=$IPV6_RPREFIX else [ "$type" = "lhost" ] && mask=$IPV4_LPREFIX || mask=$IPV4_RPREFIX @@ -401,12 +400,12 @@ tst_add_ipaddr() if [ $type = "lhost" ]; then tst_res_ TINFO "set local addr $(tst_ipaddr)/$mask" - ip addr add $(tst_ipaddr)/$mask dev $iface + ip addr add $(tst_ipaddr)/$mask dev $iface $dad return $? fi tst_res_ TINFO "set remote addr $(tst_ipaddr rhost)/$mask" - tst_rhost_run -c "ip addr add $(tst_ipaddr rhost)/$mask dev $iface" + tst_rhost_run -c "ip addr add $(tst_ipaddr rhost)/$mask dev $iface $dad" } # tst_restore_ipaddr [TYPE] [LINK]