From owner-freebsd-net@FreeBSD.ORG Mon Sep 15 16:14:59 2014 Return-Path: Delivered-To: net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 675E9BFE; Mon, 15 Sep 2014 16:14:59 +0000 (UTC) Received: from mail-we0-x231.google.com (mail-we0-x231.google.com [IPv6:2a00:1450:400c:c03::231]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D2AF0A4C; Mon, 15 Sep 2014 16:14:58 +0000 (UTC) Received: by mail-we0-f177.google.com with SMTP id u57so4234506wes.22 for ; Mon, 15 Sep 2014 09:14:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=EDpT3rEeCquGBQlAJkhJIYGGtucyP9FyHRw1Q1I9AUQ=; b=lEvbzYCQ/Y/1t9eDsOZy/pTL/0HiuFhF79Hg1/GVSB0IQXGS2sQmjsAyRfHgO6b7Xt 7priG1oLon0WqiiWWoueSjOckRZpnxWIdjehwghrNzMub689z46dX3/WNTFP/1Q2XuWE yi8I91PWWwNglrLFF1EIwuoEqDAydVoAqLmCopEDvX/gkeb0JRG5124hcjAFQ4xc/Sgw 7g1K2EAhHNdxFhzVuK79CMReYJZytZ7zfQgioZiLq0A+uGnY7BCr8HK/up2WRIFFPlnC 2Ivy+dET6kBydBuWl5GOAyDN/zKoQcoCshu1g+xFZ9ieQ8ubIpkrR9QtI8OmGBzVARyc HP3A== MIME-Version: 1.0 X-Received: by 10.180.206.230 with SMTP id lr6mr24792649wic.82.1410797694338; Mon, 15 Sep 2014 09:14:54 -0700 (PDT) Sender: asomers@gmail.com Received: by 10.194.126.1 with HTTP; Mon, 15 Sep 2014 09:14:54 -0700 (PDT) In-Reply-To: <5414D10E.7020000@FreeBSD.org> References: <5414D10E.7020000@FreeBSD.org> Date: Mon, 15 Sep 2014 10:14:54 -0600 X-Google-Sender-Auth: Hzq8tmQCBDGwqjYbgIaMTI3lboI Message-ID: Subject: Re: if_lagg(4) accounting changes From: Alan Somers To: "Alexander V. Chernikov" Content-Type: text/plain; charset=UTF-8 Cc: "net@freebsd.org" X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Sep 2014 16:14:59 -0000 On Sat, Sep 13, 2014 at 5:19 PM, Alexander V. Chernikov wrote: > Hello list. > > I'd like to commit some changes to lagg counters which might be worth > discussion. > > Diff is available at https://reviews.freebsd.org/D781 > Quoting its summary: > > > While counting packets using per-cpu counters might not introduce > any significant overhead at current rates, we do not need to > do such accounting at all. > > lagg in general is pure control-plane interface, its action on > receive should be just to change packet src if pointer. > Its action on transmit should be just selecting output interface > based on flowid. > It should not generate any errors on its own. > > In fact, RX lagg path can be skipped by setting correct ifp inside > NIC driver. TX path should be handled by generic multipath L2 nexthops > inside routing code. > > This is first step for implementing this scenario. > One side effect is that we're now collecting all counters (including > errors) from underlying interfaces. Generally most networking HW vendors > implement this behavior for their equipment and this is really the > reasonable thing to do. Sounds interesting. I'll give it a thorough review soon, but probably not today. -Alan