Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2656665pxb; Thu, 11 Feb 2021 19:49:18 -0800 (PST) X-Google-Smtp-Source: ABdhPJyTtzNAPvUrRE3bz19/0HaQv6vIK7hCGsni+bmuD3eYaZnqWRIiTQUh81O4EHKfzN/QrOWY X-Received: by 2002:a50:80c6:: with SMTP id 64mr1307547edb.209.1613101758694; Thu, 11 Feb 2021 19:49:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613101758; cv=none; d=google.com; s=arc-20160816; b=H95UYBve8M7KWxk9XtSWaPrJfsamMYDyZlDbOIwRvDvTxq4Ma5K1C1DBYWy5+T/Jbc vpqEwLy3SUfmKGhwkfOBBBy18x4IG/TU5DFAK22UPGVxnZ+lxCSyP6jHS2M6MqPKM3bD JZv/5CBHoGA6N116bKA5qViQcY1W5QWZkGbGApEDjg59tTeSQCq1P3HMu2KnhZYXK6xt PuKdXK7w14BboCYRbX/uohKzJTeYiYlHe1HM8xyl77i49UrVIkjMD2KxJpmzY+/914Ft Nh1nO5n6T15xyAKX3YMmGJcURS8iu2yBEuPYUxNMt9nZxudeKa4tndEvx3fD68tTv/n4 DqXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=x4SDy/3FUZQaQWYaudQGkVl4Fs4MFq5b1IZKtVmijUM=; b=0Rx5dsRtvtVMFaF4oPdqh4N+pZ58PYLAllPdaBbK05dRA6uCdrXYRbWcLKGOlitRpY M9Z0VT64mfH0BH7Ag49qi3OYVYE5Pk1tt6gTUFoEMVwn/mW/Q8WlC0jfwreSJS99O8ul QEXcwHCrzkUm9L28F2JwTAYvR+fl3V3Y8GTqEqD+9yrpAJeSISuG2oGAWi9ZqMzYKyJ8 SJmkXAqTfZzN4r67imklGwCsXLN3uOkwZ+tiXz5XbWsPorJu6m3omDTitI3dO4dZyGY4 curai55praVqSQJAI1ILuzqWyOScGFMKr/D6TpbNlKmH5JYx58eMnkCDxdFAWYCuIKKd Jldg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=ei+BFKKa; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t5si5294390edd.296.2021.02.11.19.48.51; Thu, 11 Feb 2021 19:49:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-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=@chromium.org header.s=google header.b=ei+BFKKa; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229499AbhBLDpj (ORCPT + 99 others); Thu, 11 Feb 2021 22:45:39 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41366 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229493AbhBLDpi (ORCPT ); Thu, 11 Feb 2021 22:45:38 -0500 Received: from mail-ot1-x331.google.com (mail-ot1-x331.google.com [IPv6:2607:f8b0:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3FEEDC061574 for ; Thu, 11 Feb 2021 19:44:58 -0800 (PST) Received: by mail-ot1-x331.google.com with SMTP id k10so7287906otl.2 for ; Thu, 11 Feb 2021 19:44:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=x4SDy/3FUZQaQWYaudQGkVl4Fs4MFq5b1IZKtVmijUM=; b=ei+BFKKaLh6pNi9JSxtd8Tmd06eM+Hpa3ndQ3I73D4xZG2qKWiLSQGGyv1c2cQfbIX piRwV3aUseMXN3EZM05LlmpDmuPqj37/AADgophw7MD7GG4Z84in5XkhTZx2mh1ZUQHl hP6mtQ9dbXVWcvP3cK56EupTnSscpZDZ4hqBg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=x4SDy/3FUZQaQWYaudQGkVl4Fs4MFq5b1IZKtVmijUM=; b=iMLNT9vQRFZDp7JhrhQKj5jF6FS6w2y2p0NFwO9TsaK/Fpg8baPxW0bIJqmPV1Q2I+ n4nZkazRRszDioZpcQMj6FR+JEWoDoiX4xfhu64oVUdTdTtEfHpmhp791fnIy2ggcGcY hyeqhpv/+sm+04uHvCUf/oBNiklZe2VVXWAViFTSEgcy8ijHOab1ryIhr6PS5aKn8Ybg c3ebIMXI4RlxU1eEXIGeWzsUwQzenJuq7V0ff4ictyNFGZftUuQAzG8KirqsDb3NfxPf BsUC+UP8RofH2x4bu8osFP/zicxxacIJOjhSYntAUks2bwFU6+DBhA3WWwtIPszfL1Q0 7FoQ== X-Gm-Message-State: AOAM531HXGXhXUJDUL56yv2fV8cWBRm6G9vWIA5ZfcJF0EmKiZwv09Mz u8Pz54+ctQ43ijDtcdXYyE9Pl4IKKUgq8g== X-Received: by 2002:a05:6830:1f4e:: with SMTP id u14mr761534oth.65.1613101497093; Thu, 11 Feb 2021 19:44:57 -0800 (PST) Received: from mail-ot1-f51.google.com (mail-ot1-f51.google.com. [209.85.210.51]) by smtp.gmail.com with ESMTPSA id l133sm1572126oia.37.2021.02.11.19.44.56 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 11 Feb 2021 19:44:56 -0800 (PST) Received: by mail-ot1-f51.google.com with SMTP id l23so7251306otn.10 for ; Thu, 11 Feb 2021 19:44:56 -0800 (PST) X-Received: by 2002:a9d:3d76:: with SMTP id a109mr767748otc.203.1613101495918; Thu, 11 Feb 2021 19:44:55 -0800 (PST) MIME-Version: 1.0 References: <20210209070755.23019-1-pkshih@realtek.com> <20210209070755.23019-4-pkshih@realtek.com> In-Reply-To: <20210209070755.23019-4-pkshih@realtek.com> From: Brian Norris Date: Thu, 11 Feb 2021 19:44:43 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v5 3/8] rtw88: add napi support To: Ping-Ke Shih Cc: Yan-Hsuan Chuang , Kalle Valo , linux-wireless , Bernie Huang Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Mon, Feb 8, 2021 at 11:11 PM Ping-Ke Shih wrote: > > From: Po-Hao Huang > > Use napi to reduce overhead on rx interrupts. > > Driver used to interrupt kernel for every Rx packet, this could > affect both system and network performance. NAPI is a mechanism that > uses polling when processing huge amount of traffic, by doing this > the number of interrupts can be decreased. > > Network performance can also benefit from this patch. Since TCP > connection is bidirectional and acks are required for every several > packets. These ack packets occupie the PCI bus bandwidth and could > lead to performance degradation. > > When napi is used, GRO receive is enabled by default in the mac80211 > stack. So mac80211 won't pass every RX TCP packets to the kernel TCP > network stack immediately. Instead an aggregated large length TCP packet > will be delivered. > > This reduces the tx acks sent and gains rx performance. After the patch, > the Rx throughput increases about 25Mbps in 11ac. > > Signed-off-by: Po-Hao Huang > Signed-off-by: Ping-Ke Shih I think this version handles my review comments and straightens up the locking situation: Reviewed-by: Brian Norris Tested-by: Brian Norris Thanks.