Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp488433ybl; Fri, 23 Aug 2019 04:03:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqwYoK8zPu9r2BG6Yyxyj1etedUGFJ54EKHI/ZvOWKZ9PWMKf0X7S/hcgB3FFc08DMgl8nek X-Received: by 2002:a17:90a:8c0f:: with SMTP id a15mr4415952pjo.112.1566558221793; Fri, 23 Aug 2019 04:03:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566558221; cv=none; d=google.com; s=arc-20160816; b=i0yrODXrXerlutsO+9dvuUsSsyJIrSSsnr/d5dRG7/i+BqBrcOldA5PXi4tTC52zYK qBFGMlusIf+UeAcB3JSOV+zcIPsp3C+njjaJRUUz5YLuUP5rX38BfAJQiZ+Nh4vt9OC6 ayCeLcU3zdO7eBT9KERG4Yx9kWRCX6xXG+ZSr4ztdbzZPz7wDonz7xzth8cFDGpisytq F9Lkro4os4d+81+gDY+wv1WgOAYSw0L/J1K5BfzbBR2TK5CWSCX1b8QZW30XfglPNftZ D2JRj8KT2kqV65wURHuDupGeZTVPSb7Kb3wAvxu60uO/VCPTL1NRsSZ7rLUuGyfmpRtP JDqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :authenticated-by; bh=gfHLP/4Z9tVXt3HXztA2RbJd8MOaaeADacH5KSLMX0A=; b=ckSGbjr+P85QIj45Bmfrqu/YdXR9+6RmWrZjUbGXJdenc0dka68hveJb9bzVkVAJ/+ SpJovyIsHtgP3YFOssCE4XROyfwf5ryXM0Qe0vRl2mLoTqH93NpqfMdNZuo2OMerVDs3 +LP3Xw/a+81AyQUTxrXf762W6k4xUgWnDtb8XN9GqMinLZCULVLGj+wikQYSwlPNCnCQ RfXc0pQSFyZA5tt1Opi+xmZSNn2MvTjpZlBm4jyqB76ur9u7MyFRvO+pB9ufuiMmoJaa 8lI0hTghWvQdEYiWMOROF/zsQh0vws3XhL3q60DfAI25gcOhRIVUgEWBFD6E8qGjQ12Y xp3g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-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 m190si1673100pga.322.2019.08.23.04.03.25; Fri, 23 Aug 2019 04:03:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2393263AbfHWIxc (ORCPT + 99 others); Fri, 23 Aug 2019 04:53:32 -0400 Received: from rtits2.realtek.com ([211.75.126.72]:40112 "EHLO rtits2.realtek.com.tw" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2393130AbfHWIxc (ORCPT ); Fri, 23 Aug 2019 04:53:32 -0400 Authenticated-By: X-SpamFilter-By: BOX Solutions SpamTrap 5.62 with qID x7N8rRxc020367, 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 x7N8rRxc020367 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Fri, 23 Aug 2019 16:53:27 +0800 Received: from fc30.localdomain (172.21.177.138) by RTITCASV01.realtek.com.tw (172.21.6.18) with Microsoft SMTP Server id 14.3.468.0; Fri, 23 Aug 2019 16:53:26 +0800 From: Hayes Wang To: CC: , , , Hayes Wang Subject: [PATCH net 2/2] r8152: avoid using napi_disable after netif_napi_del. Date: Fri, 23 Aug 2019 16:53:02 +0800 Message-ID: <1394712342-15778-316-Taiwan-albertk@realtek.com> X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <1394712342-15778-314-Taiwan-albertk@realtek.com> References: <1394712342-15778-314-Taiwan-albertk@realtek.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [172.21.177.138] Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Exchange netif_napi_del() and unregister_netdev() in rtl8152_disconnect() to avoid using napi_disable() after netif_napi_del(). Signed-off-by: Hayes Wang --- drivers/net/usb/r8152.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c index 690a24d1ef82..29390eda5251 100644 --- a/drivers/net/usb/r8152.c +++ b/drivers/net/usb/r8152.c @@ -5364,8 +5364,8 @@ static void rtl8152_disconnect(struct usb_interface *intf) if (tp) { rtl_set_unplug(tp); - netif_napi_del(&tp->napi); unregister_netdev(tp->netdev); + netif_napi_del(&tp->napi); cancel_delayed_work_sync(&tp->hw_phy_work); tp->rtl_ops.unload(tp); free_netdev(tp->netdev); -- 2.21.0