From patchwork Thu Oct 29 17:28:52 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 11867051 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.1 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A170BC4363A for ; Thu, 29 Oct 2020 17:29:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2BB9420756 for ; Thu, 29 Oct 2020 17:29:35 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="T0cz/8+J" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726665AbgJ2R3e (ORCPT ); Thu, 29 Oct 2020 13:29:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37040 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725803AbgJ2R3d (ORCPT ); Thu, 29 Oct 2020 13:29:33 -0400 Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 25952C0613D5 for ; Thu, 29 Oct 2020 10:28:59 -0700 (PDT) Received: by mail-wm1-x341.google.com with SMTP id v5so598553wmh.1 for ; Thu, 29 Oct 2020 10:28:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:to:cc:message-id:date:user-agent:mime-version :content-language:content-transfer-encoding; bh=PnA8jzIEuTFtJjEgsmvrwqFY+148FJUCFXRwrCY31bo=; b=T0cz/8+JmyyU+vLplok/3CPhgebaCNDl1H+XPiJMS2qFcmnVEmaHj8OzufaAUuqGYn G0qtFS/97CUBYFHXVNHDEXP13BqOwG+ji5q0pk3KAuRb03OwlXRvo8PdM0JorJ/NzwqG Cjk7RzEdtfCBWNqV4eiTfww0QMVgV4l1I8Hmhtzjfmm4P7xqKu1qcbLi5rigjY2EnECh prlJqI1LwvZcKfEF4Gnwwzy/j62KbL6ZKaQTCC2pJ48gt++Kms96i/sSDhGMDsrvFeSe a6984oPZWJlhFRpAo3pvxbjaZrLLPcn8OdvXI3/+RBeALwIw8okRWjMjqbIoFmI+sugc D/WQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:cc:message-id:date:user-agent :mime-version:content-language:content-transfer-encoding; bh=PnA8jzIEuTFtJjEgsmvrwqFY+148FJUCFXRwrCY31bo=; b=iwbur+3CcipcI9OeXo7vG4dCQXevKVdRboPmflsD2zCyM9sugDmh1pVBuVd+Mmpf0T JQ/Zs/DPW+ltUXR59ZXoZlbNIsnvFiLwjZqQteABqa0cxlMcD2PU1afd6baCUCTqUtQn HU6LtTaFwxWwoI6M7Rk3+kWZdmisoJe+kvqoCSHSkw+E4xsd39DhrQiUCvngRbtA3rYg MtAvehDYsrwLPQ3JQZaHLKq729TTaZxcKOl5p7s6FnsdRlBmeBtoDmsW2pmVj26oCkzz DGBWuDf7P5MYGN85m1tJZ2f6cME30OTujZO5J/xwmMO4aGMgzW/gA4cHzp+/WLw6vcfo RWwQ== X-Gm-Message-State: AOAM531tZaXwfmDXogcaTE44CTPqhm9MisNldar0MSnnwHSsqZq5codu KwtYVTWWnrrBwiSgNjzh09Gf3PjLwvM= X-Google-Smtp-Source: ABdhPJytx/seY1VgwuF8BkpAvsarGJiiYDBA4be0z1zdxOQWHnMkc7EOLT2SaLd+21enYqz79a5nyg== X-Received: by 2002:a7b:c157:: with SMTP id z23mr980545wmi.70.1603992537680; Thu, 29 Oct 2020 10:28:57 -0700 (PDT) Received: from ?IPv6:2003:ea:8f23:2800:a990:f24b:87e1:a560? (p200300ea8f232800a990f24b87e1a560.dip0.t-ipconnect.de. [2003:ea:8f23:2800:a990:f24b:87e1:a560]) by smtp.googlemail.com with ESMTPSA id z76sm856239wmc.10.2020.10.29.10.28.57 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 29 Oct 2020 10:28:57 -0700 (PDT) From: Heiner Kallweit Subject: [PATCH net-next 0/4] net: add functionality to net core byte/packet counters and use it in r8169 To: David Miller , Jakub Kicinski , Realtek linux nic maintainers Cc: "netdev@vger.kernel.org" Message-ID: <1fdb8ecd-be0a-755d-1d92-c62ed8399e77@gmail.com> Date: Thu, 29 Oct 2020 18:28:52 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org This series adds missing functionality to the net core handling of byte/packet counters and statistics. The extensions are then used to remove private rx/tx byte/packet counters in r8169 driver. Heiner Kallweit (4): net: core: add dev_sw_netstats_tx_add net: core: add devm_netdev_alloc_pcpu_stats r8169: use struct pcpu_sw_netstats for rx/tx packet/byte counters r8169: remove no longer needed private rx/tx packet/byte counters drivers/net/ethernet/realtek/r8169_main.c | 45 ++++------------------- include/linux/netdevice.h | 26 +++++++++++++ 2 files changed, 34 insertions(+), 37 deletions(-)