Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp106802ybg; Mon, 8 Jun 2020 17:46:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz03KlPVMTk8KUuOHMFhE2UgxZi/gBGDPbVek8cTiehdaqcX3tk5ewz60Po4ATTZ5Zf0AZw X-Received: by 2002:a50:b0c3:: with SMTP id j61mr25030180edd.349.1591663602871; Mon, 08 Jun 2020 17:46:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591663602; cv=none; d=google.com; s=arc-20160816; b=SM5ro5yQ5r8M9tga4HnsYFTW7XBMt2q5K53hNC8O+W3xI2ZacC+swQe0uwm+aXf7z8 9Pbv1fNVWwohce9SMsX4zqrov+kJcxI882B3v9acv9ySmuThyeqw5ZOyWvjpyixm4ZSX H6CjIQvzth1dcDwuMfdNaGiuOEj6StdK5Z7urKdi4t8QRinBayjWNZieCW7YUnr9ZInY M55H2v1LHnJhCFuAcxE1SwWaN7uDnCm38AI2r4nkgQIFA+Vo94lwXRrT0fpSuMqAsBuA KW6cbmT4KHFs6eS06aggqzF4XhrhNF17lmHdKtU4QJgh/M+qc8xPDhBDvZWjAi7guu4O eICg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=n+oYIMgRtMa7f9xAAdSLvj7zMILRwoXgfr1RSMMj03M=; b=lKhMPAnfyJjJS7ckIks2bLeBa3oaLp2bMOxBg82jxj4kizrKGvhg+59aFDzMq8TuqR SbIGOEaz4dSnEd1h1QreF0oElbKyd2GB03EapoPsyqG/+lPWgqcm906pxsfOx6w3vsZe aGhbhj9m53KkGwtr3Us3B2y+0jB11zIYmNtngobdEfb7QrdeUe2aisjdxspMRuKPxnGt 9r/TlR42ynLN5qLRzqJTGWAQ/ER+xciFzhRMPJ9M21WmXcGPtk9c+E2sUG3zoM4qsqKk PmRAMIebw3fH3F6AepJcjrw0AzovskVOsua4NZGyX8e5B4/00V0fQTdGsrQPpe3GPXm/ BXog== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Htg8w5k1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z13si9989371ejp.589.2020.06.08.17.46.19; Mon, 08 Jun 2020 17:46:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Htg8w5k1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733166AbgFIAol (ORCPT + 99 others); Mon, 8 Jun 2020 20:44:41 -0400 Received: from mail.kernel.org ([198.145.29.99]:59148 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729024AbgFHXL7 (ORCPT ); Mon, 8 Jun 2020 19:11:59 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C04922151B; Mon, 8 Jun 2020 23:11:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1591657919; bh=iGDstssJZNRPmYGflzsJwE0HzniypEW0XvpWSC3yA2I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Htg8w5k1y/J5HtQqrgjsQ6NJoIwdPfmWHKemovmEEC4zZzrEd14CmnrsKHBpi4DZe /PyOxqP+EwgfDZee8AY5IE+/EFFzQzc/T/cVtaZJVWBjHSCDAxiKKqX+7tcOZNFf9w FhSL2drySbTiFp4CoHoyjrZQ6mF73EfZK7LuSLn8= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Jakub Sitnicki , Alexei Starovoitov , Sasha Levin , linux-kselftest@vger.kernel.org, netdev@vger.kernel.org, bpf@vger.kernel.org Subject: [PATCH AUTOSEL 5.7 269/274] selftests/bpf, flow_dissector: Close TAP device FD after the test Date: Mon, 8 Jun 2020 19:06:02 -0400 Message-Id: <20200608230607.3361041-269-sashal@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200608230607.3361041-1-sashal@kernel.org> References: <20200608230607.3361041-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jakub Sitnicki [ Upstream commit b8215dce7dfd817ca38807f55165bf502146cd68 ] test_flow_dissector leaves a TAP device after it's finished, potentially interfering with other tests that will run after it. Fix it by closing the TAP descriptor on cleanup. Fixes: 0905beec9f52 ("selftests/bpf: run flow dissector tests in skb-less mode") Signed-off-by: Jakub Sitnicki Signed-off-by: Alexei Starovoitov Link: https://lore.kernel.org/bpf/20200531082846.2117903-11-jakub@cloudflare.com Signed-off-by: Sasha Levin --- tools/testing/selftests/bpf/prog_tests/flow_dissector.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/bpf/prog_tests/flow_dissector.c b/tools/testing/selftests/bpf/prog_tests/flow_dissector.c index 92563898867c..9f3634c9971d 100644 --- a/tools/testing/selftests/bpf/prog_tests/flow_dissector.c +++ b/tools/testing/selftests/bpf/prog_tests/flow_dissector.c @@ -523,6 +523,7 @@ void test_flow_dissector(void) CHECK_ATTR(err, tests[i].name, "bpf_map_delete_elem %d\n", err); } + close(tap_fd); bpf_prog_detach(prog_fd, BPF_FLOW_DISSECTOR); bpf_object__close(obj); } -- 2.25.1