Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1728806ybl; Sat, 7 Dec 2019 01:19:18 -0800 (PST) X-Google-Smtp-Source: APXvYqy7OQFfKn2u7xrOuwboL5F5QlKAopDsq2XcwUQfqM+CBgtelLJifqHh07nKTutbELoWtLfo X-Received: by 2002:a05:6830:1e8a:: with SMTP id n10mr1137475otr.228.1575710358263; Sat, 07 Dec 2019 01:19:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575710358; cv=none; d=google.com; s=arc-20160816; b=nMSf3Tnv2m8TP9G9LiGpRHHtt+ziqwuouBtpF4+cUdjocD4Edo29sLuxX1x8kEUuDA z1DeV3MzK7qDig3t+BoT7Kw/4W7pPLq9p5K9+v0rlzfRoRdRbTm3WfhOahJtz8/xgdsU VHnRuA2AwoVscjt7sIwjw/WWZnbbbCaNVvaMFV+Q6Bb0Pejuc/o8C0AdznAtoTebDtcN jmN3N7qiGccihGg316l7iPH4o9mgKGejCB7wuBJJwSp8nyMHIFzOfS06s8IbNo1rS074 jGkxuMby9KispJwxgSi9xq7YzS1nrxGGgWWmCH1hY24MsmZZMDvxHWcT5+QCG+fvmWs7 pK+w== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject; bh=2TUNROkBg+f9S44pnaiDo//8Hgq08mTNKazlimvyMZk=; b=XZEzTTh86dDpuAayhpvgJh9IQ0tNJsdWRYDC8tlYNCTu8SWXeTFDUm4KnKb5HJJ2W5 q0lmY+xcahM3YH/S0fURV1YT9FFsN+2fRIj3Md2YB8kbe6TMW81PngJ2RbJkD5287X/T MgwFW2bAF2J8x01GbDPKiJBrRMG4s/q4N4Sb1QCA4cXlgPA9dksoYidX+5Jf1o1Lx8s3 NVzxl+NKknxwywKUO5s6RMOyUg1LXu6+5fFL9RedRuKS7O9r85bzedNjszXqN9uFkiux eJ5innO/oC8wgRrSujuaxqDDLcWKi7901dlwIY3Th0rZqrGclwn0ufBMJTmj5ifZ2WqL sRxg== ARC-Authentication-Results: i=1; mx.google.com; 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 s82si8552682oif.96.2019.12.07.01.18.33; Sat, 07 Dec 2019 01:19:18 -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; 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 S1726289AbfLGJPC (ORCPT + 99 others); Sat, 7 Dec 2019 04:15:02 -0500 Received: from ivanoab7.miniserver.com ([37.128.132.42]:44358 "EHLO www.kot-begemot.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725992AbfLGJPC (ORCPT ); Sat, 7 Dec 2019 04:15:02 -0500 Received: from tun252.jain.kot-begemot.co.uk ([192.168.18.6] helo=jain.kot-begemot.co.uk) by www.kot-begemot.co.uk with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1idWB0-00031X-I9; Sat, 07 Dec 2019 09:14:58 +0000 Received: from sleer.kot-begemot.co.uk ([192.168.3.72]) by jain.kot-begemot.co.uk with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1idWAy-0002er-4G; Sat, 07 Dec 2019 09:14:58 +0000 Subject: Re: [RFC v1 1/2] um: drivers: remove support for UML_NET_PCAP To: Brendan Higgins Cc: johannes.berg@intel.com, Richard Weinberger , Jeff Dike , linux-um@lists.infradead.org, Linux Kernel Mailing List , David Gow References: <20191206020153.228283-1-brendanhiggins@google.com> <20191206020153.228283-2-brendanhiggins@google.com> <20191207012108.GA220741@google.com> From: Anton Ivanov Organization: Cambridge Greys Message-ID: <15f048d3-07ab-61c1-c6e0-0712e626dd33@cambridgegreys.com> Date: Sat, 7 Dec 2019 09:14:55 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.2 MIME-Version: 1.0 In-Reply-To: <20191207012108.GA220741@google.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Spam-Score: -1.0 X-Spam-Score: -1.0 X-Clacks-Overhead: GNU Terry Pratchett Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 07/12/2019 01:21, Brendan Higgins wrote: > On Fri, Dec 06, 2019 at 04:32:34PM -0800, Brendan Higgins wrote: >> On Thu, Dec 5, 2019 at 11:23 PM Anton Ivanov >> wrote: >> [...] >>> 1. There is a proposed patch for the build system to fix it. > > So I just tried the patch you linked on the cover letter[1], and I am > still getting the build error described above: > > arch/um/drivers/pcap_user.c:35:12: error: conflicting types for ‘pcap_open’ > static int pcap_open(void *data) > ^~~~~~~~~ > In file included from /usr/include/pcap.h:43, > from arch/um/drivers/pcap_user.c:7: > /usr/include/pcap/pcap.h:859:18: note: previous declaration of ‘pcap_open’ was here > PCAP_API pcap_t *pcap_open(const char *source, int snaplen, int flags, > > Looking at the patch, I wouldn't expect it to solve this problem. > > Are there maybe different conflicting libpcap-dev libraries and I have > the wrong one? Or is this just still broken? > >>> 2. We should be removing all old drivers and replacing them with the >>> vector ones. >> >> Hmm...does this mean you would entertain a patch removing all the >> non-vector UML network drivers? I would be happy to see VDE go as >> well. >> >> In any event, it sounds like I should probably drop this patch as it >> is currently. >> >> Thanks! > > [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=938962#79 > > _______________________________________________ > linux-um mailing list > linux-um@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-um > OK, looks like the pcap.h differs now as well. I will fix that too. It looks like you need both a pcap fix and a library linking fix for this to work. The patch fixes the issue with the build system which no longer provides the means for UML to specify extra libraries (I probably had an older pcap version on the machine where I tested this). IMHO frankly it is no longer necessary. 5.5-rc1 vector raw now has the facility to add/remove (including at runtime) filters compiled with pcap outside UML. It was merged this week. We now have the following line-up for vector drivers - EoGRE, EoL2TPv3, RAW (+/- BPF), TAP and BESS. Speeds are 2.5 to 9Gbit on my machine (mid-range Ryzen desktop). If I figure out a way to get hold of the underlying tap raw sockets the same way vhost does, TAP can probably go to 12Gbit or thereabouts. Same applies to getting zerocopy working with raw. As a basis for comparison I get 18Gbit on the same machine using vEth and containers. 50% of that is actually a very decent number. While vector drivers are not 1:1 replacements for the existing drivers, you can achieve the same topologies and the same connectivity at much higher performance - the old drivers test out in the 500Mbit range on the same hardware. IMHO we should at least mark them as "obsolete" and start preparing to remove them. -- Anton R. Ivanov Cambridgegreys Limited. Registered in England. Company Number 10273661 https://www.cambridgegreys.com/