Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp8451169ybl; Thu, 16 Jan 2020 17:07:47 -0800 (PST) X-Google-Smtp-Source: APXvYqx1VG1digDQn+pr7CSMegfA9c6hW96heK/toBioA8JH81DaFKKdsJOOgwqUKHtKM9ihwjbg X-Received: by 2002:a9d:4c82:: with SMTP id m2mr4408048otf.199.1579223266807; Thu, 16 Jan 2020 17:07:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1579223266; cv=none; d=google.com; s=arc-20160816; b=csd2TKw+nbtRsEkZZ/jIXo+VuBq2dy+MZOjg9QChU6fxTiVxRCzC3XqYrUgo/OR0xO 8FsZwDkQrTHz5XFKw8tuHJYFTgao61AuHsV3rIyo6CtsB1EMZFbmuXnWiVkqkZF+N0mT jLAYtYjn+rWnEzUdnzk7uyu4LwcnQHvUBM/AOr3tYE5y+Mm/cN3rtf4WzIdmXlJ4Amby LMH2eY5p3/zfNFYc7Nl76SafONgZXNSMkZ+Y0btK6HdPGmqn1FDjmkmn8716OMxZabCd 8HKS5Up/gSg+gSkH0yscDIVZYAWVMUi6xJ+7izeigJnkAyaBHn7PlZu/uYqOuRLF+Lib wW0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=tRdcEed4Z8MXrSelpvvJP4JzgL8ilpBIPv3BGrj3jQs=; b=Ml9HOLFuGyr054TU+RoAKaG/GOegf9hsUdPpSCXh8VuPw1eHcqkkKaHGzOsOfdY8so XdOjCY/gsvvMPEejXj0m3WbyUI1OU469tM/T6QRVh20ZV3xbQhHsrgD8AZvIbIwOohn6 5KNBgia2xojHuS+FVwESd4aDFxz4zZcUdiWc5WmeAVUAa2S5JOtY85qX+gX3IGNv0Ss5 T18Sxiymz/HTAoxDLQOD1mJxgl5Ys6828SYe04WlVrmSy/dOC7i1Pk4YUvHD3G3TmsJ9 pemDX8esGYTPlE4bi820SDJDL1U9Dhb6qVz8dTvR639gPfZ0Z/ZFSYQa4s87sLMxwJfa qaIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CX4MY5nf; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a205si12865535oii.95.2020.01.16.17.07.34; Thu, 16 Jan 2020 17:07:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CX4MY5nf; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390505AbgAPXTx (ORCPT + 99 others); Thu, 16 Jan 2020 18:19:53 -0500 Received: from mail.kernel.org ([198.145.29.99]:45930 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390496AbgAPXTu (ORCPT ); Thu, 16 Jan 2020 18:19:50 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B1A442073A; Thu, 16 Jan 2020 23:19:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1579216790; bh=tKvAIWa8NVZfJV1Dg44IZpM00pJUHt+tW3x/2Qr252Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CX4MY5nf1Owa0+2UwdpQPUC4NHz0OzzvbbXeMO0maopF0joeXmIbjuxe9s/EYj48G xvLNWlFtwITGu9kMpuizQe+DFGqXQjOiJ+L8ajNFgUb6YQiONJImtnjb4LvIGSYRBt sSI0/B3lCwuO3+09BEkMPBPbs4C7n0fjmDI241C8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hangbin Liu , Simon Horman , "David S. Miller" Subject: [PATCH 5.4 020/203] selftests: loopback.sh: skip this test if the driver does not support Date: Fri, 17 Jan 2020 00:15:37 +0100 Message-Id: <20200116231746.379551057@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200116231745.218684830@linuxfoundation.org> References: <20200116231745.218684830@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hangbin Liu commit cc7e3f63d7299dd1119be39aa187b867d6f8aa17 upstream. The loopback feature is only supported on a few drivers like broadcom, mellanox, etc. The default veth driver has not supported it yet. To avoid returning failed and making the runner feel confused, let's just skip the test on drivers that not support loopback. Fixes: ad11340994d5 ("selftests: Add loopback test") Signed-off-by: Hangbin Liu Reviewed-by: Simon Horman Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- tools/testing/selftests/net/forwarding/loopback.sh | 8 ++++++++ 1 file changed, 8 insertions(+) --- a/tools/testing/selftests/net/forwarding/loopback.sh +++ b/tools/testing/selftests/net/forwarding/loopback.sh @@ -1,6 +1,9 @@ #!/bin/bash # SPDX-License-Identifier: GPL-2.0 +# Kselftest framework requirement - SKIP code is 4. +ksft_skip=4 + ALL_TESTS="loopback_test" NUM_NETIFS=2 source tc_common.sh @@ -72,6 +75,11 @@ setup_prepare() h1_create h2_create + + if ethtool -k $h1 | grep loopback | grep -q fixed; then + log_test "SKIP: dev $h1 does not support loopback feature" + exit $ksft_skip + fi } cleanup()