From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.4 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 56B42C432BE for ; Wed, 4 Aug 2021 12:07:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2DA6660EB9 for ; Wed, 4 Aug 2021 12:07:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237986AbhHDMHL (ORCPT ); Wed, 4 Aug 2021 08:07:11 -0400 Received: from mga06.intel.com ([134.134.136.31]:49804 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234765AbhHDMHJ (ORCPT ); Wed, 4 Aug 2021 08:07:09 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10065"; a="274958502" X-IronPort-AV: E=Sophos;i="5.84,294,1620716400"; d="scan'208";a="274958502" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Aug 2021 05:06:56 -0700 X-IronPort-AV: E=Sophos;i="5.84,294,1620716400"; d="scan'208";a="511886792" Received: from dfuxbrum-mobl.ger.corp.intel.com (HELO [10.251.175.67]) ([10.251.175.67]) by fmsmga003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Aug 2021 05:06:53 -0700 Subject: Re: [Intel-wired-lan] [PATCH v2] igc: fix page fault when thunderbolt is unplugged To: Aaron Ma , jesse.brandeburg@intel.com, anthony.l.nguyen@intel.com, davem@davemloft.net, kuba@kernel.org, intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20210702045120.22855-1-aaron.ma@canonical.com> <20210713130036.741188-1-aaron.ma@canonical.com> From: "Fuxbrumer, Dvora" Message-ID: <567b12f8-359a-5268-e020-edcf2dd46937@linux.intel.com> Date: Wed, 4 Aug 2021 15:06:44 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <20210713130036.741188-1-aaron.ma@canonical.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/13/2021 16:00, Aaron Ma wrote: > After unplug thunerbolt dock with i225, pciehp interrupt is triggered, > remove call will read/write mmio address which is already disconnected, > then cause page fault and make system hang. > > Check PCI state to remove device safely. > > Trace: > BUG: unable to handle page fault for address: 000000000000b604 > Oops: 0000 [#1] SMP NOPTI > RIP: 0010:igc_rd32+0x1c/0x90 [igc] > Call Trace: > igc_ptp_suspend+0x6c/0xa0 [igc] > igc_ptp_stop+0x12/0x50 [igc] > igc_remove+0x7f/0x1c0 [igc] > pci_device_remove+0x3e/0xb0 > __device_release_driver+0x181/0x240 > > Signed-off-by: Aaron Ma > --- > drivers/net/ethernet/intel/igc/igc_main.c | 32 ++++++++++++++--------- > drivers/net/ethernet/intel/igc/igc_ptp.c | 3 ++- > 2 files changed, 21 insertions(+), 14 deletions(-) > Tested-by: Dvora Fuxbrumer From mboxrd@z Thu Jan 1 00:00:00 1970 From: Fuxbrumer, Dvora Date: Wed, 4 Aug 2021 15:06:44 +0300 Subject: [Intel-wired-lan] [PATCH v2] igc: fix page fault when thunderbolt is unplugged In-Reply-To: <20210713130036.741188-1-aaron.ma@canonical.com> References: <20210702045120.22855-1-aaron.ma@canonical.com> <20210713130036.741188-1-aaron.ma@canonical.com> Message-ID: <567b12f8-359a-5268-e020-edcf2dd46937@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: intel-wired-lan@osuosl.org List-ID: On 7/13/2021 16:00, Aaron Ma wrote: > After unplug thunerbolt dock with i225, pciehp interrupt is triggered, > remove call will read/write mmio address which is already disconnected, > then cause page fault and make system hang. > > Check PCI state to remove device safely. > > Trace: > BUG: unable to handle page fault for address: 000000000000b604 > Oops: 0000 [#1] SMP NOPTI > RIP: 0010:igc_rd32+0x1c/0x90 [igc] > Call Trace: > igc_ptp_suspend+0x6c/0xa0 [igc] > igc_ptp_stop+0x12/0x50 [igc] > igc_remove+0x7f/0x1c0 [igc] > pci_device_remove+0x3e/0xb0 > __device_release_driver+0x181/0x240 > > Signed-off-by: Aaron Ma > --- > drivers/net/ethernet/intel/igc/igc_main.c | 32 ++++++++++++++--------- > drivers/net/ethernet/intel/igc/igc_ptp.c | 3 ++- > 2 files changed, 21 insertions(+), 14 deletions(-) > Tested-by: Dvora Fuxbrumer