From patchwork Tue Apr 24 10:36:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tal Gilboa X-Patchwork-Id: 903370 Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=mellanox.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 40Vh8P5ZTfz9ry1 for ; Tue, 24 Apr 2018 21:35:17 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757213AbeDXLfP (ORCPT ); Tue, 24 Apr 2018 07:35:15 -0400 Received: from mail-il-dmz.mellanox.com ([193.47.165.129]:57689 "EHLO mellanox.co.il" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1757205AbeDXLfM (ORCPT ); Tue, 24 Apr 2018 07:35:12 -0400 Received: from Internal Mail-Server by MTLPINE1 (envelope-from talgi@mellanox.com) with ESMTPS (AES256-SHA encrypted); 24 Apr 2018 14:36:32 +0300 Received: from gen-l-vrt-691.mtl.labs.mlnx (gen-l-vrt-691.mtl.labs.mlnx [10.141.69.1]) by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id w3OBZ6Cv030425; Tue, 24 Apr 2018 14:35:06 +0300 Received: from gen-l-vrt-691.mtl.labs.mlnx (localhost [127.0.0.1]) by gen-l-vrt-691.mtl.labs.mlnx (8.14.7/8.14.7) with ESMTP id w3OAaUoi041629; Tue, 24 Apr 2018 13:36:30 +0300 Received: (from talgi@localhost) by gen-l-vrt-691.mtl.labs.mlnx (8.14.7/8.14.7/Submit) id w3OAaQn2041627; Tue, 24 Apr 2018 13:36:26 +0300 From: Tal Gilboa To: David Miller Cc: netdev@vger.kernel.org, Tariq Toukan , Tal Gilboa , Saeed Mahameed , Florian Fainelli , Andy Gospodarek Subject: [PATCH net-next V3 0/3] Introduce adaptive TX interrupt moderation to net DIM Date: Tue, 24 Apr 2018 13:36:00 +0300 Message-Id: <1524566163-41563-1-git-send-email-talgi@mellanox.com> X-Mailer: git-send-email 1.8.3.1 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Net DIM is a library designed for dynamic interrupt moderation. It was implemented and optimized with receive side interrupts in mind, since these are usually the CPU expensive ones. This patch-set introduces adaptive transmit interrupt moderation to net DIM, complete with a usage in the mlx5e driver. Using adaptive TX behavior would reduce interrupt rate for multiple scenarios. Furthermore, it is essential for increasing bandwidth on cases where payload aggregation is required. v3: Remove "inline" from functions in .c files (requested by DaveM). Revert adding "enabled" field from struct net_dim and applied mlx5e structural suggestions (suggested by SaeedM). v2: Rebase over proper tree. v1: Fix compilation issues due to missed function renaming. Tal Gilboa (3): net/dim: Rename *_get_profile() functions to *_get_rx_moderation() net/dim: Support adaptive TX moderation net/mlx5e: Enable adaptive-TX moderation drivers/net/ethernet/broadcom/bcmsysport.c | 6 +- drivers/net/ethernet/broadcom/bnxt/bnxt_dim.c | 8 +-- drivers/net/ethernet/broadcom/genet/bcmgenet.c | 6 +- drivers/net/ethernet/mellanox/mlx5/core/en.h | 4 ++ drivers/net/ethernet/mellanox/mlx5/core/en_dim.c | 28 ++++++-- .../net/ethernet/mellanox/mlx5/core/en_ethtool.c | 35 +++++++--- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 79 ++++++++++++++-------- drivers/net/ethernet/mellanox/mlx5/core/en_txrx.c | 37 +++++++--- include/linux/net_dim.h | 69 ++++++++++++++----- 9 files changed, 190 insertions(+), 82 deletions(-)