From patchwork Sat Dec 18 23:54:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Mosberger-Tang X-Patchwork-Id: 526850 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4AADFC433F5 for ; Sat, 18 Dec 2021 23:55:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235227AbhLRXz2 (ORCPT ); Sat, 18 Dec 2021 18:55:28 -0500 Received: from o1.ptr2625.egauge.net ([167.89.112.53]:25498 "EHLO o1.ptr2625.egauge.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234933AbhLRXyU (ORCPT ); Sat, 18 Dec 2021 18:54:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=egauge.net; h=from:subject:in-reply-to:references:mime-version:to:cc: content-transfer-encoding:content-type; s=sgd; bh=RT9YbsVtdR4GzUV4QohWzyGBC/fSE3abgungjw0gKpI=; b=DI2HiQJ/zFWwPLhZv+3T3Rl+KuFLuimYbfKdO+q6+UnCb3EfqWCEZoGGKbAowvAnB4bi GRCDd0FRQl5EkyFRKcAQZbdGeXQHhoMYZng524VREnBd7U/zyCFWzxusrnM5j/C0lRjqz2 m/rMxD3xza4bl0bYTByPnfU5z+zT2HOmW9eGNDiVkZrOMXeMbYU84okzxmVUYUSigLVKRS dRCTLS5Ma2rZcdk3YVoRHdIya2pzWZrqilQOcakp0/Khmerpw7g1dMCO/wYcdna7H/7VAc WPyb0LSSUoeogwdKMexKnR+i3mt9TrQF0pIx6W30QZLVt09eLDB+n2sCsCe76lUg== Received: by filterdrecv-7bf5c69d5-p7gjg with SMTP id filterdrecv-7bf5c69d5-p7gjg-1-61BE74A8-19 2021-12-18 23:54:16.810393089 +0000 UTC m=+1581803.434338992 Received: from pearl.egauge.net (unknown) by geopod-ismtpd-3-0 (SG) with ESMTP id Zo3TXZV0SyWEp2hsODIFTg Sat, 18 Dec 2021 23:54:16.680 +0000 (UTC) Received: by pearl.egauge.net (Postfix, from userid 1000) id 96FCC700F5D; Sat, 18 Dec 2021 16:54:15 -0700 (MST) From: David Mosberger-Tang Subject: [PATCH 07/23] wilc1000: increment tx_dropped stat counter on tx packet drop Date: Sat, 18 Dec 2021 23:54:17 +0000 (UTC) Message-Id: <20211218235404.3963475-8-davidm@egauge.net> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211218235404.3963475-1-davidm@egauge.net> References: <20211218235404.3963475-1-davidm@egauge.net> MIME-Version: 1.0 X-SG-EID: +kMxBqj35EdRUKoy8diX1j4AXmPtd302oan+iXZuF8m2Nw4HRW2irNspffT/khET6RJF6+Prbl0h/EtF1rRLvED/zcavR1sH7nYvL46KWWXmyIJ8qnkI45lXgEPjy7Xft66PMj7o6uG1hrNLoSTcAe0/27A0i6YO161kES7Da+tApeSd7UOFDRgvUicIUqHKXLnEGiZU7qxMKVCwj3vAWK0BKRzt5IofQGOLUbmoRvk4m5PbfEIcWU4+i45E8/SD9tu8/BVl+amilRS/yEMbOA== To: Ajay Singh Cc: Claudiu Beznea , Kalle Valo , "David S. Miller" , Jakub Kicinski , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, David Mosberger-Tang X-Entity-ID: Xg4JGAcGrJFIz2kDG9eoaQ== Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Packet drops are important events so we should remember to count them. Signed-off-by: David Mosberger-Tang --- drivers/net/wireless/microchip/wilc1000/wlan.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/microchip/wilc1000/wlan.c b/drivers/net/wireless/microchip/wilc1000/wlan.c index a9bfd71b0e667..b85ceda8409e6 100644 --- a/drivers/net/wireless/microchip/wilc1000/wlan.c +++ b/drivers/net/wireless/microchip/wilc1000/wlan.c @@ -202,7 +202,10 @@ static void wilc_wlan_tx_packet_done(struct txq_entry_t *tqe, int status) static void wilc_wlan_txq_drop_net_pkt(struct txq_entry_t *tqe) { - struct wilc *wilc = tqe->vif->wilc; + struct wilc_vif *vif = tqe->vif; + struct wilc *wilc = vif->wilc; + + vif->ndev->stats.tx_dropped++; wilc_wlan_txq_remove(wilc, tqe->q_num, tqe); wilc_wlan_tx_packet_done(tqe, 1);