Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1683882ybl; Thu, 19 Dec 2019 00:59:20 -0800 (PST) X-Google-Smtp-Source: APXvYqye+14kv5cPIy+27XT8TAmx4irTX7YpWvEKfdh+rMv+djoC3A0NlNURtrjfCHM4vIL5Cdnv X-Received: by 2002:a9d:7b4a:: with SMTP id f10mr8036096oto.4.1576745960358; Thu, 19 Dec 2019 00:59:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576745960; cv=none; d=google.com; s=arc-20160816; b=oWk9MoE85/KlcHCHW4VfB9igyFJZZM2CUexaN7A2xMXCwEwpQfpAO28yAiUXqMm2L6 XihNhpSsifEWDEjNwUUVwje9XIShRpzfRhzs0ZfbA/JRm9/NGwQ/H0Wu1B9d5ndd9gZp ULyhGyDAionRnaqK9oLKTBHMFeYE55b7kFhH2uj/jwKE3cX/P0daDEhxDV/leSg5RRra AfSe0iJYLKBu5U6ZV2FmXd8rypqv/R3mBB2Ccp7Ydgy5tbDvzrqVugS6IJJyLGfJ4yTX 6tpfjPOwnuiduuY960TIyZ6MUFL1cjUVjBMxtHIMcmLweU+u4p+7eesoEWArqavImrNb qa+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:authenticated-by; bh=I931GGfdv6mrZbWBlHb2hLobDlnL8hzzOSAizzyV2TY=; b=SpPMUSSEv2l/aN2yIzactgvI42BzlYuOADROo/q5bAn5xd5msfM2eiMmqlN8rGD69l mrbcMvH5W0G7h/YprTJY+lD7dauKne6oz4m7YnRcH40eS8D1ne+g1d01VpPV0JP+aqD1 t8tvDsuXDBAO49ezNopigvOL1uEn3z5eUvaeSLbo9nPjLnh99/pkSR4Wz2ah2hQGdthO YiZdyOxnPw9S8kHtsuhYUdK9JF+EfnqaCkzZfSw7wJ3Sxpe5G4MLZo/0oXkEhRsLAYGT 7SXuQJFk0RPSowHhadRE82T9PJKFvmHESq1XV4xndq/3NN9FZ8Hm382tMI+hdigNbOvX ww+g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s126si2891471oib.84.2019.12.19.00.59.09; Thu, 19 Dec 2019 00:59:20 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726742AbfLSI6n (ORCPT + 99 others); Thu, 19 Dec 2019 03:58:43 -0500 Received: from rtits2.realtek.com ([211.75.126.72]:59554 "EHLO rtits2.realtek.com.tw" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726599AbfLSI6m (ORCPT ); Thu, 19 Dec 2019 03:58:42 -0500 Authenticated-By: X-SpamFilter-By: BOX Solutions SpamTrap 5.62 with qID xBJ8wWRX024852, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (RTITCASV01.realtek.com.tw[172.21.6.18]) by rtits2.realtek.com.tw (8.15.2/2.57/5.78) with ESMTPS id xBJ8wWRX024852 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 19 Dec 2019 16:58:32 +0800 Received: from localhost.localdomain (172.21.68.126) by RTITCASV01.realtek.com.tw (172.21.6.18) with Microsoft SMTP Server id 14.3.468.0; Thu, 19 Dec 2019 16:58:31 +0800 From: To: CC: , , Subject: [PATCH v4 1/7] rtw88: pci: reset ring index when release skbs in tx ring Date: Thu, 19 Dec 2019 16:58:10 +0800 Message-ID: <20191219085816.20709-2-yhchuang@realtek.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191219085816.20709-1-yhchuang@realtek.com> References: <20191219085816.20709-1-yhchuang@realtek.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.21.68.126] Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Chin-Yen Lee When skbs queued for each TX ring are relased in PCI stop flow, the ring index should be reset at the same time. Signed-off-by: Chin-Yen Lee Signed-off-by: Yan-Hsuan Chuang --- v1 -> v2 * no change v2 -> v3 * no change v3 -> v4 * no change drivers/net/wireless/realtek/rtw88/pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/wireless/realtek/rtw88/pci.c b/drivers/net/wireless/realtek/rtw88/pci.c index a58e8276a41a..068f1bec88e6 100644 --- a/drivers/net/wireless/realtek/rtw88/pci.c +++ b/drivers/net/wireless/realtek/rtw88/pci.c @@ -506,6 +506,7 @@ static void rtw_pci_dma_release(struct rtw_dev *rtwdev, struct rtw_pci *rtwpci) struct rtw_pci_tx_ring *tx_ring; u8 queue; + rtw_pci_reset_trx_ring(rtwdev); for (queue = 0; queue < RTK_MAX_TX_QUEUE_NUM; queue++) { tx_ring = &rtwpci->tx_rings[queue]; rtw_pci_free_tx_ring_skbs(rtwdev, tx_ring); -- 2.17.1